!read adm/css.phtml
!read adm/class/classname.phtml $wims_classname\
$wims_institutionname
!header1
<script type="text/javascript" src="scripts/js/wz_tooltip.js"></script>
!! not useful ???
!!!if $cmd=help
!! !read lang/help.phtml
!!!endif
!if $job!=$empty and $job!=sheets
!read $job.phtml
!endif
!read adm/title.phtml 1\
$classname\
$wims_name_part_list ($usercnt)
!if $error!=$empty
<div class="wims_alertmsg">
!read lang/msg.phtml.$moduclass_lang
</div>
!set wims_ref_class=wims_button
!if $wims_class!=$empty
!href module=home $wims_name_class_home
!else
!href module=home $wims_name_home
!endif
!endif
<div class="wimscenter">
!set class_Supervisor
=!defof class_Supervisor in wimshome
/log/classes
/$wims_class/.def
!!## the administrator at the level of the portal or the creator of the class can add a teacher to
!!## the list of teachers of his class
!if ($wims_typename iswordof group or $class_Supervisor=$wims_realuser) and $wims_supertype=2
!default wims_superclass=$wims_class
!set teacherlist
=!record
0 of wimshome
/log/classes
/$wims_superclass/.teacherlist
!set teachercnt=!linecnt $teacherlist
!if $teachercnt>0
!set wims_ref_class=wims_button
!href cmd=renew&job=teacher $wims_name_teacherlist
!endif
!!## only the administrator has the right to add a teacher to the superclass
!if $wims_typename iswordof group and $wims_supertype=2
!set wims_ref_class=wims_button
!href module=adm/class/reguser&step=1&utype=1 $wims_name_addteacher
!endif
!endif wims_typename=group etc
!set typen
=!defof class_typename in wimshome
/log/classes
/$wims_class/.def
!if $usercnt==0
$name_noyetparticipant
!if $typen!=level
!set wims_ref_class=wims_button
!href module=adm/class/reguser&step=1 $wims_name_addstudent
!endif
!set wims_ref_class=wims_button
!href cmd=reply&job=csv $wims_name_csv
</div>
!else -- $usercnt>0
!!## it is dangerous to register directly a student in a level
!if $typen!=level
!set deleted
=!sh cd
$wims_home/log/classes
/$wims_class/.users
; ls
.[0-9a
-zA
-Z
]* 2>/dev
/null
!set deleted
=!trim $deleted
!set wims_ref_class=wims_button
!href module=adm/class/reguser&step=1 $wims_name_addstudent
!endif
!set wims_ref_class=wims_button
!href cmd=reply&job=csv $wims_name_csv
!if $deleted!=$empty
!set wims_ref_class=wims_button
!href cmd=reply&job=recover $name_partdeleted
!endif
</div>
!if $seq_cnt=0
<p>
$name_warning_no_sequence
!set wims_ref_class=wims_button
!href module=adm/class/sequence&job=config $wims_name_config
</p>
!endif
!!test inutile ?
!if $usercnt > 0
!if $activecnt+$eactivecnt>=1
!form reply
<input type="hidden" name="job" value="sheets" />
!set wims_formselect_switch=multiple="multiple" size="$[min($activecnt,6)]"
$name_pickup
<div class="wimscenter">
!set seq_open
=!defof sequence_open in wimshome
/log/classes
/$wims_class/seq
/.def
!for i=1 to $activecnt
!set sh=!line $i of $activesheets
!set se=!item 1 of $sh
!if $seq_open!=yes
!set ti=!item 3 to -1 of $sh
!set ti=!replace internal , by , in $ti
!set tmp=!append item $se: $ti to $tmp
!else
!set ti=!item 4 to -1 of $sh
!set ti=!replace internal , by , in $ti
!set seq=!item 3 of $sh
!set tmp=!append item $seq/$se: $ti to $tmp
!endif
!set ash=$activesh
!for i=1 to $eactivecnt
!set tt=!item $i of $activexams
!set l
=!record
$tt of wimshome
/log/classes
/$wims_class/exams
/.exams
!set l=!line 4 of $l
!set l=!replace internal , by , in $l
!set tmp=!append item $name_Exam $tt: $l to $tmp
!set ash=!append item E$tt to $ash
!formselect showsheet
list $ash prompt
$tmp
</div>
<p>
$wims_name_or $name_post
!if $job_affi=notes or $job_affi=$empty
!set wims_ref_class=wims_button
!href cmd=reply&job_affi=quality $(name_affi[1])
!set wims_ref_class=wims_button
!href cmd=reply&job_affi=points $(name_affi[2])
<span class="wims_button disabled"> $(name_affi[3])</span>
!set wims_ref_class=wims_button
!href cmd=reply&job_affi=best $(name_affi[4])
!set wims_ref_class=wims_button
!href cmd=reply&job_affi=level $(name_affi[5])
!endif
!if $job_affi=quality
<span class="wims_button disabled"> $(name_affi[1])</span>
!set wims_ref_class=wims_button
!href cmd=reply&job_affi=points $(name_affi[2])
!set wims_ref_class=wims_button
!href cmd=reply&job_affi=notes $(name_affi[3])
!set wims_ref_class=wims_button
!href cmd=reply&job_affi=best $(name_affi[4])
!set wims_ref_class=wims_button
!href cmd=reply&job_affi=level $(name_affi[5])
!endif
!if $job_affi=points
!set wims_ref_class=wims_button
!href cmd=reply&job_affi=quality $(name_affi[1])
<span class="wims_button disabled"> $(name_affi[2])</span>
!set wims_ref_class=wims_button
!href cmd=reply&job_affi=notes $(name_affi[3])
!set wims_ref_class=wims_button
!href cmd=reply&job_affi=best $(name_affi[4])
!set wims_ref_class=wims_button
!href cmd=reply&job_affi=level $(name_affi[5])
!endif
!if $job_affi=best
!set wims_ref_class=wims_button
!href cmd=reply&job_affi=quality $(name_affi[1])
!set wims_ref_class=wims_button
!href cmd=reply&job_affi=points $(name_affi[2])
!set wims_ref_class=wims_button
!href cmd=reply&job_affi=notes $(name_affi[3])
<span class="wims_button disabled"> $(name_affi[4])</span>
!set wims_ref_class=wims_button
!href cmd=reply&job_affi=level $(name_affi[5])
!endif
!if $job_affi=level
!set wims_ref_class=wims_button
!href cmd=reply&job_affi=quality $(name_affi[1])
!set wims_ref_class=wims_button
!href cmd=reply&job_affi=points $(name_affi[2])
!set wims_ref_class=wims_button
!href cmd=reply&job_affi=notes $(name_affi[3])
!set wims_ref_class=wims_button
!href cmd=reply&job_affi=best $(name_affi[4])
<span class="wims_button disabled">$(name_affi[5])</span>
!endif
</p>
!else
!form reply
!endif
<p>
!if $wims_typename notwordof group portal
$name_click
!endif
$name_filter
<textarea name="varfilter">$varfilter</textarea>
!set wims_ref_class=wims_button_help float_right
!href cmd=help&special_parm=filter $wims_name_help
</p>
<div class="wimsform wimscenter">
<input type="submit" value="$wims_name_Show" />
</div>
!formend
!endif
$table_header
!if $wims_typename notwordof group portal
!if $job_affi=notes
<caption>$name_formula2</caption>
!else
!let tmp
=!recordcnt wimshome
/log/classes
/$wims_class/sheets
/.sheets
!let tmp=!values v for v=1 to $tmp
!let showsheet=!listintersect $showsheet and $tmp
!if $job_affi=quality
<caption>$name_qualitygot</caption>
!endif
!if $job_affi=points
<caption>$name_percentagedone</caption>
!endif
!if $job_affi=best
<caption>$name_percentagebest</caption>
!endif
!endif
!endif
!if $manual>0 and $job_affi=notes
$table_hdtr<th rowspan="2">$wims_name_lastname, $wims_name_firstname ($usercnt)</th>
<th colspan="3">$name_Average</th>
!for j in $showsheet
!if E isin $j
!set k=!char 2 to -1 of $j
<th rowspan="2" class="name_exam small">$name_Exam $k</th>
!else
<th rowspan="2" class="show_sheet small">
!set s
=!record
$j of wimshome
/log/classes
/$wims_class/sheets
/.sheets
!set s=!line 3 of $s
!set wims_ref_title=$s
!href cmd=reply&job=showsheet&numshowsheet=$j $name_Sheet $j
!!<a onmouseover="Tip('$s',$tooltip_parm)">$picto</a>
</th>
!endif
</tr>
$table_hdtr<th class="manual_notes small">$(name_manual_notes[1])</th>
<th class="manual_notes small">$(name_manual_notes[2])</th>
<th class="manual_notes small">$(name_manual_notes[3])</th>
!else
$table_hdtr<th>$wims_name_lastname, $wims_name_firstname ($usercnt)</th>
!if $wims_typename iswordof group portal
!goto endgroup
!endif
!if $job_affi=notes
<th class="average">$name_Average</th>
!endif
!for j in $showsheet
!if E isin $j
!set k=!char 2 to -1 of $j
<th class="name_exam small">$name_Exam $k</th>
!else
<th class="small">
!href cmd=reply&job=showsheet&numshowsheet=$j $name_Sheet $j
</th>
!endif
!endif
:endgroup
</tr>
!distribute item 0,0,0 into mean_tea,mean_auto,mean_glob
!distribute item 0,0,0 into cnt_tea,cnt_auto,cnt_glob
!for i=1 to $usercnt
!set uu
=!record
$i of wimshome
/log/classes
/$wims_class/.userlist
!distribute items $uu into lastname,firstname,uu
!if $varfilter_!=$empty
!read adm/class/testfilter $uu\
$varfilter_
!if $var_filter_test!=1
!goto enduser
!endif
!endif
!set UU=!hex $uu
$table_tr
<td>
!href cmd=reply&job=getuser&getuser=$uu#sheet$(showsheet[1]) $name_student1
!if $uu isitemof $wims_connectedlogin
<img src="gifs/themes/$wims_theme_icon/connected.png" width="15px" alt="connected" />
!endif
</td>
!if $wims_typename iswordof group portal
!goto enduser
!endif
!readproc adm/class/userscore
!if $manual>0 and $job_affi=notes
!set
glob=$
[rint
($manual*$
(manual_
$UU)+(100-$manual)*($per))/100]
!if $glob>0
!read adm
/class/colors $
[ceil($glob*10/$scoremax)]
<td style=$style_note>$glob
!else
<td>--
!endif
</td>
!if $(manual_$UU)>0
!read adm
/class/colors $
[ceil($
(manual_
$UU)*10/$scoremax)]
<td style=$style_note>$(manual_$UU)
!else
<td>--
!endif
</td>
!if $per>0
!read adm
/class/colors $
[ceil($per*10/$scoremax)]
<td style=$style_note>$per
!else
<td>--
!endif
</td>
!distribute item $[$mean_glob+$glob],$[$mean_tea+$(manual_$UU)] into mean_glob,mean_tea
!if $glob>0
!advance cnt_glob
!if $(manual_$UU)>0
!advance cnt_tea
!endif
!if $per>0
!advance cnt_auto
!endif
!endif
!else
!if $wims_typename iswordof group portal
</tr>
!goto enduser
!endif
!if $job_affi=notes
!if $per>0
!read adm
/class/colors $
[ceil($per*10/$scoremax)]
<td style=$style_note>$per
!advance cnt_auto
!advance cnt_glob
!else
<td>--
!endif
</td>
!endif
!endif
!set mean_auto=$[$mean_auto+$per]
!for j in $showsheet
!if E isin $j
!set k=!char 2 to -1 of $j
!set p_=$[rint(10*$scoremax*$(es_$k))/100]
!if NaN isin $p_
!set p_=0
!endif
!if $p_>0
!read adm
/class/colors $
[ceil($p_*10/$scoremax)]
<td style=$style_note>$p_
!else
<td>$p_
!endif
</td>
!else
!set p_=!line $j of $percents
!distribute words $p_ into p1,p2,p3,p4
!if $job_affi=notes
!if $p2!=$empty
!set sev=!line $j of $defaultformula
!distribute word $(sev) into w_$j,s,ss
!bound s between integer 0 and 6 default 2
!bound ss between integer 0 and 2 default 0
!set f_$j=!item $s+1 of $formula_list
!set f_$j=!replace internal I by I$ss in $(f_$j)
!distribute item $[$p1/100],$[$p2/10],$[$p3/100], $[$p4/100] into x0_,y_,x1_,x2_
!set ff_$j=!mathsubst Q=$y_ in $(f_$j)
!for sev=0 to 2
!set ff_$j=!mathsubst I$sev=$(x$(sev)_) in $(ff_$j)
!set p_=$[rint(100*$scoremax*$(ff_$j))/100]
!else
!set p_=0
!endif
!if $p_>0
!read adm
/class/colors $
[ceil(10*$p_/$scoremax)]
<td style=$style_note>$p_
!else
<td>--
!endif
</td>
!else
!if quality iswordof $job_affi
!set p_=$p2
!if $p_>0
!read adm
/class/colors $
[ceil($p_)]
<td style=$style_note>$p_
!else
<td>--
!endif
</td>
!endif
!if points iswordof $job_affi
!set p_=$p1
!if $p_>0
!read adm
/class/colors $
[ceil($p_/10)]
<td style=$style_note>$p_ %
!else
<td>--
!endif
</td>
!endif
!if best iswordof $job_affi
!set p_=$p3
!if $p_>0
!read adm
/class/colors $
[ceil($p_/10)]
<td style=$style_note>$p_ %
!else
<td>--
!endif
</td>
!endif
!if level iswordof $job_affi
!set p_=$[$p4/10]
!if $p_>0
!read adm
/class/colors $
[ceil($p_)]
<td style=$style_note>$p_
!else
<td>--
!endif
</td>
!endif
!if $p2=$empty
!set $p_=0
!endif
!endif
!endif
!set per_$j=$[$(per_$j)+$p_]
!if $p_>0
!advance cnt_$j
!endif
</tr>
:enduser
!if $wims_typename iswordof group portal
</table>
!endif
!distribute item $[rint(100*$mean_auto/$usercnt)/100],\
$[rint(100*$mean_tea/$usercnt)/100],\
$[rint(100*$mean_glob/$usercnt)/100] into m_auto,m_tea,m_glob
$table_hdtr<th>$name_classAverage</th>
!if $job_affi=notes
!if $manual>0
!if $m_glob >0
!read adm
/class/colors $
[ceil($m_glob*10/$scoremax)]
<td style=$style_note>$m_glob
!else
<td>--
!endif
</td>
!if $m_tea >0
!read adm
/class/colors $
[ceil($m_tea*10/$scoremax)]
<td style=$style_note>$m_tea
!else
<td>--
!endif
</td>
!if $m_auto>0
!read adm
/class/colors $
[ceil($m_auto*10/$scoremax)]
<td style=$style_note>$m_auto
!else
<td>--
!endif
</td>
!else
!if $m_auto>0
!read adm
/class/colors $
[ceil($m_auto*10/$scoremax)]
<td style=$style_note>$m_auto
!else
<td>--
!endif
</td>
!endif
!endif
!for j in $showsheet
!if $
[rint
(100*$
(per_
$j)/max(1,$usercnt))/100]>0
!if $job_affi=points
!read adm
/class/colors $
[ceil($
(per_
$j)/max(1,$usercnt)/10)]
<td style
=$style_note>$
[rint
(100*$
(per_
$j)/max(1,$usercnt))/100] %
!else
!read adm
/class/colors $
[ceil($
(per_
$j)/max(1,$usercnt)*10/$scoremax)]
<td style
=$style_note>$
[rint
(100*$
(per_
$j)/max(1,$usercnt))/100]
!endif
!else
<td>--
!endif
</td>
!if $cnt_glob>0
!distribute item $
[rint
(100*$mean_auto/max(1,$cnt_auto))/100],\
$
[rint
(100*$mean_tea/max(1,$cnt_tea))/100],\
$
[rint
(100*$mean_glob/max(1,$cnt_glob))/100] into m_auto
,m_tea
,m_glob
</tr>
$table_hdtr<th>$name_posAverage</th>
!if $manual>0
!if $m_glob>0
!read adm
/class/colors $
[ceil($m_glob*10/$scoremax)]
<td style=$style_note>$m_glob
!else
<td>--
!endif
</td>
!if $m_tea>0
!read adm
/class/colors $
[ceil($m_tea*10/$scoremax)]
<td style=$style_note>$m_tea
!else
<td>--
!endif
</td>
!if $m_auto>0
!read adm
/class/colors $
[ceil($m_auto*10/$scoremax)]
<td style=$style_note>$m_auto
!else
<td>--
!endif
</td>
!else
!if $m_auto>0
!read adm
/class/colors $
[ceil($m_auto*10/$scoremax)]
<td style=$style_note>$m_auto
!else
<td>--
!endif
</td>
!endif
!for j in $showsheet
!if $
[rint
(100*$
(per_
$j)/max(1,$
(cnt_
$j)))/100]>0
!read adm
/class/colors $
[ceil($
(per_
$j)/max(1,$
(cnt_
$j))*10/$scoremax)]
<td style
=$style_note>$
[rint
(100*$
(per_
$j)/max(1,$
(cnt_
$j)))/100]
!else
<td>--
!endif
</td>
!endif
</tr>
$table_end
!endif (usercnt=0?)
!set wims_menu_items=!append line sendmail,1,module=adm/class/sendmail\
photoboard,1,module=adm/class/photoboard\
to $wims_menu_items
!if $typen!=level
!set wims_menu_items=!append line addstudent,1,module=adm/class/reguser&step=1\
to $wims_menu_items
!endif
!! disconnected
for a few
time
!!!set wims_menu_items=!append line csv,1,cmd=reply&job=csv\
!! ,0,\
!!to $wims_menu_items
!! :end (deplacement plus haut pour l
'instant)
!tail
!reset job,showsheet,getuser,getraw,delprep,deluser,formula,abandon,reg,\
passcheck