- Timestamp:
- 25 Sep 2006, 10:40:18 (18 years ago)
- Location:
- WAeUP_SRP/trunk
- Files:
-
- 6 added
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
WAeUP_SRP/trunk/Widgets.py
r537 r551 139 139 140 140 widgetRegistry.register(CertificateCourseIdWidget) 141 ###) 142 143 144 class CourseIdWidget(CPSStringWidget): ###( 145 """ CourseId Widget""" 146 meta_type = "CourseId Widget" 147 148 def validate(self, datastructure, **kw): 149 """Validate datastructure and update datamodel.""" 150 151 valid = CPSStringWidget.validate(self, datastructure, **kw) 152 if not valid: 153 return 0 154 else: 155 widget_id = self.getWidgetId() 156 value = datastructure[widget_id].upper() 157 err = 0 158 res = self.portal_catalog(meta_type= "Course",id = value) 159 if len(res) > 0: 160 err = 'Course %s already exists' % (value) 161 if err: 162 datastructure.setError(widget_id, err) 163 else: 164 datamodel = datastructure.getDataModel() 165 datamodel[self.fields[0]] = value 166 167 return not err 168 169 InitializeClass(CourseIdWidget) 170 171 widgetRegistry.register(CourseIdWidget) 141 172 142 173 -
WAeUP_SRP/trunk/profiles/default/layouts/certificate.xml
r486 r551 7 7 <property name="flexible_widgets"/> 8 8 <property name="validate_values_expr"></property> 9 <widget name="Description" meta_type="Text Widget"> 10 <property name="fields"> 11 <element value="Description"/> 12 </property> 13 <property name="label">Description</property> 14 <property name="label_edit">Description</property> 15 <property name="is_i18n">True</property> 16 <property name="hidden_layout_modes"/> 17 <property name="css_class">description</property> 18 <property name="width">72</property> 19 </widget> 20 <widget name="Title" meta_type="String Widget"> 21 <property name="fields"> 22 <element value="Title"/> 23 </property> 24 <property name="is_required">True</property> 25 <property name="label">Title</property> 26 <property name="label_edit">Title</property> 27 <property name="display_width">40</property> 28 <property name="size_max">200</property> 29 </widget> 30 <widget name="code" meta_type="WAeUPId Widget"> 31 <property name="title">Certificate ID</property> 32 <property name="fields"> 33 <element value="code"/> 34 </property> 35 <property name="is_required">True</property> 36 <property name="label">Certificate ID</property> 37 <property name="label_edit">Certificate ID</property> 38 <property name="readonly_layout_modes"/> 39 <property name="hidden_layout_modes"> 40 <element value="view"/> 41 <element value="edit"/> 42 </property> 43 <property name="hidden_readonly_layout_modes"/> 44 </widget> 9 45 <widget name="admin_status" meta_type="String Widget"> 10 46 <property name="title">Admin Status</property> … … 116 152 <property name="label">Original Code</property> 117 153 <property name="label_edit">Original Code</property> 118 <property name="readonly_layout_modes"/> 119 <property name="hidden_layout_modes"/> 154 <property name="readonly_layout_modes"> 155 <element value="edit"/> 156 </property> 157 <property name="hidden_layout_modes" > 158 <element value="create"/> 159 </property> 120 160 <property name="hidden_readonly_layout_modes"/> 121 161 </widget> … … 156 196 <table> 157 197 <row> 198 <cell name="code"/> 199 </row> 200 <row> 201 <cell name="Title"/> 202 </row> 203 <row> 204 <cell name="Description"/> 205 </row> 206 <row> 158 207 <cell name="original_code"/> 159 208 </row> -
WAeUP_SRP/trunk/profiles/default/layouts/department.xml
r486 r551 29 29 </widget> 30 30 <widget name="code" meta_type="WAeUPId Widget"> 31 <property name="title"> Object ID</property>31 <property name="title">Department ID</property> 32 32 <property name="fields"> 33 33 <element value="code"/> 34 34 </property> 35 35 <property name="is_required">True</property> 36 <property name="label"> Object ID</property>37 <property name="label_edit"> Object ID</property>36 <property name="label">Department ID</property> 37 <property name="label_edit">Department ID</property> 38 38 <property name="readonly_layout_modes"/> 39 39 <property name="hidden_layout_modes"> 40 40 <element value="view"/> 41 41 <element value="edit"/> 42 </property>43 <property name="hidden_readonly_layout_modes"/>44 </widget>45 <widget name="code_alt" meta_type="String Widget">46 <property name="title">Object ID</property>47 <property name="fields">48 <element value="code"/>49 </property>50 <property name="label">Object ID</property>51 <property name="label_edit">Object ID</property>52 <property name="readonly_layout_modes"/>53 <property name="hidden_layout_modes">54 <element value="edit"/>55 <element value="view"/>56 42 </property> 57 43 <property name="hidden_readonly_layout_modes"/> -
WAeUP_SRP/trunk/profiles/default/layouts/faculty.xml
r486 r551 39 39 <property name="hidden_readonly_layout_modes"/> 40 40 </widget> 41 <widget name="code" meta_type="WAeUPId Widget"> 42 <property name="title">Faculty ID</property> 43 <property name="fields"> 44 <element value="code"/> 45 </property> 46 <property name="label">Faculty ID</property> 47 <property name="label_edit">Faculty ID</property> 48 <property name="readonly_layout_modes"> 49 <element value="edit"/> 50 </property> 51 <property name="hidden_layout_modes"> 52 <element value="edit"/> 53 </property> 54 <property name="hidden_readonly_layout_modes"/> 55 </widget> 41 56 <widget name="college_code" meta_type="String Widget"> 42 57 <property name="title">College Code</property> … … 75 90 <table> 76 91 <row> 92 <cell name="code"/> 93 </row> 94 <row> 95 <cell name="Title"/> 96 </row> 97 <row> 77 98 <cell name="title_prefix"/> 78 99 </row> -
WAeUP_SRP/trunk/skins/waeup_academics/academics_index.py
r542 r551 27 27 28 28 if isManager: 29 if context.portal_type == 'AcademicsFolder': 30 return context.academics.academics_index_view() 31 elif context.portal_type == 'Faculty': 32 return context.faculty_index_view() 29 33 return redirect("%s/academics_contents" % context.absolute_url()) 30 34 if isStudent: -
WAeUP_SRP/trunk/skins/waeup_custom/logged_in.py
r537 r551 32 32 utool = context.portal_url 33 33 mtool = context.portal_membership 34 wftool = context.portal_workflow 34 35 portal = utool.getPortalObject() 35 36 portal_absolute_url = portal.absolute_url() … … 83 84 member.setProperties(last_login_time=current,login_time=current) 84 85 if info['review_state'] == "application_pin_entered": 86 wftool.doActionFor(info['app'],'open',dest_container=info['app']) 85 87 return response.redirect("%s/passport_entry_view" % student.absolute_url()) 86 88 return response.redirect("%s" % student.absolute_url()) -
WAeUP_SRP/trunk/skins/waeup_default/layout_waeup_create.pt
r486 r551 1 <tal:block define="global creation python:1; 2 global formaction string:apply_admission" /> 1 <tal:block define="global creation python:1" /> 3 2 <metal:block use-macro="here/layout_waeup_edit/macros/default_edit" /> -
WAeUP_SRP/trunk/skins/waeup_default/layout_waeup_edit.pt
r486 r551 20 20 cpsmcat nocall:here/translation_service; 21 21 "> 22 <tal:block condition="python: 1 orfirst_layout">22 <tal:block condition="python:first_layout"> 23 23 <tal:block 24 24 content="structure string:<form id='editForm' action='${formaction}' method='post'
Note: See TracChangeset for help on using the changeset viewer.