source: waeup_product/trunk/skins/waeup_default/getWAeUPSchemas.py @ 113

Last change on this file since 113 was 113, checked in by joachim, 19 years ago

=academics created

  • Property svn:keywords set to Id
File size: 11.9 KB
RevLine 
[47]1#-*- mode: python; mode: fold -*-
2# $Id: getWAeUPSchemas.py 113 2005-10-28 10:17:39Z joachim $
3
4university_schema = { ###(
[45]5}
[47]6###)
7
8students_folder_schema = { ###(
[45]9}
[47]10###)
11
[113]12academics_folder_schema = { ###(
13}
14###)
15
[47]16student_schema = { ###(
[19]17     'jamb_is_admitted': {
18        'type': 'CPS Boolean Field',
19        'data': {
20            'default_expr': 'python:False',
21            'is_searchabletext': 0,
22            'acl_read_permissions': '',
23            'acl_read_roles': '',
24            'acl_read_expr': '',
25            'acl_write_permissions': '',
26            'acl_write_roles': '',
27            'acl_write_expr': '',
28            'read_ignore_storage': False,
29            'read_process_expr': '',
30            'read_process_dependent_fields': (),
31            'write_ignore_storage': False,
32            'write_process_expr': '',
33        },
34    },
35    'faculty': {
36        'type': 'CPS String Field',
37        'data': {
38            'default_expr': 'string:',
39            'is_searchabletext': True,
40            'acl_read_permissions': '',
41            'acl_read_roles': '',
42            'acl_read_expr': '',
43            'acl_write_permissions': '',
44            'acl_write_roles': '',
45            'acl_write_expr': '',
46            'read_ignore_storage': False,
47            'read_process_expr': '',
48            'read_process_dependent_fields': (),
49            'write_ignore_storage': False,
50            'write_process_expr': '',
51        },
52    },
[106]53    'course': {
54        'type': 'CPS String Field',
55        'data': {
56            'default_expr': 'string:',
57            'is_searchabletext': True,
58            'acl_read_permissions': '',
59            'acl_read_roles': '',
60            'acl_read_expr': '',
61            'acl_write_permissions': '',
62            'acl_write_roles': '',
63            'acl_write_expr': '',
64            'read_ignore_storage': False,
65            'read_process_expr': '',
66            'read_process_dependent_fields': (),
67            'write_ignore_storage': False,
68            'write_process_expr': '',
69        },
70    },
[107]71    'accommodation_sc_id': {
[106]72        'type': 'CPS String Field',
73        'data': {
74            'default_expr': 'string:',
75            'is_searchabletext': True,
76            'acl_read_permissions': '',
77            'acl_read_roles': '',
78            'acl_read_expr': '',
79            'acl_write_permissions': '',
80            'acl_write_roles': '',
81            'acl_write_expr': '',
82            'read_ignore_storage': False,
83            'read_process_expr': '',
84            'read_process_dependent_fields': (),
85            'write_ignore_storage': False,
86            'write_process_expr': '',
87        },
88    },
[107]89    'accommodation_sc_pin': {
[106]90        'type': 'CPS String Field',
91        'data': {
92            'default_expr': 'string:',
93            'is_searchabletext': True,
94            'acl_read_permissions': '',
95            'acl_read_roles': '',
96            'acl_read_expr': '',
97            'acl_write_permissions': '',
98            'acl_write_roles': '',
99            'acl_write_expr': '',
100            'read_ignore_storage': False,
101            'read_process_expr': '',
102            'read_process_dependent_fields': (),
103            'write_ignore_storage': False,
104            'write_process_expr': '',
105        },
106    },
[47]107}
108#
109###)
110
111student_personal_schema = { ###(
112     'firstname': {
113        'type': 'CPS String Field',
114        'data': {
115            'is_searchabletext': 1,
116        },
[20]117    },
[47]118    'middlename': {
119        'type': 'CPS String Field',
120        'data': {
121            'is_searchabletext': 1,
122        },
123    },
124     'lastname': {
125        'type': 'CPS String Field',
126        'data': {
127            'is_searchabletext': 1,
128        },
129    },
130     'sex': {
131        'type': 'CPS Boolean Field',
[68]132        'default_expr': 'python:True',
[47]133        'data': {
134            'is_searchabletext': 1,
135        },
136    },
137     'birthday': {
138        'type': 'CPS DateTime Field',
139        'data': {
140            'is_searchabletext': 1,
141        },
142    },
[57]143     'age': {
144        'type': 'CPS DateTime Field',
145        'data': {
146            'is_searchabletext': 1,
147        },
148    },
149     'state': {
150        'type': 'CPS DateTime Field',
151        'data': {
152            'is_searchabletext': 1,
153        },
154    },
[19]155}
[47]156###)
157
158jamb_schema = { ###(
[19]159    'reg_nr': {
160        'type': 'CPS String Field',
161        'data': {
162            'default_expr': 'string:',
163            'is_searchabletext': True,
164        },
165    },
[47]166    'admission_sc_id': {
[19]167        'type': 'CPS String Field',
168        'data': {
169            'is_searchabletext': True,
170        },
171    },
[47]172    'admission_sc_pin': {
173        'type': 'CPS String Field',
[19]174        'data': {
[47]175            'is_searchabletext': True,
[19]176        },
177    },
[47]178    'admission_sc_pin_usage': {
179        'type': 'CPS Int Field',
[19]180        'data': {
[29]181            'default_expr': 'python:0',
[19]182            'is_searchabletext': False,
[57]183            },
184    },
185     'firstname': {
186        'type': 'CPS String Field',
187        'data': {
188            'is_searchabletext': 1,
[19]189        },
190    },
[57]191    'middlename': {
[19]192        'type': 'CPS String Field',
193        'data': {
[57]194            'is_searchabletext': 1,
[19]195        },
196    },
[57]197     'lastname': {
198        'type': 'CPS String Field',
199        'data': {
200            'is_searchabletext': 1,
201        },
202    },
[47]203    'age': {
204        'type': 'CPS Int Field',
[19]205        'data': {
[47]206            'default_expr': 'python:20',
207            'is_searchabletext': False,
[19]208        },
209    },
[47]210    'sex': {
211        'type': 'CPS Boolean Field',
[19]212        'data': {
[47]213            'default_expr': 'python:0',
[19]214            'is_searchabletext': False,
215        },
216    },
[57]217    'state': {
[19]218        'type': 'CPS String Field',
219        'data': {
220            'default_expr': 'string:',
[57]221            'is_searchabletext': False,
[19]222        },
223    },
[47]224    'exam_results': {
[19]225        'type': 'CPS String Field',
226        'data': {
227            'default_expr': 'string:',
228        },
229    },
[47]230    'aggregate': {
231        'type': 'CPS String Field',
[25]232        'data': {
[47]233            'default_expr': 'string:',
234            'is_searchabletext': False,
[25]235        },
[47]236    },
[57]237    'faculty': {
[25]238        'type': 'CPS String Field',
239        'data': {
[47]240            'default_expr': 'string:',
241            'is_searchabletext': False,
[25]242        },
243    },
[106]244    'course': {
245        'type': 'CPS String Field',
246        'data': {
247            'default_expr': 'string:',
248            'is_searchabletext': False,
249        },
250    },
[57]251    'listing_date': {
252        'type': 'CPS DateTime Field',
[25]253        'data': {
[57]254            'is_searchabletext': False,
[25]255        },
256    },
[57]257##    '2nd_choice': { ###(
258##        'type': 'CPS String Field',
259##        'data': {
260##            'default_expr': 'string:',
261##            'is_searchabletext': False,
262##            'acl_read_permissions': '',
263##            'acl_read_roles': '',
264##            'acl_read_expr': '',
265##            'acl_write_permissions': '',
266##            'acl_write_roles': '',
267##            'acl_write_expr': '',
268##            'read_ignore_storage': False,
269##            'read_process_expr': '',
270##            'read_process_dependent_fields': (),
271##            'write_ignore_storage': False,
272##            'write_process_expr': '',
273##        },
274##    },
275##    '3rd_choice': {
276##        'type': 'CPS String Field',
277##        'data': {
278##            'default_expr': 'string:',
279##            'is_searchabletext': True,
280##            'acl_read_permissions': '',
281##            'acl_read_roles': '',
282##            'acl_read_expr': '',
283##            'acl_write_permissions': '',
284##            'acl_write_roles': '',
285##            'acl_write_expr': '',
286##            'read_ignore_storage': False,
287##            'read_process_expr': '',
288##            'read_process_dependent_fields': (),
289##            'write_ignore_storage': False,
290##            'write_process_expr': '',
291##        },
292##    },
293###)
[25]294}
[47]295
[57]296
[47]297###)
298
[68]299faculty_schema = { ###(
300}###)
301
302department_schema = { ###(
303}###)
304
305course_schema = { ###(
[96]306    'heading': {
307        'type': 'CPS String Field',
308        'data': {
309            'default_expr': 'string:',
310            'is_searchabletext': True,
311        },
312    },
313    'text': {
314        'type': 'CPS String Field',
315        'data': {
316            'default_expr': 'string:',
317            'is_searchabletext': True,
318        },
319    },
[68]320    'level': {
321        'type': 'CPS String Field',
322        'data': {
323            'default_expr': 'string:',
324            'is_searchabletext': True,
325        },
326    },
327    'code': {
328        'type': 'CPS String Field',
329        'data': {
330            'default_expr': 'string:',
331            'is_searchabletext': True,
332        },
333    },
334    'semester': {
335        'type': 'CPS Boolean Field',
336        'data': {
337            'default_expr': 'python:True',
338            'is_searchabletext': False,
339        },
340    },
341    'credit': {
342        'type': 'CPS Int Field',
343        'data': {
344            'default_expr': 'string:',
345            'is_searchabletext': False,
346        },
347    },
348    'core_elective': {
349        'type': 'CPS Boolean Field',
350        'data': {
351            'default_expr': 'python:True',
352            'is_searchabletext': False,
353        },
354    },
355}###)
356
[103]357accommodation = { ###(
[101]358    'heading': {
359        'type': 'CPS String Field',
360        'data': {
361            'is_searchabletext': True,
362        },
363    },
364    'text': {
365        'type': 'CPS String Field',
366        'data': {
367            'is_searchabletext': True,
368        },
369    },
[103]370    'which_sex': {
371        'type': 'CPS Boolean Field',
[101]372        'data': {
373            'is_searchabletext': True,
374        },
375    },
[103]376    'nr_of_blocks': {
377        'type': 'CPS Int Field',
[101]378        'data': {
[103]379            'is_searchabletext': False,
[101]380        },
381    },
[103]382    'nr_of_floors': {
383        'type': 'CPS Int Field',
[101]384        'data': {
385            'is_searchabletext': False,
386        },
387    },
[103]388    'rooms_per_floor': {
[101]389        'type': 'CPS Int Field',
390        'data': {
391            'is_searchabletext': False,
392        },
393    },
[103]394    'beds_per_room': {
395        'type': 'CPS Int Field',
[101]396        'data': {
397            'is_searchabletext': False,
398        },
399    },
[107]400    'beds_assigned': {
401        'type': 'CPS Int Field',
402        'data': {
403            'is_searchabletext': False,
404        },
405    },
406    'beds_assigned_list': {
407        'type': 'CPS String List Field',
408        'data': {
409            'is_searchabletext': False,
410        },
411    },
[101]412}###)
413
[47]414##scratch_card = { ###(
415####   'allow_discussion': {
416####        'type': 'CPS Int Field',
417####        'data': {
418####            'default_expr': 'python:0',
419####            'is_searchabletext': 0,
420####            },
421####        },
422##     'sc_id': {
423##        'type': 'CPS String Field',
424##        'data': {
425##            'default_expr': '',
426##            'is_searchabletext': 0,
427##            'acl_read_permissions': '',
428##            'acl_read_roles': '',
429##            'acl_read_expr': '',
430##            'acl_write_permissions': '',
431##            'acl_write_roles': '',
432##            'acl_write_expr': '',
433##            'read_ignore_storage': False,
434##            'read_process_expr': '',
435##            'read_process_dependent_fields': (),
436##            'write_ignore_storage': False,
437##            'write_process_expr': '',
438##        },
439##    },
440##     'sc_pin': {
441##        'type': 'CPS String Field',
442##        'data': {
443##            'default_expr': '',
444##            'is_searchabletext': 0,
445##            'acl_read_permissions': '',
446##            'acl_read_roles': '',
447##            'acl_read_expr': '',
448##            'acl_write_permissions': '',
449##            'acl_write_roles': '',
450##            'acl_write_expr': '',
451##            'read_ignore_storage': False,
452##            'read_process_expr': '',
453##            'read_process_dependent_fields': (),
454##            'write_ignore_storage': False,
455##            'write_process_expr': '',
456##        },
457##    },
458##}
[19]459schemas = {}
[47]460###)
461
[45]462schemas['university'] = university_schema
[113]463schemas['academics'] = academics_folder_schema
[45]464schemas['students'] = students_folder_schema
[19]465schemas['student'] = student_schema
[47]466schemas['student_personal'] = student_personal_schema
[103]467schemas['accommodation'] = accommodation
[19]468schemas['jamb'] = jamb_schema
[78]469#schemas['scratch_card'] = scratch_card
470schemas['faculty'] = faculty_schema
471schemas['department'] = department_schema
[68]472schemas['course'] = course_schema
[19]473
474return schemas
Note: See TracBrowser for help on using the repository browser.