Changeset 3707
- Timestamp:
- 4 Oct 2008, 05:41:27 (16 years ago)
- Location:
- WAeUP_SRP/trunk
- Files:
-
- 2 added
- 18 deleted
- 12 edited
Legend:
- Unmodified
- Added
- Removed
-
WAeUP_SRP/trunk/CHANGES.txt
r3706 r3707 66 66 ----------------- 67 67 - add total_score to applicants_catalog 68 69 1.11 (2008-10-04) 70 ----------------- 71 - OIS customizations according to Issoufou's wish list of Oct 2 (2, 4, 5, 6, 7, 8) -
WAeUP_SRP/trunk/WAeUPTables.py
r3675 r3707 1557 1557 1558 1558 for field in self.schema(): 1559 d[field] = getattr(brain,field,'') 1560 1559 d[field] = getattr(brain,field,None) 1560 if repr(d[field]) == 'Missing.Value': 1561 d[field] = '' 1561 1562 d['weight'] = '' 1562 1563 d['grade'] = '' … … 1569 1570 if score and str(score).isdigit() and int(score) > 0: 1570 1571 score = int(score) 1571 grade,weight = self.getGradesFromScore(score )1572 grade,weight = self.getGradesFromScore(score,'') 1572 1573 gpa += weight * credits 1573 1574 d['weight'] = weight … … 1575 1576 d['score'] = score 1576 1577 1577 if str(brain.ca1).isdigit() and str(brain.ca2).isdigit() and str(brain.exam).isdigit(): 1578 d['score_calc'] = int(brain.ca1) + int(brain.ca2) + int(brain.exam) 1579 else: 1578 #if str(brain.ca1).isdigit() and str(brain.ca2).isdigit() and str(brain.exam).isdigit(): 1579 # d['score_calc'] = int(brain.ca1) + int(brain.ca2) + int(brain.exam) 1580 #else: 1581 # d['score_calc'] = '' 1582 try: 1583 d['score_calc'] = float(brain.ca1) + float(brain.ca2) + float(brain.exam) 1584 except: 1580 1585 d['score_calc'] = '' 1586 1587 if d['score_calc']: 1588 grade = self.getGradesFromScore(d['score_calc'],level_id) 1589 d['grade'] = grade 1581 1590 1582 1591 d['coe'] = '' -
WAeUP_SRP/trunk/profiles/ois/actions.xml
r3700 r3707 156 156 <action title="My Accommodation" action_id="reserve_accommodation" 157 157 category="student_navigation" condition_expr="member" 158 url_expr="string:${portal_url}/campus/students/${member}/reserve_accommodation" visible=" True"/>158 url_expr="string:${portal_url}/campus/students/${member}/reserve_accommodation" visible="False"/> 159 159 <action title="My Payments" action_id="payments" 160 160 category="student_navigation" condition_expr="member" -
WAeUP_SRP/trunk/profiles/ois/layouts/student_course_result.xml
r3699 r3707 7 7 <property name="flexible_widgets"/> 8 8 <property name="validate_values_expr"></property> 9 9 <property name="label"></property> 10 <property name="label_edit"></property> 11 <property name="is_i18n">False</property> 12 <widget name="ca1" meta_type="Float Widget"> 13 <property name="title">CA 1 Marks</property> 14 <property name="fields"> 15 <element value="ca1"/> 16 </property> 17 <property name="label">CA 1 Marks</property> 18 <property name="label_edit">CA 1 Marks</property> 19 <property name="readonly_layout_modes"/> 20 <property name="hidden_layout_modes"/> 21 <property name="hidden_readonly_layout_modes"/> 22 <property name="is_limited">True</property> 23 <property name="max_value">20.0</property> 24 <property name="decimals_number">1</property> 25 </widget> 26 <widget name="ca2" meta_type="Float Widget"> 27 <property name="title">CA 2 Marks</property> 28 <property name="fields"> 29 <element value="ca2"/> 30 </property> 31 <property name="label">CA 2 Marks</property> 32 <property name="label_edit">CA 2 Marks</property> 33 <property name="readonly_layout_modes"/> 34 <property name="hidden_layout_modes"/> 35 <property name="hidden_readonly_layout_modes"/> 36 <property name="is_limited">True</property> 37 <property name="max_value">20.0</property> 38 <property name="decimals_number">1</property> 39 </widget> 10 40 <widget name="code" meta_type="CertificateCourseId Widget"> 11 41 <property name="title">Course Code</property> … … 53 83 <property name="hidden_readonly_layout_modes"/> 54 84 </widget> 85 <widget name="exam" meta_type="Float Widget"> 86 <property name="title">Exam Marks</property> 87 <property name="fields"> 88 <element value="exam"/> 89 </property> 90 <property name="label">Exam Marks</property> 91 <property name="label_edit">Exam Marks</property> 92 <property name="readonly_layout_modes"/> 93 <property name="hidden_layout_modes"/> 94 <property name="hidden_readonly_layout_modes"/> 95 <property name="is_limited">True</property> 96 <property name="max_value">60.0</property> 97 <property name="decimals_number">1</property> 98 </widget> 55 99 <widget name="passmark" meta_type="Int Widget"> 56 100 <property name="title">Passmark</property> … … 76 120 <property name="label">Score</property> 77 121 <property name="label_edit">Score</property> 78 <property name="readonly_layout_modes"> 79 </property> 122 <property name="readonly_layout_modes"/> 80 123 <property name="hidden_layout_modes"/> 81 124 <property name="hidden_readonly_layout_modes"/> 82 125 </widget> 83 84 <widget name="exam" meta_type="Int Widget">85 <property name="title">Exam Marks</property>86 <property name="fields">87 <element value="exam"/>88 </property>89 <property name="label">Exam Marks</property>90 <property name="label_edit">Exam Marks</property>91 <property name="readonly_layout_modes">92 </property>93 <property name="hidden_layout_modes"/>94 <property name="hidden_readonly_layout_modes"/>95 </widget>96 <widget name="ca1" meta_type="Int Widget">97 <property name="title">CA 1 Marks</property>98 <property name="fields">99 <element value="ca1"/>100 </property>101 <property name="label">CA 1 Marks</property>102 <property name="label_edit">CA 1 Marks</property>103 <property name="readonly_layout_modes">104 </property>105 <property name="hidden_layout_modes"/>106 <property name="hidden_readonly_layout_modes"/>107 </widget>108 <widget name="ca2" meta_type="Int Widget">109 <property name="title">CA 2 Marks</property>110 <property name="fields">111 <element value="ca2"/>112 </property>113 <property name="label">CA 2 Marks</property>114 <property name="label_edit">CA 2 Marks</property>115 <property name="readonly_layout_modes">116 </property>117 <property name="hidden_layout_modes"/>118 <property name="hidden_readonly_layout_modes"/>119 </widget>120 121 126 <widget name="title" meta_type="String Widget"> 122 127 <property name="title">Original Course Title</property> … … 155 160 </object> 156 161 162 -
WAeUP_SRP/trunk/skins/waeup_ois/main_template.pt
r3690 r3707 87 87 <td style="width: 20px;"></td> 88 88 <td style="width: 170px; text-align: center; padding-top: 0.5em;"> 89 <img tal:attributes="src string:${static_base_url}logo_left.jpg" alt="Logo" /> 89 <img tal:attributes="src string:${static_base_url}logo_left.jpg" alt="Logo" 90 height="100" /> 90 91 </td> 91 92 <td padding=0.5em><h1>Olashore International School <br /> Iloko-Ijesa, Nigeria</h1></td> -
WAeUP_SRP/trunk/skins/waeup_ois/student_view.pt
r3700 r3707 23 23 <table> 24 24 <tr> 25 <td width="220px">Registration Number:</td> 26 <td><span tal:content="baseinfo/jamb_reg_no" /></td> 27 </tr> 28 <tr> 29 <td>Matriculation Number:</td> 25 <td>Registration Number:</td> 30 26 <td><span tal:content="baseinfo/matric_no" /></td> 31 27 </tr> -
WAeUP_SRP/trunk/skins/waeup_student/academic_report_slip.pt
r3702 r3707 19 19 <br /> 20 20 <span tal:condition="not:info/data_missing" tal:omit-tag=""> 21 <table class="contentListing" id="folder_content" >21 <table class="contentListing" id="folder_content" width="100%"> 22 22 <span tal:repeat="sem python:(('1','Term One','normal1'),('2','Term Two','normal2'),('3','Term Three','normal3'))"> 23 23 <tr tal:condition="python:info[sem[2]]"> 24 <th align='center'> 25 </th> 26 <th align='center'>ca1 27 </th> 28 <th align='center'>ca2 29 </th> 30 <th align='center'>em 31 </th> 32 <th align='center'>om 33 </th> 24 <th tal:content="python:sem[1]" /> 25 <th align='center'>CA 1 <br />Marks</th> 26 <th align='center'>CA 2 <br />Marks</th> 27 <th align='center'>Exam <br />Marks</th> 28 <th align='center'>Overall <br />Marks</th> 29 <th align='center'>Grade</th> 34 30 <th tal:condition="is_so" align='center'> 35 31 </th> … … 38 34 tal:attributes="class python:test(repeat['row'].even(), 'even ajaxtd', 'odd ajaxtd')"> 39 35 <td tal:content="row/title"></td> 40 <td align="center" width="10%" tal:content="row/code"></td>41 36 <td align="center" tal:content="row/ca1"></td> 42 37 <td align="center" tal:content="row/ca2"></td> 43 38 <td align="center" tal:content="row/exam"></td> 44 39 <td align="center" tal:content="row/score_calc"></td> 40 <td align="center" tal:content="row/grade"></td> 45 41 </tr> 46 42 <tr><td> </td> … … 49 45 </table> 50 46 </span> 51 <table> 52 <tr> 53 <th>ca1/2: 54 </th> <td>CA 1/2 Marks</td> 55 </tr> 56 <tr> 57 <th>em: 58 </th> <td>Exam Marks</td> 59 </tr> 60 <tr> 61 <th>om: 62 </th> <td>Overall Marks</td> 63 </tr> 64 </table> 65 <span tal:condition="is_ca"> <br /><br /> 47 48 <span tal:condition="python:False"> <br /><br /> 66 49 <table width=100%> 67 50 <tr > -
WAeUP_SRP/trunk/skins/waeup_student/academic_report_view.pt
r3703 r3707 1 <metal:body use-macro="here/slip_template/macros/master"> 2 <metal:main fill-slot="main" tal:define="info context/getStudyLevelInfo;" > 3 <span tal:condition="not: info"> 4 <span tal:content="here/illegal_view" /> 5 </span> 6 <span tal:condition="info" tal:omit-tag=""> 7 <span tal:omit-tag="" tal:define="is_so info/is_so; 8 is_ca info/is_ca; 9 show_check_boxes 10 info/show_check_boxes; 11 is_student info/is_student; 12 validated info/validated; "> 13 <h3> <span tal:content="info/session" /> Academic Report (<span tal:content="info/student/course" /> 14 <span tal:content="info/level_str" />) 15 </h3> <br /> 16 <span tal:omit-tag="" tal:content="structure python: info['app_doc'].render(proxy=info['app_doc'], 17 layout_mode='view_info', 18 layout_id='student_application')" /> 19 <br /> 20 <span tal:condition="not:info/data_missing" tal:omit-tag=""> 21 <table class="contentListing" id="folder_content"> 22 <span tal:repeat="sem python:(('1','Term One','normal1'),('2','Term Two','normal2'),('3','Term Three','normal3'))"> 23 <tr tal:condition="python:info[sem[2]]"> 24 <th colspan=2 1 <metal:body use-macro="here/main_template/macros/master"> 2 <metal:main fill-slot="main" 3 tal:define="info context/getStudyLevelInfo; 4 contact_student_form string:contact_student_form; 5 study_level_view string:study_level_view;"> 6 <metal:block define-macro="edit_form"> 7 8 <span tal:condition="not: info"> 9 <span tal:content="here/illegal_view" /> 10 </span> 11 <span tal:condition="info"> 12 <span tal:define= "is_so context/isSectionOfficer; 13 is_ca info/is_ca; 14 show_check_boxes info/show_check_boxes; 15 has_verdict info/has_verdict; 16 submission_allowed info/submission_allowed; 17 rejection_allowed info/rejection_allowed; 18 is_current_level info/is_current_level; 19 is_student info/is_student; 20 with_score not: info/without_score|nothing; 21 with_cascore not: info/without_cascore|nothing; 22 "> 23 24 25 <span tal:condition="python:True"> 26 <div style="text-align: right" 27 tal:condition="python:True"> 28 <a href="" target="slip" tal:attributes="href string:academic_report_slip" 29 onclick="javascript:window.open('','slip','width=600, height=700, directories=no, toolbar=no, location=no, menubar=yes, scrollbars=yes, status=no, resizable=no, dependent=no')"> 30 <img tal:attributes="src string:${here/portal_url}/actionicon_print.png" /> 31 Academic Report Slip 32 </a> 33 </div> 34 </span> 35 36 <a href="" 37 tal:attributes="href string:${here/academicsParent}"> 38 <img tal:attributes="src string:${here/portal_url}/arrow_up.gif"/> 39 Up one level 40 </a> 41 42 <h3> 43 <span tal:condition="python: is_so or is_ca"> 44 <span tal:content="info/student/name" />: 45 </span> 46 <span tal:condition="is_student">My </span> 47 48 Subject Registration Form for <span tal:content="info/level_str" /> 49 </h3> 50 51 <br /> 52 53 <table> 54 <tr> 55 <th valign='top'>Pastoral Reports:</th> 56 <td> 57 <span tal:repeat="item python:info['items']"> 58 <a href="view" 59 tal:attributes="href item/id" 60 tal:content="item/title"/><br /> 61 </span> 62 </td> 63 </tr> 64 <tr> 65 <th>Session:</th> 66 <td><span tal:content="info/session" /></td> 67 </tr> 68 <tr tal:condition="has_verdict"> 69 <th>Verdict:</th> 70 <td><span tal:content="info/verdict" /></td> 71 </tr> 72 </table> 73 74 75 <form action="." method="post" class="group" onsubmit="return submit_once()"> 76 77 <div class="" tal:condition="python: info['data_missing'] and not info['spillover']"> 78 <font color="red">Your faculty has not yet provided the list of subjects for your certificate. Please contact your faculty!</font> 79 <br /><br /> 80 </div> 81 82 <span tal:condition="not:info/data_missing" tal:omit-tag=""> 83 84 <table class="contentListing" id="folder_content" width="100%"> 85 86 <span tal:repeat="sem python:(('1','Term One','normal1'),('2','Term Two','normal2'),('3','Term Three','normal3'))"> 87 88 <tr tal:condition="python:info[sem[2]]"> 89 <th tal:attributes="colspan python: test(show_check_boxes,'2','1')" 25 90 tal:content="python:sem[1]" /> 26 <th align='center'>ca1 27 </th> 28 <th align='center'>ca2 29 </th> 30 <th align='center'>em 31 </th> 32 <th align='center'>om 33 </th> 34 <th tal:condition="is_so" align='center'> 35 </th> 36 </tr> 37 <tr tal:repeat="row python:info[sem[2]]" 38 tal:attributes="class python:test(repeat['row'].even(), 'even ajaxtd', 'odd ajaxtd')"> 39 <td tal:content="row/title"></td> 40 <td align="center" width="10%" tal:content="row/code"></td> 41 <td align="center" tal:content="row/ca1"></td> 42 <td align="center" tal:content="row/ca2"></td> 43 <td align="center" tal:content="row/exam"></td> 44 <td align="center" tal:content="row/score_calc"></td> 45 </tr> 46 <tr><td> </td> 47 </tr> 48 </span> 49 </table> 50 </span> 51 <table> 52 <tr> 53 <th>ca1/2: 54 </th> <td>CA 1/2 Marks</td> 55 </tr> 56 <tr> 57 <th>em: 58 </th> <td>Exam Marks</td> 59 </tr> 60 <tr> 61 <th>om: 62 </th> <td>Overall Marks</td> 63 </tr> 64 </table> 65 <span tal:condition="is_ca"> <br /><br /> 66 <table width=100%> 67 <tr > 68 <td width=50%>Date:</td><td>Date:</td> 69 </tr> 70 </table> <br /><br /><br /><br /> 71 <table width=100%> 72 <tr > 73 <td width=50% style="border-top-style:solid; border-top-width:1px; border-top-color:black"> Student</td> 74 <td width=50% style="border-top-style:solid; border-top-width:1px; border-top-color:black">Course Adviser</td> 75 </tr> 76 </table> 77 </span> 78 </span> 79 </span> 80 </metal:main> 91 <th align='center'>CA 1 <br />Marks</th> 92 <th align='center'>CA 2 <br />Marks</th> 93 <th align='center'>Exam <br />Marks</th> 94 <th align='center'>Overall <br />Marks</th> 95 <th align='center'>Grade</th> 96 <th tal:condition="submission_allowed" align='center'></th> 97 <th tal:condition="is_so" align='center'></th> 98 99 </tr> 100 <tr tal:repeat="row python:info[sem[2]]" 101 tal:attributes="class python:test(repeat['row'].even(), 'even ajaxtd', 'odd ajaxtd')"> 102 <td align="left" valign="middle" style="width: 5%;" 103 tal:condition="show_check_boxes"> 104 <input type="checkbox" name="ids:list" value="" id="" class="noborder" 105 tal:define="id row/id" 106 tal:attributes="value id; 107 id python:'cb_' + id; 108 checked python:id in info['choosen_ids'];" 109 /> 110 </td> 111 <td tal:content="row/title"></td> 112 <td align="center" tal:content="row/ca1"></td> 113 <td align="center" tal:content="row/ca2"></td> 114 <td align="center" tal:content="row/exam"></td> 115 <td align="center" tal:content="row/score_calc"></td> 116 <td align="center" tal:content="row/grade"></td> 117 118 <td tal:condition="python:submission_allowed and is_student" align="center"> 119 <a href="edit" tal:attributes="href string:course_edit/${row/code}" 120 target="edit_course_result" 121 onclick="javascript:window.open('','edit_course_result','width=600, height=350, directories=no, toolbar=no, location=no, menubar=no, scrollbars=yes, status=no, resizable=no, dependent=no')"> 122 [edit] 123 </a> 124 </td> 125 <td tal:condition="is_so" align="center"> 126 <a href="edit" tal:attributes="href string:lecturer_course_edit/${row/code}" 127 target="edit_course_result" 128 onclick="javascript:window.open('','edit_course_result','width=600, height=500, directories=no, toolbar=no, location=no, menubar=no, scrollbars=yes, status=no, resizable=no, dependent=no')"> 129 [edit] 130 </a> 131 </td> 132 </tr> 133 <tr><td> </td></tr> 134 </span> 135 136 </table> 137 </span> 138 139 140 141 <br /> 142 143 <table tal:condition="python: is_student and show_check_boxes" width="100%" cellspacing="0" cellpadding="2" 144 class="folderButtons"> 145 <tr> 146 <td align="left" valign="top" rowspan="3"></td> 147 <td align="left" valign="top"> 148 <input type="submit" name="delete_course_result:method" value="Delete selected" 149 class="destructive" i18n:attributes="value" 150 tal:attributes="onclick python:'return window.confirm(\'%s\')' % 151 ('Do you really want to delete selected subjects?', )" 152 /> 153 <input tal:condition="python: 1" type="submit" name="refresh_level:method" 154 class="context" value="Update" 155 /> 156 157 158 <br /><br /> 159 <input tal:condition="not: info/credits_exceeded" 160 type="submit" name="register_courses:method" 161 class="context" value="Submit to Academic Tutor" 162 tal:attributes="onclick python:'return window.confirm(\'%s\')' % 163 ('Do you really want to submit the list? You will not be able to edit your data after submission.', )" /> 164 <span tal:condition="info/credits_exceeded"> 165 <font color="red"> <strong>Your total credits exceed <span tal:replace="info/max_credits" />!</strong></font> 166 </span> 167 168 <input type="hidden" name="action_after_validate" type="text" id="action_after_validate" 169 tal:attributes="value study_level_view"/> 170 171 <br /><br /> 172 173 <span tal:condition="python: 1"> 174 <strong>Note:</strong> 'Update' checks for all subjects in your certificate and will add them to your subject list irrespective of 175 prior deletion, i.e. already deleted subjectss will show up again. 176 Please use this function only if you are sure that your faculty has added subjects which are not yet on your subject list. 177 </span> 178 <span tal:condition="python: 0"> 179 <strong>Note:</strong> The 'Update' function has been temporarily disabled. 180 </span> 181 182 </td> 183 </tr> 184 </table> 185 <table tal:condition="python: is_so and show_check_boxes" width="100%" cellspacing="0" cellpadding="2" 186 class="folderButtons"> 187 <tr> 188 <td align="left" valign="top" rowspan="3"></td> 189 <td align="left" valign="top"> 190 <input type="button" value="Select all" class="context" 191 onclick="someJavaScriptFunctionThatWillBeReplaced" 192 i18n:attributes="value" 193 tal:attributes="onclick python:'toggleSelect(this, \'%s\', \'%s\')' 194 % (cpsmcat('button_select_all'), cpsmcat('button_deselect_all'))" 195 /> 196 <input type="submit" name="delete_course_result:method" value="Delete selected" 197 class="destructive" i18n:attributes="value" 198 tal:attributes="onclick python:'return window.confirm(\'%s\')' % 199 ('Do you really want to delete the subjects selected?', )" 200 /> 201 <input 202 type="submit" name="refresh_level:method" 203 class="context" value="Update" 204 /> 205 <input tal:condition="submission_allowed" type="submit" name="register_courses:method" 206 class="context" value="Submit" /> 207 <input tal:condition="info/validation_allowed" type="submit" name="validate_courses:method" 208 class="context" value="Validate" /> 209 <input tal:condition="info/rejection_allowed" type="submit" name="reject_courses:method" 210 class="context" value="Reject" /> 211 212 <input type="hidden" name="action_after_validate" type="text" id="action_after_validate" 213 tal:attributes="value study_level_view"/> 214 <input type="hidden" name="action_after_reject" type="text" id="action_after_reject" 215 tal:attributes="value contact_student_form"/> 216 217 </td> 218 </tr> 219 </table> 220 <table tal:condition="python:is_ca and is_current_level and not has_verdict" width="100%" cellspacing="0" cellpadding="2" 221 class="folderButtons"> 222 <tr> 223 <td align="left" valign="top" rowspan="3"></td> 224 <td align="left" valign="top"> 225 <input tal:condition="show_check_boxes" 226 type="button" value="Select all" class="context" 227 onclick="someJavaScriptFunctionThatWillBeReplaced" 228 i18n:attributes="value" 229 tal:attributes="onclick python:'toggleSelect(this, \'%s\', \'%s\')' 230 % (cpsmcat('button_select_all'), cpsmcat('button_deselect_all'))" 231 /> 232 <input tal:condition="show_check_boxes" 233 type="submit" name="delete_course_result:method" value="Delete selected" 234 class="destructive" i18n:attributes="value" 235 tal:attributes="onclick python:'return window.confirm(\'%s\')' % 236 ('Do you really want to delete the subjects selected?', )" 237 /> 238 <input tal:condition="show_check_boxes" 239 type="submit" name="refresh_level:method" 240 class="context" value="Update" 241 /> 242 <input tal:condition="submission_allowed" type="submit" name="register_courses:method" 243 class="context" value="Submit" /> 244 <input tal:condition="info/validation_allowed" type="submit" name="validate_courses:method" 245 class="context" value="Validate" /> 246 <input tal:condition="info/rejection_allowed" type="submit" name="reject_courses:method" 247 class="context" value="Reject" /> 248 249 <input type="hidden" name="action_after_validate" type="text" id="action_after_validate" 250 tal:attributes="value study_level_view"/> 251 <input type="hidden" name="action_after_reject" type="text" id="action_after_reject" 252 tal:attributes="value contact_student_form"/> 253 254 255 </td> 256 </tr> 257 </table> 258 259 </form> 260 <br /> 261 <form action="add_course_result" method="post" class="group" onsubmit="return submit_once()" 262 tal:condition="show_check_boxes"> 263 <table> 264 <tr> 265 <th>Subject Id</th> 266 <td><input type="text" name="course_id" 267 tal:attributes="value request/course_id|nothing"/></td> 268 <td colspan="2"> 269 <input type="submit" name="add" 270 class="context" value="Add Subject" 271 /> 272 <input type="hidden" name="action_after_validate" type="text" id="action_after_validate" 273 tal:attributes="value study_level_view"/> 274 </td> 275 </table> 276 </form> 277 </span> 278 </span> 279 </metal:block> 280 </metal:main> 281 81 282 </metal:body> 283 -
WAeUP_SRP/trunk/skins/waeup_student/getGradesFromScore.py
r2756 r3707 5 5 ##bind script=script 6 6 ##bind subpath=traverse_subpath 7 ##parameters=score=None 7 ##parameters=score=None,level_id=None 8 8 ##title= 9 9 ## 10 10 # $Id$ 11 11 12 if score is None: 13 return None,None 14 score = int(score) 15 if score >= 70: 16 return ('A',5) 17 if score >= 60: 18 return ('B',4) 19 if score >= 50: 20 return ('C',3) 21 if score >= 45: 22 return ('D',2) 23 if score >= 40: 24 return ('E',1) 25 return ('F',0) 12 if level_id: 13 if level_id in ('100', '200', '300'): 14 if score >= 80: 15 return ('A') 16 if score >= 60: 17 return ('C') 18 if score >= 55: 19 return ('P') 20 if score >= 0: 21 return ('F') 22 elif level_id in ('400', '500', '600'): 23 if score >= 80: 24 return ('A1') 25 if score >= 75: 26 return ('B2') 27 if score >= 70: 28 return ('B3') 29 if score >= 65: 30 return ('C4') 31 if score >= 60: 32 return ('C5') 33 if score >= 55: 34 return ('C6') 35 if score >= 0: 36 return ('F9') 37 else: 38 return('X') 39 else: 40 if score is None: 41 return None,None 42 score = int(score) 43 if score >= 70: 44 return ('A',5) 45 if score >= 60: 46 return ('B',4) 47 if score >= 50: 48 return ('C',3) 49 if score >= 45: 50 return ('D',2) 51 if score >= 40: 52 return ('E',1) 53 return ('F',0) -
WAeUP_SRP/trunk/skins/waeup_student/lecturer_course_edit.py
r3617 r3707 50 50 course = course_results[0] 51 51 for field in context.course_results.schema(): 52 object[field] = getattr(course,field) 52 object[field] = getattr(course,field,None) 53 if repr(object[field]) == 'Missing.Value': 54 object[field] = None 55 #set_trace() 53 56 lt = context.portal_layouts 54 57 res,psm, ds = lt.renderLayout(schema_id = 'student_course_result', … … 77 80 psm = 'psm_content_changed' 78 81 break 79 80 82 return context.lecturer_course_edit_form(rendered = res, 81 83 psm = psm, -
WAeUP_SRP/trunk/skins/waeup_student/pastoral_report_slip.pt
r3702 r3707 18 18 tal:content="structure python: info['doc'].render(layout_mode='view')" /> 19 19 </span> 20 <span tal:condition="python:True"> <br /><br /> 21 <table width=100%> 22 <tr > 23 <td width=50%>Date:</td><td></td> 24 </tr> 25 </table> <br /><br /><br /><br /> 26 <table width=100%> 27 <tr > 28 <td width=50% style="border-top-style:solid; border-top-width:1px; border-top-color:black">Name of House Staff</td> 29 <td width=50% style="border-top-style:solid; border-top-width:1px; border-top-color:black">Signature</td> 30 </tr> 31 </table> 32 </span> 20 33 </metal:main> 21 34 </metal:body>
Note: See TracChangeset for help on using the changeset viewer.