source: WAeUP_SRP/branches/uli/skins/waeup_student/study_course_view.pt @ 9819

Last change on this file since 9819 was 1655, checked in by uli, 18 years ago

Added submit_once(). Untested.

  • Property svn:keywords set to Id
File size: 5.2 KB
Line 
1<metal:html>
2  <metal:body use-macro="here/waeup_content_master/macros/master">
3    <metal:block fill-slot="header" 
4                 tal:define="global info context/getStudyCourseInfo;
5                 global create_level info/create_level|nothing;
6                 global is_so info/is_so;
7                 "
8                 >
9      <a href=""
10         tal:attributes="href string:${here/academicsParent}">
11        <img tal:attributes="src string:${here/portal_url}/arrow_up.gif"/>
12        Up one level
13      </a>
14      <h3>
15         <span tal:condition="python:is_so and info">
16           <span tal:content="info/student/name" />:
17         </span>
18        <span tal:content="here/title_or_id" />
19      </h3>
20      <br />
21    </metal:block>
22    <metal:main fill-slot="main">
23      <table tal:define="sc python: info['course_doc']">
24        <tr>
25          <td width="220px">Certificate Code:</td>
26          <td><span tal:content="info/doc/study_course" /></td>
27        </tr>
28        <tr>
29          <td width="220px">Current Study Level:</td>
30          <td><span tal:content="python:context.portal_vocabularies.courselevel.get(info['doc'].current_level)" /></td>
31        </tr>
32        <tr>
33          <td width="220px">Current Verdict:</td>
34          <td><span tal:content="info/verdict" /></td>
35        </tr>
36        <tr>
37          <td width="220px">Certificate:</td>
38          <td><span tal:content="sc/title" /></td>
39        </tr>
40        <tr>
41          <td>Certificate Id:</td>
42          <td tal:content="sc/study_course" />
43        </tr>
44          <span tal:define="f_id sc/faculty;
45          d_id sc/department;
46          f_title context/academics/?f_id/Title|string:Faculty not yet in Prospectus;
47          d_title context/academics/?f_id/?d_id/Title|string:Department not yet in Prospectus"
48          >
49            <tr>
50              <td>Faculty:</td>
51              <td tal:content="f_title" />
52            </tr>
53            <tr>
54              <td>Department:</td>
55              <td><span tal:content="d_title" /></td>
56            </tr>
57          </span>
58        </table>       
59     
60      <form action="" method="post" class="group" onsubmit="return submit_once()"
61            tal:attributes="action info/action"
62            tal:define="rows python: info['items'];"
63            >
64        <table tal:condition="python: 1" class="contentListing" width="100%" summary="content layout" id="folder_content">     
65          <tr tal:repeat="row rows"
66            tal:attributes="class python:test(repeat['row'].even(), 'even ajaxtd', 'odd ajaxtd')">
67            <td align="left" valign="middle" style="width: 5px;"
68                tal:condition="python:is_so">
69              <input type="checkbox" name="ids:list" value="" id="" class="noborder"
70                     tal:condition="is_so"
71                     tal:define="id row/id"
72                     tal:attributes="value id;
73                     id python:'cb_' + id;
74                     checked python:id in info['choosen_ids'];"
75                     />
76            </td>
77            <td><a href="view"
78                   tal:attributes="href string:${row/url}">
79              <strong tal:content="row/title" /></a>
80            </td>
81          </tr>
82        </table>
83        <table width="100%" cellspacing="0" cellpadding="2"
84               summary="contents of the folder"
85               class="folderButtons">
86          <tr tal:condition="python: is_so and info['items']">
87            <td align="left" valign="top" rowspan="3"></td>
88            <td align="left" valign="top">
89              <input type="button" value="button_select_all" class="context"
90                       onclick="someJavaScriptFunctionThatWillBeReplaced"
91                       i18n:attributes="value"
92                       tal:attributes="onclick python:'toggleSelect(this, \'%s\', \'%s\')'
93                       % (cpsmcat('button_select_all'), cpsmcat('button_deselect_all'))"
94                       />
95              <input type="submit" name="folder_delete:method" value="button_delete"
96                     class="destructive" i18n:attributes="value"
97                     tal:attributes="onclick python:'return window.confirm(\'%s\')' %
98                     (cpsmcat('description_confirm_delete'), )"
99                     />
100            </td>
101          </tr>
102        </table>
103      </form>
104      <form action="" method="post" class="group" onsubmit="return submit_once()"
105            tal:attributes="action string:${context/absolute_url}/create_level"
106            tal:define="rows python: info['items'];"
107            tal:condition="create_level"
108            >
109        <table width="100%" cellspacing="0" cellpadding="2"
110               summary="contents of the folder"
111               class="folderButtons">
112          <tr>
113            <td align="left" valign="top" rowspan="3"></td>
114            <td align="left" valign="top">
115              <input type="submit" name="create_level"
116                       class="destructive"
117                       tal:attributes="onclick python:'return window.confirm(\'Do you really want to register for Level %s?\')' % create_level;
118                       value string: Register Courses for Level ${create_level}"
119                       />
120            </td>
121          </tr>
122        </table>
123      </form>         
124    </metal:main>
125 
126  </metal:body>
127</metal:html>
Note: See TracBrowser for help on using the repository browser.