File: participant.phtml

package info (click to toggle)
wims 2%3A4.29a%2Bdfsg1-3
  • links: PTS, VCS
  • area: main
  • in suites: trixie
  • size: 185,704 kB
  • sloc: xml: 366,687; javascript: 120,570; ansic: 62,341; java: 62,170; sh: 7,744; perl: 3,937; yacc: 3,217; cpp: 1,915; lex: 1,805; makefile: 1,084; lisp: 914; pascal: 601; python: 520; php: 318; asm: 7
file content (208 lines) | stat: -rw-r--r-- 6,074 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
<div class="wims_content">

!read search.phtml
!if $overflow=yes
  !goto end
!endif
!if $clcnt+$sccnt+$directcnt<1
  !if $keyword=$empty
    $name_language
    !href module=home&list=0 $wims_name_search
  !else
    <p class="wims_msg info">$name_nofound</p>
  !endif
  !goto end
!endif
!if $wims_user!=$empty
  !read direct.phtml
  !if $wims_user!=supervisor and $superclass_orig=$empty
    !!goto end
  !endif
!else
  $name_text1
!endif


!set super_mixed_auth=!defof class_mixed_external_auth in wimshome/log/classes/$wims_superclass/.def
!if $sccnt>0 and $super_mixed_auth!=2
  !set table_id=TABLE_portal
  !set table_class=sortable
  $table_header
  <caption>$name_portalandgroup</caption>
  <thead>
  $table_hdtr
    <th scope="col">$wims_name_name</th>
    <th scope="col" data-sort-method="none">$wims_name_action</th>
    <th scope="col">$wims_name_Supervisor</th>
    <th scope="col">$wims_name_Status</th>
  </tr>
  </thead>
  <tbody>
  !for i=1 to $sccnt
    !set l=!line $i of $sclasses
    !distribute items $l into code,expire,inst,cl,la,ty,lv,pswd
    !!!if $sclass=$empty
     !set show=$inst<br>$cl
    !!!else
    !! !set show=$inst
    !!!endif
    !set supv=!item 9 of $l
    !if $supv=$empty
      !reset class_password
      !defread wimshome/log/classes/$code/.def
      !set supv=$class_supervisor
      !set pswd=$class_password
    !endif
    $table_tr<td>
    !!!href module=$module&type=authparticipant&class=$code
    $show
    </td>
    !read adm/class/initclass $code,auth
    !defread wimshome/log/classes/$code/.def
    !if $class_auth isitemof $auth_method_list and $(class_$(class_auth)_auth)!=$empty
      !set tmp_parm=&subclass=yes
      !read participant2.phtml
      !reset tmp_parm
    !else
      <td>
      !set wims_ref_class=wims_button
      !href module=$module&type=authparticipant&class=$code&subclass=yes $wims_name_Enter
      </td>
    !endif
    <td>
    $supv
    </td><td>
      !if $pswd=$empty
        <span class="wims_label open">$name_open</span>
      !else
        <span class="wims_label wims_warning">$name_protected</span>
      !endif
    </td></tr>
  !next i
  </tbody>
  $table_end
  !read tablesort.phtml
!endif

!if $clcnt>0 and $super_mixed_auth!=2
  !set table_id=TABLE_cls
  !set table_class=sortable
  $table_header
  !if $superclass_orig=$empty
    <caption>$name_independantclass</caption>
    <thead>
    $table_hdtr
    <th scope="col">$wims_name_name</th>
    <th scope="col" data-sort-method="none">$wims_name_action</th>
    <th scope="col">$wims_name_nameteacher</th>
    <th scope="col">$wims_name_level</th>
    <th scope="col">$wims_name_Status</th>
  !else
    !if $splevel>1
      !set inst=!defof class_description in wimshome/log/classes/$superclass2/.def
    !else
      !set inst=!defof class_institution in wimshome/log/classes/$superclass_orig/.def
    !endif
    <caption>$Name_levels ($inst)
    !if $splevel>1
      !href cmd=reply&type=$type&superclass2=$sparent $name_up
    !endif
    </caption>
    <thead>
    $table_hdtr
     <th scope="col">$wims_name_name</th>
     <th scope="col" data-sort-method="none">$wims_name_action</th>
     <th scope="col">$wims_name_nameteacher</th>
     <th scope="col">$wims_name_level</th>
     <th scope="col">$wims_name_Status</th>
    !if $superclass_orig!=$empty and $stype=4
      <th scope="col">+</th>
    !endif
  !endif
  </tr>
  </thead>
  <tbody>
  !!! put it var.proc ??
  !set directlist_=!replace internal , by $ ; $ $ in $directlist
  !for i=1 to $clcnt
    !set l=!line $i of $classes
    !distribute items $l into code,expire,inst,cl,la,ty,lv,pswd
    !set supv=!item 9 of $l
    !if $supv=$empty
      !reset class_password
      !defread wimshome/log/classes/$code/.def
      !set lv=$class_level
      !set supv=$class_supervisor
      !set pswd=$class_password
    !endif
    !distribute char $lv into l_,y_
    !if $superclass_orig=$empty
      !set show=$inst <br>$cl
    !else
      !set show=$cl
    !endif
    !read adm/class/initclass $code,auth
    !defread wimshome/log/classes/$code/.def
    $table_tr<td>
      $show
    </td>
    !if $auth_method isitemof $auth_method_list and $host_auth!=$empty
      !read participant2.phtml
    !else
      <td>
      !! obligatory course
      !set tmp=!defof class_ocourses in wimshome/log/classes/$class_parent/.def
      !if $code notwordof $directlist_ \
          and $code notitemof $user_participate,$user_supervise\
          and ($class_typename!=level or $wims_user=supervisor)
        !set wims_ref_class=wims_button
        !! obligatory course or optionel course but not registered in the parent
        !if $class_typename=course and (($tmp!=$empty and $tmp isin $code) \
          or $class_parent notitemof $user_participate)
          <span style="color:grey">$name_register</span>
        !else
          !if $wims_user=$empty
            !href module=$module&type=authparticipant&class=$code&subclass=yes $wims_name_Enter
          !else
            !href module=adm/class/reguser&class=$code&subclass=yes&auth_user=$wims_user $name_register
          !endif
        !endif
      !else
        !if $splevel=$empty or $splevel=2 and $code notitemof $tmp
          !set wims_ref_class=wims_button
          !href module=$module&type=authparticipant&class=$code&subclass=yes&auth_user=$wims_user $wims_name_Enter
        !else
          <span style="color:grey">$name_register</span>
        !endif
      !endif
      </td>
    !endif
    <td>
    $supv
    </td><td>$(wims_name_n_$l_)<br>$name_year $y_</td>
    <td>
      !if $pswd=$empty
        <span class="wims_label open">$name_open</span>
      !else
        <span class="wims_label wims_warning">$name_protected</span>
      !endif
    </td>
    !if $superclass_orig!=$empty and $stype=4
      <td>
      !if $ty!=1 and $splevel!=3
      !set wims_ref_class=wims_button
        !href cmd=reply&type=$type&superclass2=$code $sousclasses
      !else
        -
      !endif
      </td>
    !endif
    </tr>
    :endloop
  !next i
  </tbody>
  $table_end
  !read tablesort.phtml
!endif
:end
</div>