Changeset 1709
- Timestamp:
- 25 Apr 2007, 16:06:28 (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
WAeUP_SRP/trunk/Students.py
r1707 r1709 546 546 wftool = self.portal_workflow 547 547 students_folder = self.portal_catalog({'meta_type': 'StudentsFolder'})[-1].getObject() 548 entry_levels = {'ume_ft':'100', 549 'de_ft': '200', 550 'ug_pt': '100', 551 'de_pt': '200', 552 'pg_ft': '700', 553 'pg_pt': '700', 554 } 548 555 csv_d = {'jamb_reg_no': "reg_no", 549 556 'entry_mode': 'entry_mode', … … 620 627 da["jamb_lastname"] = lastname 621 628 catalog_entry['entry_session'] = da["entry_session"] = self.getSessionId()[-2:] 622 catalog_entry['entry_level'] = da["entry_level"] = 'NA'623 629 catalog_entry['sex'] = sex = result.get(csv_d['jamb_sex']).startswith('F') 624 630 da_fields = ('jamb_reg_no', … … 632 638 catalog_entry['email'] = da['app_email'] 633 639 catalog_entry['entry_mode'] = da['entry_mode'] 640 catalog_entry['entry_level'] = da["entry_level"] = entry_levels.get(da['entry_mode'],'NA') 634 641 app = student.application 635 642 app_doc = app.getContent() … … 673 680 clearance = student.clearance 674 681 date_str = result.get(csv_d['birthday']) 675 date = DateTime.DateTime(date_str) 682 try: 683 date = DateTime.DateTime(date_str) 684 except: 685 #import pdb;pdb.set_trace() 686 date = None 676 687 dc['birthday'] = date 677 688 clearance.getContent().edit(mapping=dc) … … 685 696 #catalog_entry['level'] = getattr(cert_doc,'start_level') 686 697 catalog_entry['session'] = dsc['current_session'] = da['entry_session'] 687 catalog_entry['level'] = dsc['current_level'] = 'NA'698 catalog_entry['level'] = dsc['current_level'] = entry_levels.get(da['entry_mode'],'NA') 688 699 catalog_entry['mode'] = dsc['current_mode'] = da['entry_mode'] 689 700 catalog_entry['course'] = dsc['study_course'] = cert_id
Note: See TracChangeset for help on using the changeset viewer.