Ignore:
Timestamp:
22 Jun 2011, 09:47:22 (13 years ago)
Author:
Henrik Bettermann
Message:

Implement search page for access codes (work in progress).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.sirp/trunk/src/waeup/sirp/accesscodes/browser_templates/searchpage.pt

    r5918 r6450  
    11<form method="POST">
     2
     3<br />
     4
    25  <input type="submit" name="search" value="Search" />
    3   for scratch cards
     6  for access codes
    47
    58  <select name="searchtype">
    6     <option value="stud_id">
    7       used by student with ID
    8     </option>
    9     <option value="pin">with PIN</option>
    10     <option value="serial">with serial</option>
    11   </select>:
     9    <option value="code">with PIN</option>
     10    <option value="batch_serial">with serial</option>
     11    <option value="history">with message term</option>
     12  </select>
    1213
    1314  <input type="text" name="searchterm" />
    14   <br /><br />
    15   <b>complete numbers only</b>
    16   (Student ID means registration number for APP SCs)
    17   <br />
    1815
    1916  <p>&nbsp;</p>
    20   <div tal:condition="view/searchresults">
     17  <div tal:condition="view/hitlist">
    2118    <h3>Search Results</h3>
    22     <table>
     19    <input type="hidden" name="old_searchterm"
     20         tal:attributes="value view/searchterm" />
     21    <input type="hidden" name="old_searchtype"
     22         tal:attributes="value view/searchtype" />
     23    <table class = "zebra">
    2324      <thead>
    24         <tr>
    25           <th>&nbsp;</th>
    26           <th>Serial</th><th>AC</th><th>Status</th>
    27         </tr>
     25        <tr>
     26          <th>&nbsp;</th>
     27          <th>Serial</th><th>AC</th><th>Status</th><th>History</th>
     28        </tr>
    2829      </thead>
    2930      <tbody>
    30         <tr tal:repeat="item view/searchresults"
    31             tal:attributes="class python: repeat['item'].odd() and 'even' or 'odd'">
    32           <td><input type="checkbox" name="entries"
    33                      tal:attributes="value item/code" /></td>
    34           <td tal:content="item/serial">1</td>
    35           <td tal:content="item/code">APP-1-1234567890</td>
    36           <td tal:content="item/status">unused</td>
    37         </tr>
     31        <tr tal:repeat="item view/hitlist">
     32          <td><input type="checkbox" name="entries"
     33                     tal:attributes="value item/code" /></td>
     34          <td tal:content="item/batch_serial">1</td>
     35          <td tal:content="item/code">APP-1-1234567890</td>
     36          <td tal:content="item/status">unused</td>
     37          <td tal:content="structure item/history">history</td>
     38        </tr>
    3839      </tbody>
    3940    </table>
Note: See TracChangeset for help on using the changeset viewer.