Changeset 6110


Ignore:
Timestamp:
16 May 2011, 08:22:14 (13 years ago)
Author:
Henrik Bettermann
Message:

Add attribute 'ac_prefix' to ApplicantsContainer? to preselect ac batches. Use this ac_prefix in loginapplicant.pt.

Location:
main/waeup.sirp/trunk/src/waeup/sirp/applicants
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.sirp/trunk/src/waeup/sirp/applicants/authentication.py

    r6043 r6110  
    137137
    138138    loginpagename = 'login'
    139     accesscode_prefix_field = 'form.prefix'
     139    accesscode_prefix_field = 'form.ac_prefix'
    140140    accesscode_series_field = 'form.ac_series'
    141141    accesscode_number_field = 'form.ac_number'
  • main/waeup.sirp/trunk/src/waeup/sirp/applicants/browser.py

    r6108 r6110  
    148148    def update(self):
    149149        datepicker.need() # Enable jQuery datepicker in date fields.
    150         from waeup.sirp.browser.resources import jqueryui
    151         jqueryui.need()
     150        #from waeup.sirp.browser.resources import jqueryui
     151        #jqueryui.need()
    152152        return super(ApplicantsContainerAddFormPage, self).update()
    153153
     
    285285    grok.require('zope.Public')
    286286
    287     title = u'Login'
     287    @property
     288    def title(self):
     289        return u"Applicant Login: %s" % self.context.title
    288290
    289291    @property
    290292    def label(self):
    291         return self.title
    292 
    293     pnav = 3
    294     prefix = u'APP'
     293        return u'Login for applicants only'
     294
     295    pnav = 3
     296   
     297    @property
     298    def ac_prefix(self):
     299        return self.context.ac_prefix
    295300
    296301    def update(self, SUBMIT=None):
  • main/waeup.sirp/trunk/src/waeup/sirp/applicants/browser_templates/applicantscontainermanagepage.pt

    r6107 r6110  
    7272        <thead>
    7373          <tr>
    74             <th>ID</th><th>status</th>
     74            <th>&nbsp;</th><th>ID</th><th>status</th>
    7575          </tr>
    7676        </thead>
     
    8080              <input type="checkbox"
    8181                         name="val_id"
    82                          tal:attributes="value appl/_name_" />
     82                         tal:attributes="value appl/__name__" />
    8383            </td>
    8484            <td>
  • main/waeup.sirp/trunk/src/waeup/sirp/applicants/browser_templates/loginapplicant.pt

    r5887 r6110  
    1 <h3>
    2   Applicant login
    3   <span tal:on-error="nothing">
    4     (<span tal:replace="view/getCurrentSession">2010/2011</span>)
    5   </span>
    6 </h3>
    7 <div>
    8   This Login is for applicants only!
    9 </div>
     1<h2 i18n:translate=""
     2    tal:condition="view/label"
     3    tal:content="view/label">Label</h2>
     4
     5
    106<form method="POST">
     7  <input type="hidden" name="form.ac_prefix"
     8         value="" tal:attributes="value view/ac_prefix" />
    119  <table>
    1210    <tbody>
    1311      <tr>
    14         <input type="hidden" name="form.prefix" value="APP" />
    15         <td><label for="form.ac_series">Access Code</label></td>
    16         <td>
    17           APP-<input name="form.ac_series" type="text" size="3" maxlength="3"
    18                       value="" tal:attributes="value view/ac_series"
    19           />-<input name="form.ac_number" type="text" size="10" maxlength="10"
    20                     value="" tal:attributes="value view/ac_number" />
    21         </td>
     12        <td><label for="form.ac_series">Access Code:</label></td>
     13        <td>
     14          <span tal:replace="view/ac_prefix">PIN Prefix</span>
     15         -<input name="form.ac_series" type="text" size="3" maxlength="3"
     16                  value="" tal:attributes="value view/ac_series"/>
     17         -<input name="form.ac_number" type="text" size="10" maxlength="10"
     18                value="" tal:attributes="value view/ac_number" />
     19        </td>
    2220      </tr>
    2321      <tr>
     
    3129
    3230<div>
    33   Instructions:
     31  <h3>Instructions:</h3>
    3432  <ul class="list">
    3533    <li>
     
    4644      Press the 'Final Submit' button.
    4745    </li>
     46    <li>
     47      After submission you won't be able to edit the data
     48      but you can access and print this form again.
     49    </li>
    4850  </ul>
    4951</div>
  • main/waeup.sirp/trunk/src/waeup/sirp/applicants/interfaces.py

    r6109 r6110  
    195195        readonly = True,
    196196        )
     197       
     198    ac_prefix = schema.Choice(
     199        title = u'Access code prefix',
     200        required = True,
     201        default = None,
     202        values = ['APP','CEST','PUME','PUDE'],
     203        )
    197204
    198205    description = schema.Text(
Note: See TracChangeset for help on using the changeset viewer.