Changeset 190
- Timestamp:
- 17 Nov 2005, 13:18:53 (19 years ago)
- Location:
- waeup_product/trunk/skins
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
waeup_product/trunk/skins/waeup_default/getWAeUPLayouts.py
r189 r190 1015 1015 'layout': { 1016 1016 'style_prefix': 'layout_waeup_', 1017 'layout_edit_method': 'layout_eligibility_create', 1018 'layout_create_method': 'layout_eligibility_create', 1017 1019 'flexible_widgets': (), 1018 1020 'ncols': 1, 1019 1021 'rows': [ 1020 1022 #[{'widget_id': 'jamb_results', 'ncols': 1},], 1021 #[{'widget_id': 'jamb_aggregate', 'ncols': 1},],1023 [{'widget_id': 'jamb_aggregate', 'ncols': 1},], 1022 1024 #[{'widget_id': 'jamb_listing_date', 'ncols': 1},], 1023 1025 [{'widget_id': 'faculty', 'ncols': 1},], … … 1036 1038 'rows': [ 1037 1039 #[{'widget_id': 'jamb_results', 'ncols': 1},], 1038 #[{'widget_id': 'jamb_aggregate', 'ncols': 1},],1040 [{'widget_id': 'jamb_aggregate', 'ncols': 1},], 1039 1041 #[{'widget_id': 'jamb_listing_date', 'ncols': 1},], 1040 1042 [{'widget_id': 'faculty', 'ncols': 1},], -
waeup_product/trunk/skins/waeup_default/getWAeUPSchemas.py
r179 r190 503 503 'type': 'CPS String Field', 504 504 'data': { 505 'default_expr': 'string:',506 505 'is_searchabletext': False, 507 506 }, -
waeup_product/trunk/skins/waeup_student/eligibility.py
r189 r190 20 20 21 21 validate = fhas('add') or fhas('change') or fhas('delete') 22 23 #form['widget__jamb_results'] = eli.jamb_results 24 #form['widget__jamb_aggregate'] =eli.jamb_aggregate 25 form['widget__faculty'] =eli.faculty 26 form['widget__course'] =eli.course 27 res,psm,ds = lt.renderLayout(layout_id= 'student_eligibility_edit', 22 data = {'faculty': eli.faculty, 23 'course': eli.course, 24 'jamb_aggregate': eli.jamb_aggregate, 25 } 26 res,psm,ds = lt.renderLayout(layout_id= 'student_eligibility', 28 27 schema_id= 'student_eligibility', 29 28 context=context, 30 mapping= request,31 ob= {},29 mapping=validate and request, 30 ob=data, 32 31 layout_mode='create', 33 32 formaction = "eligibility", 34 33 schoolresults = sr, 35 34 ) 36 35 if psm == 'invalid': 36 return context.eligibility_form(rendered = res, 37 psm = 'Please correct your errors', 38 ds = ds, 39 ) 40 elif psm == '': 41 return context.eligibility_form(rendered = res, 42 psm = psm, 43 ds = ds, 44 ) 37 45 inr = 0 38 rset('ds',ds)39 46 if fhas('add') and (fget('type') or fget('subject') or fget('result')): 40 47 sr.append((fget('type'),fget('subject'),fget('result'))) … … 54 61 sr = new 55 62 psm = "%s items deleted" % inr 56 else: 57 psm = '' 63 elif psm == 'valid': 64 psm = "your changes have been saved" 65 58 66 ds.set('schoolresults',sr) 59 eli.edit(mapping={'schoolresults':sr, 60 'jamb_aggregate': fget('widget__aggregate'), 61 }) 62 #eli.edit(mapping=ds) 63 res,dummy,ds = lt.renderLayout(layout_id= 'student_eligibility_edit', 67 eli.edit(mapping=ds) 68 res,dummy,fds = lt.renderLayout(layout_id= 'student_eligibility', 64 69 schema_id= 'student_eligibility', 65 70 context=context, … … 72 77 73 78 return context.eligibility_form(rendered = res, 74 #psm = str(ds),79 #psm = "%s <br /> %s" % (str(ds),str(lt.student_eligibility.getLayoutDefinition())) 75 80 psm = psm, 76 81 ) 77 ##elif psm == '':78 ## return context.eligibility_form(rendered = res,79 ## psm = None,80 ## ds = ds,81 ## )82 ##elif psm == 'valid':83 ## s_personal = context.PERSONAL.getContent()84 ## s_personal.edit(mapping={'email': ds.get('email')})85 ## #pw = REQUEST.get("widget__pw")86 ## #pm.setPassword(pw)87 ##psm = 'Email has been successfully set.'88 ##return context.REQUEST.RESPONSE.redirect('%s' % context.portal_url.getUrlFromRpath('/students'))89 ##90 ####return context.eligibility_form(rendered = res,91 #### psm = psm,92 #### ds = ds,93 #### )
Note: See TracChangeset for help on using the changeset viewer.