Changeset 4558
- Timestamp:
- 16 Dec 2009, 09:56:53 (15 years ago)
- Location:
- WAeUP_SRP/trunk
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
WAeUP_SRP/trunk/WAeUPImport.py
r4531 r4558 64 64 #self.current = DateTime.DateTime().strftime("%d-%m-%y_%H_%M_%S") 65 65 self.waeup_tool = waeup_tool 66 self.session = waeup_tool.getSessionId()[0] 66 67 self.academics_folder = waeup_tool.portal_url.getPortalObject().campus.academics 67 68 self.schema_tool = getToolByName(waeup_tool, 'portal_schemas') … … 784 785 ) 785 786 }, 786 # 'StudentStudyLevel': 787 # {'id': 'current_level', 788 # 'title': '', 789 # 'wf_transition_return': 'open', 790 # 'wf_transition_admit': 'remain', 791 # 'fields': 792 # ('verdict', 793 # 'session', 794 # ) 795 # }, 787 'StudentAccommodation': 788 {'id': 'accommodation_final', 789 'title': '', 790 'wf_transition_return': 'remain', 791 'wf_transition_admit': 'remain', 792 'wf_transition_graduate': 'remain', 793 'wf_transition_pay_school_fee': 'remain', 794 'wf_transition_validate_courses': 'remain', 795 'fields': 796 ('acco_maint_date', 797 'acco_maint_code', 798 'acco_maint_fee', 799 'acco_maint_sc_pin', 800 'acco_maint_pay_id', 801 'acco_res_date', 802 'acco_res_sc_pin', 803 'bed', 804 'session', 805 'student_status', 806 ) 807 }, 796 808 'PaymentsFolder': 797 809 {'id': 'payments', … … 852 864 break 853 865 for pt in f2t.keys(): 854 student_obj.invokeFactory(pt,f2t[pt]['id']) 866 if pt == 'StudentAccommodation': 867 if mapping.get('bed',None): 868 student_obj.invokeFactory(pt,f2t[pt]['id']) 869 else: 870 continue 871 else: 872 student_obj.invokeFactory(pt,f2t[pt]['id']) 855 873 sub_obj = getattr(student_obj,f2t[pt]['id']) 856 874 sub_doc = sub_obj.getContent() … … 942 960 'disabled', 943 961 ), 962 'accommodation': 963 ('acco_maint_date', 964 'acco_maint_code', 965 'acco_maint_fee', 966 'acco_maint_sc_pin', 967 'acco_maint_pay_id', 968 'acco_res_date', 969 'acco_res_sc_pin', 970 'bed', 971 'session', 972 'student_status', 973 ), 944 974 } 945 975 946 sub_types = ['StudentApplication','StudentClearance','StudentPersonal','StudentStudyCourse' ]976 sub_types = ['StudentApplication','StudentClearance','StudentPersonal','StudentStudyCourse','StudentAccommodation'] 947 977 non_image_keys = {} 948 978 for i in sub_types: … … 962 992 non_image_keys['clearance'].remove('lastname') 963 993 toexport = non_image_keys 964 994 #import pdb;pdb.set_trace() 965 995 while True: 966 996 if hasattr(students_folder,student_id): … … 993 1023 d = {'student_id':student_id,'reg_state':student.review_state,'import_mode':'create'} 994 1024 for k in toexport.keys()[0:]: 1025 if k.startswith('acco'): 1026 session = self.session 1027 subobject = 'accommodation_' + session 1028 else: 1029 subobject = k 995 1030 try: 996 object = getattr(student_obj, k)1031 object = getattr(student_obj,subobject) 997 1032 object_doc = object.getContent() 998 1033 except: 1034 for f in toexport[k]: 1035 d[f] = '' 999 1036 continue 1000 1037 for f in toexport[k]: -
WAeUP_SRP/trunk/WAeUPTool.py
r4548 r4558 1282 1282 if os.path.exists(picture_path) or not os.path.exists(orig_path): 1283 1283 return False 1284 os.rename( picture_path + "_removed",picture_path)1284 os.rename(orig_path,picture_path) 1285 1285 return True 1286 1286 ###) -
WAeUP_SRP/trunk/profiles/default/schemas/import_student.xml
r3987 r4558 45 45 <field name="disabled" meta_type="CPS Boolean Field"/> 46 46 47 <field name="acco_maint_date" meta_type="CPS DateTime Field"/> 48 <field name="acco_maint_code" meta_type="CPS String Field"/> 49 <field name="acco_maint_fee" meta_type="CPS String Field"/> 50 <field name="acco_maint_sc_pin" meta_type="CPS String Field"/> 51 <field name="acco_maint_pay_id" meta_type="CPS String Field"/> 52 <field name="acco_res_date" meta_type="CPS DateTime Field"/> 53 <field name="acco_res_sc_pin" meta_type="CPS String Field"/> 54 <field name="bed" meta_type="CPS String Field"/> 55 <field name="session" meta_type="CPS String Field"/> 56 <field name="student_status" meta_type="CPS String Field"/> 57 47 58 <field name="password" meta_type="CPS String Field"/> 48 59 </object> -
WAeUP_SRP/trunk/profiles/default/vocabularies/searchable_student_states.xml
r3689 r4558 7 7 <property name="acl_write_roles">Manager</property> 8 8 <item key="all" msgid="">all states</item> 9 <item key="graduated" msgid="">graduated</item> 9 10 <item key="returning" msgid="">returning</item> 10 11 <item key="school_fee_paid" msgid="">school fee paid</item> -
WAeUP_SRP/trunk/profiles/uniben/actions.xml
r4544 r4558 19 19 <permission>View</permission> 20 20 </action> 21 <action title="Alumni" action_id="view_ students" category="navigation"21 <action title="Alumni" action_id="view_alumni" category="navigation" 22 22 condition_expr="python:portal.campus.students.isStaff() and portal.portal_url().find('alumni') >-1" 23 23 url_expr="string:${portal_url}/campus/students" visible="True">
Note: See TracChangeset for help on using the changeset viewer.