Changeset 6858 for WAeUP_SRP/trunk/skins


Ignore:
Timestamp:
4 Oct 2011, 06:05:39 (13 years ago)
Author:
Henrik Bettermann
Message:

Implement 100L carryover courses registration in current_level 100. The level id is 501. The course result records are not beeing marked as carryovers because students can add courses which are not marked as such.

Location:
WAeUP_SRP/trunk/skins
Files:
1 added
6 edited

Legend:

Unmodified
Added
Removed
  • WAeUP_SRP/trunk/skins/waeup_futminna/getStudentLevelsVoc.py

    r6855 r6858  
    3636else:
    3737    raise KeyError
     38
     39# FUTMinna only
     40if ikey == 501:
     41    return "100 Level Carryover Courses"
     42
    3843level_nr,repeat = divmod(ikey, 100)
    3944l = []
  • WAeUP_SRP/trunk/skins/waeup_futminna/getStudyCourseInfo.py

    r6857 r6858  
    9494               (student_record.entry_mode.startswith('pd') and current_level == '500'))  #fceokene only
    9595
     96info['may_register_501'] = (current_level == '500') and '501' not in levels
     97
    9698missing_data = has_paid and\
    9799               current_level not in levels and\
  • WAeUP_SRP/trunk/skins/waeup_futminna/getStudyLevelInfo.py

    r6855 r6858  
    4747info['has_verdict'] = has_verdict = level_doc.verdict
    4848
    49 info['submission_allowed']= school_fee_paid and is_current_level and not has_verdict
    50 info['validation_allowed']= review_state == 'courses_registered' and is_current_level
    51 info['rejection_allowed']= review_state in ('courses_registered', 'courses_validated','returning',) and is_current_level
     49info['submission_allowed']= school_fee_paid and is_current_level and not has_verdict and level_id != '501'
     50info['validation_allowed']= review_state == 'courses_registered' and is_current_level and level_id != '501'
     51info['rejection_allowed']= review_state in ('courses_registered', 'courses_validated','returning',) and\
     52                                             is_current_level and level_id != '501'
    5253info['validated'] = level_doc.validated_by and not (is_current_level and review_state in ('courses_registered',))
    5354info['show_check_boxes'] =  (is_ca and school_fee_paid and is_current_level and not has_verdict) or\
    5455                            (info['is_student'] and school_fee_paid and is_current_level and not has_verdict) or\
     56                            level_id == '501' or\
    5557                            (is_so) # and is_current_level and not has_verdict)
    5658
     
    6062
    6163info['choosen_ids'] = request.get('ids',[])
    62 
    63 #info['status_info'] = ""
    64 #if is_student:
    65 #    if review_state == 'courses_registered':
    66 #        info['status_info'] = "Request for course validation pending"
    67 #    elif review_state == 'courses_validated':
    68 #        info['status_info'] = "Courses validated"
    69 #elif is_ca:
    70 #    if review_state == 'courses_registered':
    71 #        info['status_info'] = "Please validate these courses"
    72 #    elif review_state == 'courses_validated':
    73 #        info['status_info'] = "Courses validated"
    7464
    7565cert_id = student.course
     
    9686            row['score'] = 0
    9787info['without_cascore'] = True
    98 #end customization
    9988
    10089info['max_credits'] = max_credits
    10190info['credits_exceeded'] = total_credits > max_credits
    10291current_session = student.session
     92info['show_submit'] = not info['credits_exceeded'] and level_id != '501'
     93info['show_update'] = level_id != '501'
     94#end customization
    10395
    10496info['gpa'] = gpa
  • WAeUP_SRP/trunk/skins/waeup_futminna/study_course_view.pt

    r6856 r6858  
    133133      </table>
    134134    </form> 
     135
     136    <form action="" method="post" class="group" onsubmit="return submit_once()"
     137          tal:attributes="action string:${context/absolute_url}/create_level_501"
     138          tal:define="rows python: info['items'];"
     139          tal:condition="info/may_register_501"
     140          >
     141      <table width="100%" cellspacing="0" cellpadding="2"
     142             summary="contents of the folder"
     143             class="folderButtons">
     144        <tr>
     145          <td align="left" valign="top" rowspan="3"></td>
     146          <td align="left" valign="top">
     147            <input type="submit" name="create_level"
     148                     class="destructive"
     149                     tal:attributes="value string: Register 100L Carryover Courses"
     150                     />
     151          </td>
     152        </tr>
     153      </table>
     154    </form>
    135155   
    136156    <div tal:condition="info/missing_data">
  • WAeUP_SRP/trunk/skins/waeup_futminna/study_level_view.pt

    r6855 r6858  
    1313    is_ca info/is_ca;
    1414    show_check_boxes info/show_check_boxes;
     15    show_update info/show_update;
    1516    has_verdict info/has_verdict;
    1617    submission_allowed info/submission_allowed;
     
    209210                     ('Do you really want to delete selected courses?', )"
    210211                     />
    211               <input tal:condition="python: 1" type="submit" name="refresh_level:method"
     212              <input tal:condition="show_update" type="submit" name="refresh_level:method"
    212213                     class="context" value="Update"
    213214                     />
     
    215216                     
    216217              <br /><br />
    217               <input tal:condition="not: info/credits_exceeded"
     218              <input tal:condition="info/show_submit"
    218219                     type="submit" name="register_courses:method"
    219220                     class="context" value="Submit to Course Adviser"
     
    229230              <br /><br />
    230231             
    231               <span tal:condition="python: 1">
     232              <span tal:condition="show_update">
    232233              <strong>Note:</strong> 'Update' checks for all courses in your certificate and will add them to your course list irrespective of
    233234              prior deletion, i.e. already deleted courses will show up again.
     
    257258                     ('Do you really want to delete the courses selected?', )"
    258259                     />
    259               <input
     260              <input tal:condition="show_update"
    260261                     type="submit" name="refresh_level:method"
    261262                     class="context" value="Update"
     
    294295                     ('Do you really want to delete the courses selected?', )"
    295296                     />
    296               <input tal:condition="show_check_boxes"
     297              <input tal:condition="show_update"
    297298                     type="submit" name="refresh_level:method"
    298299                     class="context" value="Update"
  • WAeUP_SRP/trunk/skins/waeup_student/register_courses.py

    r5457 r6858  
    3333student = getattr(students_folder,student_id)
    3434
     35# FUTMinna only
     36if context.getId() == '501':
     37    return 'Forbidden'
     38
    3539info = context.getStudyLevelInfo()
    3640if info['credits_exceeded']:
Note: See TracChangeset for help on using the changeset viewer.