Changeset 2363 for WAeUP_SRP/base/skins/waeup_student
- Timestamp:
- 15 Oct 2007, 12:04:52 (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
WAeUP_SRP/base/skins/waeup_student/clearance_edit.py
r2013 r2363 49 49 ) 50 50 required_scans = ('fst_sit_scan', 51 'age_dec', 52 'birth_certificate', 51 53 # 'jamb_slip', 52 54 'ref_let', … … 96 98 logger.info('%s edited clearance object of %s' % (member_id,student_id )) 97 99 98 ## No idea why the following lines were still active until July 6.99 ## The code does not make any sense. When editing the clearance object100 ## as admin, always the PIN HOS-1-4921190317101 ## was filled in. This was the only PIN ever used by admin.102 103 #if clear_doc.clr_ac_pin == "":104 # res = context.portal_pins(student=member_id)105 # if res:106 # p = res[0].pin107 # if len(p) > 10:108 # pin = "%s-%s-%s" % (p[:3],p[3:4],p[4:])109 # else:110 # pin = p111 # clear_doc.edit(mapping={'clr_ac_pin': pin})112 113 ## simple method to remove the wrong PIN114 115 #if clear_doc.clr_ac_pin.startswith('HOS'):116 # pin=''117 # clear_doc.edit(mapping={'clr_ac_pin': pin})118 119 120 100 elif cpsdocument_edit_and_view_button: 121 101 if acknowledge and info['review_state'] == "clearance_pin_entered": 122 102 missing = False 123 files = clear_doc.objectIds()124 for scan in required_scans:125 if scan not in files:126 missing = True127 break128 if not missing:129 if not "age_dec" in files and not "birth_certificate" in files:130 missing = True131 if missing:103 #files = clear_doc.objectIds() 104 # for scan in required_scans: 105 # if scan not in files: 106 # missing = True 107 # break 108 # if not missing: 109 # if not "age_dec" in files and not "birth_certificate" in files: 110 # missing = True 111 if not context.waeup_tool.picturesExist(required_scans): 132 112 logger.info('%s requested clearance with documents missing' % (student_id)) 133 113 psm = "You have not uploaded all necessary documents to request clearance!"
Note: See TracChangeset for help on using the changeset viewer.