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

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

=academics created

  • Property svn:keywords set to Id
File size: 11.9 KB
Line 
1#-*- mode: python; mode: fold -*-
2# $Id: getWAeUPSchemas.py 113 2005-10-28 10:17:39Z joachim $
3
4university_schema = { ###(
5}
6###)
7
8students_folder_schema = { ###(
9}
10###)
11
12academics_folder_schema = { ###(
13}
14###)
15
16student_schema = { ###(
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    },
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    },
71    'accommodation_sc_id': {
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    },
89    'accommodation_sc_pin': {
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    },
107}
108#
109###)
110
111student_personal_schema = { ###(
112     'firstname': {
113        'type': 'CPS String Field',
114        'data': {
115            'is_searchabletext': 1,
116        },
117    },
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',
132        'default_expr': 'python:True',
133        'data': {
134            'is_searchabletext': 1,
135        },
136    },
137     'birthday': {
138        'type': 'CPS DateTime Field',
139        'data': {
140            'is_searchabletext': 1,
141        },
142    },
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    },
155}
156###)
157
158jamb_schema = { ###(
159    'reg_nr': {
160        'type': 'CPS String Field',
161        'data': {
162            'default_expr': 'string:',
163            'is_searchabletext': True,
164        },
165    },
166    'admission_sc_id': {
167        'type': 'CPS String Field',
168        'data': {
169            'is_searchabletext': True,
170        },
171    },
172    'admission_sc_pin': {
173        'type': 'CPS String Field',
174        'data': {
175            'is_searchabletext': True,
176        },
177    },
178    'admission_sc_pin_usage': {
179        'type': 'CPS Int Field',
180        'data': {
181            'default_expr': 'python:0',
182            'is_searchabletext': False,
183            },
184    },
185     'firstname': {
186        'type': 'CPS String Field',
187        'data': {
188            'is_searchabletext': 1,
189        },
190    },
191    'middlename': {
192        'type': 'CPS String Field',
193        'data': {
194            'is_searchabletext': 1,
195        },
196    },
197     'lastname': {
198        'type': 'CPS String Field',
199        'data': {
200            'is_searchabletext': 1,
201        },
202    },
203    'age': {
204        'type': 'CPS Int Field',
205        'data': {
206            'default_expr': 'python:20',
207            'is_searchabletext': False,
208        },
209    },
210    'sex': {
211        'type': 'CPS Boolean Field',
212        'data': {
213            'default_expr': 'python:0',
214            'is_searchabletext': False,
215        },
216    },
217    'state': {
218        'type': 'CPS String Field',
219        'data': {
220            'default_expr': 'string:',
221            'is_searchabletext': False,
222        },
223    },
224    'exam_results': {
225        'type': 'CPS String Field',
226        'data': {
227            'default_expr': 'string:',
228        },
229    },
230    'aggregate': {
231        'type': 'CPS String Field',
232        'data': {
233            'default_expr': 'string:',
234            'is_searchabletext': False,
235        },
236    },
237    'faculty': {
238        'type': 'CPS String Field',
239        'data': {
240            'default_expr': 'string:',
241            'is_searchabletext': False,
242        },
243    },
244    'course': {
245        'type': 'CPS String Field',
246        'data': {
247            'default_expr': 'string:',
248            'is_searchabletext': False,
249        },
250    },
251    'listing_date': {
252        'type': 'CPS DateTime Field',
253        'data': {
254            'is_searchabletext': False,
255        },
256    },
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###)
294}
295
296
297###)
298
299faculty_schema = { ###(
300}###)
301
302department_schema = { ###(
303}###)
304
305course_schema = { ###(
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    },
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
357accommodation = { ###(
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    },
370    'which_sex': {
371        'type': 'CPS Boolean Field',
372        'data': {
373            'is_searchabletext': True,
374        },
375    },
376    'nr_of_blocks': {
377        'type': 'CPS Int Field',
378        'data': {
379            'is_searchabletext': False,
380        },
381    },
382    'nr_of_floors': {
383        'type': 'CPS Int Field',
384        'data': {
385            'is_searchabletext': False,
386        },
387    },
388    'rooms_per_floor': {
389        'type': 'CPS Int Field',
390        'data': {
391            'is_searchabletext': False,
392        },
393    },
394    'beds_per_room': {
395        'type': 'CPS Int Field',
396        'data': {
397            'is_searchabletext': False,
398        },
399    },
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    },
412}###)
413
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##}
459schemas = {}
460###)
461
462schemas['university'] = university_schema
463schemas['academics'] = academics_folder_schema
464schemas['students'] = students_folder_schema
465schemas['student'] = student_schema
466schemas['student_personal'] = student_personal_schema
467schemas['accommodation'] = accommodation
468schemas['jamb'] = jamb_schema
469#schemas['scratch_card'] = scratch_card
470schemas['faculty'] = faculty_schema
471schemas['department'] = department_schema
472schemas['course'] = course_schema
473
474return schemas
Note: See TracBrowser for help on using the repository browser.