Changeset 764
- Timestamp:
- 27 Oct 2006, 11:04:57 (18 years ago)
- Location:
- WAeUP_SRP/trunk
- Files:
-
- 1 added
- 1 deleted
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
WAeUP_SRP/trunk/Students.py
r763 r764 246 246 'wrong': "Wrong", 247 247 'pume_eng_score': "EngScore", 248 'pume_tot_score': "GenScore", 248 'pume_gen_score': "GenScore", 249 'pume_tot_score': "Right", 249 250 'batch': "Batch", 250 251 'serial': "SerialNo", … … 333 334 dp_fields = ( 334 335 'pume_eng_score', 336 'pume_gen_score', 335 337 'pume_tot_score', 336 338 ) … … 618 620 ###) 619 621 620 ##security.declareProtected(View,'createSubObjects') ###(621 ##def createSubObjects(self):622 ##"""make the student a member"""623 ##dp = {'Title': 'Personal Data'}624 ##app_doc = self.application.getContent()625 ##names = app_doc.jamb_lastname.split()626 ##if len(names) == 3:627 ##dp['firstname'] = names[0].capitalize()628 ##dp['middlename'] = names[1].capitalize()629 ##dp['lastname'] = names[2].capitalize()630 ##elif len(names) == 2:631 ##dp['firstname'] = names[0].capitalize()632 ##dp['lastname'] = names[1].capitalize()633 ##else:634 ##dp['lastname'] = app_doc.jamb_lastname635 ##dp['sex'] = app_doc.jamb_sex == 'F'636 ##dp['lga'] = "%s/%s" % (app_doc.jamb_state,app_doc.jamb_lga )637 ##proxy = self.aq_parent638 ##proxy.invokeFactory('StudentPersonal','personal')639 ##per = proxy.personal640 ##per_doc = per.getContent()641 ##per_doc.edit(mapping = dp)642 ##per.manage_setLocalRoles(self.getId(), ['Owner',])643 ###self.portal_workflow.doActionFor(per,'open',dest_container=per)622 security.declareProtected(View,'createSubObjects') ###( 623 def createSubObjects(self): 624 """make the student a member""" 625 dp = {'Title': 'Personal Data'} 626 app_doc = self.application.getContent() 627 names = app_doc.jamb_lastname.split() 628 if len(names) == 3: 629 dp['firstname'] = names[0].capitalize() 630 dp['middlename'] = names[1].capitalize() 631 dp['lastname'] = names[2].capitalize() 632 elif len(names) == 2: 633 dp['firstname'] = names[0].capitalize() 634 dp['lastname'] = names[1].capitalize() 635 else: 636 dp['lastname'] = app_doc.jamb_lastname 637 dp['sex'] = app_doc.jamb_sex == 'F' 638 dp['lga'] = "%s/%s" % (app_doc.jamb_state,app_doc.jamb_lga ) 639 proxy = self.aq_parent 640 proxy.invokeFactory('StudentPersonal','personal') 641 per = proxy.personal 642 per_doc = per.getContent() 643 per_doc.edit(mapping = dp) 644 per.manage_setLocalRoles(self.getId(), ['Owner',]) 645 #self.portal_workflow.doActionFor(per,'open',dest_container=per) 644 646 645 647 ###) -
WAeUP_SRP/trunk/profiles/default/layouts/student_pume.xml
r759 r764 20 20 <property name="hidden_readonly_layout_modes"/> 21 21 </widget> 22 <widget name="pume_gen_ paper" meta_type="String Widget">23 <property name="title">PUME General Paper</property>22 <widget name="pume_gen_score" meta_type="String Widget"> 23 <property name="title">PUME General Score</property> 24 24 <property name="fields"> 25 <element value="pume_gen_ paper"/>25 <element value="pume_gen_score"/> 26 26 </property> 27 <property name="label">PUME General Paper</property>28 <property name="label_edit">PUME General Paper</property>27 <property name="label">PUME General Score</property> 28 <property name="label_edit">PUME General Score</property> 29 29 <property name="readonly_layout_modes"> 30 30 </property> … … 59 59 <table> 60 60 <row> 61 <cell name="pume_gen_ paper" ncols="3"/>61 <cell name="pume_gen_score" ncols="1"/> 62 62 </row> 63 63 <row> 64 <cell name="pume_eng_score" ncols=" 3"/>64 <cell name="pume_eng_score" ncols="1"/> 65 65 </row> 66 66 <row> 67 <cell name="pume_math_score" ncols=" 3"/>67 <cell name="pume_math_score" ncols="1"/> 68 68 </row> 69 69 <row> 70 <cell name="pume_tot_score" ncols="3"/> 71 </row> 72 <row> 73 <cell name="passport" ncols="3"/> 70 <cell name="pume_tot_score" ncols="1"/> 74 71 </row> 75 72 </table> -
WAeUP_SRP/trunk/profiles/default/schemas/student_pume.xml
r745 r764 2 2 <object name="student_pume" meta_type="CPS Schema"> 3 3 <field name="pume_eng_score" meta_type="CPS String Field"/> 4 <field name="pume_gen_ paper" meta_type="CPS String Field"/>4 <field name="pume_gen_score" meta_type="CPS String Field"/> 5 5 <field name="pume_math_score" meta_type="CPS String Field"/> 6 6 <field name="pume_tot_score" meta_type="CPS String Field"/>
Note: See TracChangeset for help on using the changeset viewer.