Subversion Repositories wimsdev

Rev

Rev 16891 | Blame | Compare with Previous | Last modification | View Log | RSS feed

  1. !if $user!=$empty
  2.   !readproc adm/class/userdef ,$wims_class,$user
  3.   !set tmp_=!getdef user_lastname,user_firstname in $userdef
  4.   !distribute item $tmp_ into lastname,firstname
  5. !endif
  6. !default name_student=!nosubst $lastname, $firstname
  7. !if $status!=OK
  8.   !form reply
  9.   <input type="hidden" name="job" value="select">
  10.   <input type="hidden" name="status" value="OK">
  11.   <fieldset class="property_fields halfwidth blockcenter">
  12.     <legend>$name_title
  13.   !if $user!=$empty
  14.     ($name_student)
  15.   !endif
  16.     </legend>
  17.    <div class="field box">
  18.       <label for="showsheet">$name_showsheet</label>
  19.       <br>
  20.   !set wims_formselect_switch=multiple size="$[min($activelist_cnt,10)]"
  21.   !formselect showsheet list $activlist prompt $(shs_title[$(activlist)])
  22.     </div>
  23.     <div class="wimscenter wimsform">
  24.       <input type="submit" value="$wims_name_Show">
  25.     </div>
  26.   !read script/choix.phtml
  27.    </fieldset>
  28.   !formend
  29. !else
  30.   !if $usercnt==0
  31.     $name_noparticipant
  32.   !else
  33.     !default showsheet=$activlist
  34.     !default graphics=0
  35.     !if $graphics=1
  36.       !default choice=first
  37.       !if $choice=all
  38.         !set choice=first
  39.       !endif
  40.     !else
  41.       !if $choice!=login
  42.         !reset loginlist
  43.       !endif
  44.     !endif
  45.     !set nbth=4
  46.     !if $user=$empty
  47.       <p>$name_click</p>
  48.     !endif
  49.     !if $graphics!=1
  50.       !set table_id=TABLE_userlist
  51.       !set table_class=sortable
  52.     !endif
  53.     $table_header
  54.     <thead>
  55.     <tr>
  56.     <th colspan="5"></th>
  57.     !for j in $showsheet
  58.       !if $(activ[$j])>0
  59.         <th colspan="2" class="small">$wims_name_Sheet $j <br>$(shs_title[$j])<br>($(nbexo$j) $name_exo)</th>
  60.         !increase nbth
  61.         !increase nbth
  62.       !endif
  63.     !next j
  64.     </tr>
  65.     $table_hdtr
  66.     <th scope="col">$wims_name_lastname, $wims_name_firstname</th>
  67.     <th scope="col">$name_lastconnexion</th>
  68.     <th scope="col" data-sort-method="number">$name_nbsessions</th>
  69.     <th scope="col" class="small" data-sort-method="number">$wims_name_cnt_exo<br> ($nbexototal $name_exo)</th>
  70.     <th>$name_total</th>
  71.     !for j in $showsheet
  72.       !if $(activ[$j])>0
  73.         <th class="small" scope="col" data-sort-method="number">$name_cnt_exo</th>
  74.         <th class="small" scope="col" data-sort-method="number">$name_time</th>
  75.       !endif
  76.     !next j
  77.     </tr>
  78.     </thead>
  79.     <tbody>
  80.     !!!no efficient !
  81.     !set nbpart=0
  82.     !for m=1 to $usercnt
  83.       !if $nbpart > $limitpart and $choice!=all
  84.         !break
  85.       !endif
  86.       !set uu=!record $m of wimshome/log/classes/$wims_class/.userlist
  87.       !distribute items $uu into lastname,firstname,uu
  88.       !if $choice=first and $m=1
  89.         !default user=$uu
  90.       !endif
  91.       !if $choice=all or ($choice=login and $uu isitemof $loginlist and $user=$empty) \
  92.           or ($choice=select and $uu isitemof $select_user)\
  93.         or $uu=$user\
  94.         or ($choice=filter and $varfilter_!=$empty)
  95.         !if $varfilter_!=$empty
  96.           !reset var_filter_test
  97.           !readproc adm/vfilter/testfilter $uu\
  98. $varfilter_
  99.           !if $var_filter_test!=1
  100.             !goto enduser
  101.           !endif
  102.         !endif
  103.         !set getraw=$uu
  104.         !increase nbpart
  105.         !readproc script/raw.proc
  106.         $table_tr
  107.         <td>
  108.           !href cmd=reply&job=useractivity&user=$uu $name_student
  109.         </td>
  110.         !for h = 1 to 2*$sheetcnt + 4
  111.           !set h1=$[($h+$h%2)/2-2]
  112.           !if $h <=4 or ($h>4 and $(activ[$h1])>0) and $h1 isitemof $showsheet
  113.             !if $h>2 and . notin $[$h/2]
  114.               !if $(data[$h])!=$empty
  115.                 !let tmp=!replace internal : by , in $(data[$h])
  116.                 !let tmp=$[$(tmp[1])*3600+$(tmp[2])*60+$(tmp[3])]
  117.               !else
  118.                 !let tmp=-1
  119.               !endif
  120.               <td data-sort="$tmp">$(data[$h])
  121.             !else
  122.               <td data-sort="$(data[$h])">$(data[$h])
  123.             !endif
  124.             !if $h=3 and $(data[$h])!=$empty and $(data[-1])>0
  125.               <span style="color:orange">+ $(data[-1])</span>
  126.             !endif
  127.             !set h2=$[$h%2]
  128.             !if $h1 isitemof $showsheet and $h2=1
  129.               !if , isin $showsheet
  130.                 !set bb=!select $databyday where column 1=$h1
  131.               !else
  132.                 !set bb=$(databyday[1;])
  133.               !endif
  134.               !if $bb!=$empty
  135.                 !set bb=!exec pari vecsum($(bb[6]))
  136.                 <span style="color:orange">+ $bb</span>
  137.               !endif
  138.             !endif
  139.             </td>
  140.           !endif
  141.         !next h
  142.         </tr>
  143.         !if $graphics=1
  144.           $table_tr
  145.           <td colspan="$[$nbth+1]" style="text-align:left;">
  146.           !read script/exobyday.phtml
  147.           </td></tr>
  148.         !endif
  149.       !endif
  150.   :enduser
  151.     !next m
  152.     </tbody>
  153.     $table_end
  154.     !read tablesort.phtml
  155.   !endif
  156. !endif
  157.  
  158. !if $choice!=all
  159.   !read adm/class/getnextuser $wims_class,$user,activity,user
  160. !endif
  161.