Changeset 2328 for WAeUP_SRP/base


Ignore:
Timestamp:
8 Oct 2007, 15:12:24 (17 years ago)
Author:
Henrik Bettermann
Message:

improve application forms

Location:
WAeUP_SRP/base/skins
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • WAeUP_SRP/base/skins/waeup_layout/layout_apply_admission_create.pt

    r2310 r2328  
    2222                           err python:ds.getError(wid);
    2323                           err_mapping python:ds.getErrorMapping(wid);
    24                            is_required widget/is_required|nothing;
    25                            tooltip_id python:wid + '_help';
    2624                           widget_css_class cell/widget_css_class|nothing;
    2725                           css_class python:test(err, 'row error','row')">
  • WAeUP_SRP/base/skins/waeup_student/apply_admission.py

    r2324 r2328  
    4848if manage:
    4949    validate = False
    50 #layout = "application_pume"
    51 #screening_type = ""
    5250without_reg_no = False
    5351
    54 # if traverse_subpath and traverse_subpath[0] == "prence":
    55 #     layout = "application_prence"
    56 #     screening_type = "prence"
    57 #     without_reg_no = True
    58 # elif traverse_subpath and traverse_subpath[0] == "pume":
    59 #     layout = "application_pume"
    60 #     screening_type = "pume"
    61 # elif traverse_subpath and traverse_subpath[0] == "pce":
    62 #     layout = "application_pce"
    63 #     screening_type = "pce"
    64 # elif traverse_subpath and traverse_subpath[0] == "pde":
    65 #     layout = "application_pde"
    66 #     screening_type = "pde"
    67 # elif traverse_subpath and traverse_subpath[0] == "cest":
    68 #     layout = "application_cest"
    69 #     screening_type = "cest"
    70 # else:
    71 #     return request.RESPONSE.redirect("%s/srp_anonymous_view" % context.portal_url())
    72 screening_types = ('prence','pume','pce','pde','cest')
    73 headings = {}
    74 headings['pume'] = 'Apply for Post UME Screening Test (2007/2008)! '
    75 headings['pde'] = 'Apply for Post DE Screening Test(2007/2008)! '
    76 headings['prence'] = 'Apply for Pre-NCE Programme (2007/2008)! '
    77 headings['pce'] = 'Apply for PCE Screening (2007/2008)! '
    78 headings['cest'] = 'Apply for Common Entrance Screening Test (2007/2008)! '
    79 info = {}
    80 if traverse_subpath and traverse_subpath[0] in screening_types:
    81     screening_type = info['screening_type'] = traverse_subpath[0]
    82     info['heading'] = headings[screening_type]
    83     layout = "application_%s" % screening_type
    84     without_reg_no = screening_type in ('prence',)
    85 
    86 else:
    87     return request.RESPONSE.redirect("%s/srp_anonymous_view" % context.portal_url())
     52
    8853lt = context.portal_layouts
    8954
     
    11681            #logger.info('%s/%s entered wrong pin %s' % (member,reg_no,pin))
    11782            #return request.RESPONSE.redirect("%s/srp_anonymous_view" % context.portal_url())
     83
     84
     85screening_types = ('prence','pume','pce','pde','cest')
     86headings = {}
     87headings['pume'] = 'Apply for Post UME Screening Test (2007/2008)! '
     88headings['pde'] = 'Apply for Post DE Screening Test(2007/2008)! '
     89headings['prence'] = 'Apply for Pre-NCE Programme (2007/2008)! '
     90headings['pce'] = 'Apply for PCE Screening (2007/2008)! '
     91headings['cest'] = 'Apply for Common Entrance Screening Test (2007/2008)! '
     92headings_slip = {}
     93headings_slip['pume'] = 'Post UME Screening (2007/2008) Aknowledgement Slip!'
     94headings_slip['pde'] = 'Post DE Screening (2007/2008) Aknowledgement Slip'
     95headings_slip['prence'] = 'Pre-NCE Application (2007/2008) Aknowledgement Slip'
     96headings_slip['pce'] = 'PCE Screening (2007/2008) Aknowledgement Slip'
     97headings_slip['cest'] = 'Common Entrance Screening (2007/2008) Aknowledgement Slip'
     98info = {}
     99if traverse_subpath and traverse_subpath[0] in screening_types:
     100    screening_type = info['screening_type'] = traverse_subpath[0]
     101    info['heading'] = headings[screening_type]
     102    info['heading_slip'] = headings_slip[screening_type]
     103    layout = "application_%s" % screening_type
     104    without_reg_no = screening_type in ('prence',)
     105elif manage:
     106    if object['screening_type']:
     107        st = object['screening_type']
     108    else:
     109        st = 'pume'
     110    screening_type = info['screening_type'] = st
     111    info['heading'] = headings[screening_type]
     112    info['heading_slip'] = headings_slip[screening_type]
     113    layout = "application_%s" % screening_type
     114    without_reg_no = screening_type in ('prence',) 
     115else:
     116    return request.RESPONSE.redirect("%s/srp_anonymous_view" % context.portal_url())
     117
    118118
    119119if slip:
     
    160160        data[field] = dm.get(field)
    161161data['reg_no'] = reg_no
    162 data['screening_type'] = screening_type
     162
    163163if apply_admission:
    164164    if submitted:
  • WAeUP_SRP/base/skins/waeup_student/apply_admission_slip.pt

    r2310 r2328  
    55           mode options/mode;
    66           name python:ds['lastname'];
     7           info options/info;
    78           "
    89           >
     
    1011    <metal:block use-macro="here/slip_template/macros/master">
    1112      <metal:block fill-slot="main">
    12         <h3>Post UME Screening (2007/2008) Aknowledgement Slip</h3>
     13        <h3 tal:content="info/heading_slip" />
    1314        <br />
    1415        <div tal:replace="structure rendered_main" />
    1516       
    1617        The applicant has confirmed that the picture shown on this slip is a true picture of him/her.
    17         <br/><br/>
    18         Please check for your screening venue at any of the UNIBEN entry gates or
    19         at the Sports Complex and come to the screening venue with a copy of this slip. 
     18
    2019      </metal:block>
    2120    </metal:block>
  • WAeUP_SRP/base/skins/waeup_utilities/deleteResultByKey.py

    r2097 r2328  
    2525students = context.portal_url.getPortalObject().campus.students
    2626if str(member) not in ('admin','joachim','med','despej') or key is None:
    27     return
     27    return 'You are not allowed to execute this command!'
    2828
    2929output = []
Note: See TracChangeset for help on using the changeset viewer.