Subversion Repositories wimsdev

Rev

Rev 17606 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
16309 guerimand 1
!! process control page for view student work in type=3
14537 guerimand 2
 
16309 guerimand 3
!if $loadwork!=1
14537 guerimand 4
  error=badallows
5
  emptypage=yes
6
  !exit
7
!endif
8
 
16309 guerimand 9
!if $userv notitemof $ulist
10
  error=exolog-nouser
11
  job=configfw
12
  !changeto $job.proc
13
  !exit
14
!endif
16324 guerimand 15
 
16
!! ------- preparing date format
17
d1=!text select char 0123456789 in $(deadline)$(timedeadline)
18
d2=!text select char 0123456789 in $(soldate)$(timesoldate)
19
now=!text select char 0123456789 in $wims_now
20
now=!char 1 to 12 of $now
21
!reset toolate
22
!if $now>$d1
23
  toolate=yes
24
!endif
25
!readproc adm/date.phtml $(deadline)
26
tmp=!replace internal : by H in $timedeadline
27
!let date1=$l_date_out $wims_name_at $tmp
28
!readproc adm/date.phtml $(soldate)
29
tmp=!replace internal : by H in $timesoldate
30
!let date2=$l_date_out $wims_name_at $tmp
31
 
32
 
14537 guerimand 33
!! ---- read structure of the freework
14820 guerimand 34
!distribute item 0,0,$empty into nbrezoneteacher,nbrezonestudent,ltdownloadzone
14537 guerimand 35
nb=!recordcnt wimshome/log/classes/$wims_class/freeworks/.freework$freework
36
!for k=1 to $nb
37
  dt=!record $k of wimshome/log/classes/$wims_class/freeworks/.freework$freework
38
  l=!line 1 of $dt
39
  !distribute word $l into t,u
40
  !bound u within teacher,student default teacher
14788 guerimand 41
  !bound t within solution,$listfilename_ztype default $(listfilename_ztype[1])
42
  !if $t!=solution
14537 guerimand 43
    !increase nbrezone$u
44
    ztype$(u)$(nbrezone$u)=$t
45
    script_data=!line 2 to -1 of $dt
46
    !readproc applet/$t pararead $u $(nbrezone$u)
14788 guerimand 47
    !! -- read display parameters for each zone
16324 guerimand 48
    !readproc applet/$t displayread $u $(nbrezone$u) 0 $userv
14537 guerimand 49
  !endif
50
!next k
16324 guerimand 51
ltdownloadzone=!listintersection $ltdownloadzone and $zonelistlabelstudent
52
 
14867 obado 53
!!if $putiworkco=1
54
!!  iedit_activated=1
55
!!endif
14537 guerimand 56
 
17606 czzmrn 57
!if $showstudlist!=yes
16309 guerimand 58
  error=noinlineanswer
59
  job=configfw
60
  !changeto $job.proc
61
!endif
14758 guerimand 62
 
14537 guerimand 63
!set appletnum=0
64
 
65
!readproc adm/class/userdef ,$wims_class,$userv
66
tmp=!defof user_firstname,user_lastname in $userdef
67
!distribute item $tmp into lastname,firstname
16568 guerimand 68
remark=!record 0 of wimshome/log/classes/$wims_class/freeworksdata/$freework/co/.$userv
14537 guerimand 69
remark=!replace internal : by : in $remark
16568 guerimand 70
finalremark=!record 0 of wimshome/log/classes/$wims_class/freeworksdata/$freework/co/$userv
71
finalremark=!replace internal : by : in $finalremark
17780 czzmrn 72
!! !set wims_menu_items=!append line $name_managefreework,1,module=$module&cmd=new&job=configfw&freework=$freework to $wims_menu_items
16324 guerimand 73
 
74
!! ------ delete file 
75
!if $job2=eraseusersol
76
 namefile=!text select 1234567890azertyuiopqsdfghjklmwxcvbnAZERTYUIOPMLKJHGFDSQWXCVBN. in $namefile
77
 !sh rm -f $wims_home/log/classes/$wims_class/freeworksdata/$freework/co/$(userv)-file/$namefile 2>\dev\null;
78
!endif
79
!readproc proc/findfile3.proc $freework,$userv