Subversion Repositories wimsdev

Rev

Rev 11243 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
23 reyssat 1
 
2
!if $job=first
12616 bpr 3
  this=$wims_superclass
23 reyssat 4
!else
12616 bpr 5
  icourse=$course
6
  this=$wims_superclass/$($job)
23 reyssat 7
!endif
8
teacherlist=!record 0 of $classdir1/.teacherlist
9
teachercnt=!linecnt $teacherlist
10597 bpr 10
!reset list1 list2 prompt
23 reyssat 11
cnt1=0
12
cnt2=0
13
 
14
!if $teachercnt<=0
12616 bpr 15
  !exit
23 reyssat 16
!endif
17
 
18
!if $more!=$empty
12616 bpr 19
  !! ??? Why ???
11234 bpr 20
  !if $wims_class/ notin $this/
21
    progtest=!defof sharing_exam in wimshome/log/classes/$this/neighbors
22
    !if $wims_class!=$progtest
23
      check=no
24
    !endif
23 reyssat 25
  !endif
11234 bpr 26
  !if $check!=no
27
    !for more_ in $more
28
      check_=!defof user_supervisable in $classdir1/.users/$more_
29
      !if $check_=yes
30
        supervise=!defof user_supervise in $classdir1/.users/$more_
31
        !if $actype=del
32
         sup2=!listcomplement $this in $supervise
33
        !endif
34
        !if $actype=add
35
          sup2=!listunion $supervise and $this
36
        !endif
37
        !if $sup2!=$supervise
38
          !setdef !set user_supervise=$sup2 in $classdir1/.users/$more_
39
        !endif
40
      !endif
11243 bpr 41
    !next
11234 bpr 42
    !read adm/gateway/mkteacherlist
43
    !reset more
23 reyssat 44
  !endif
45
!endif
46
 
47
main=!defof class_Supervisor in wimshome/log/classes/$this/.def
48
 
49
!for i=1 to $teachercnt
11234 bpr 50
  l=!line $i of $teacherlist
51
  !distribute items $l into last,first,l
52
  !if $l!=$main
53
    supervise=!defof user_supervise in $classdir1/.users/$l
54
    !if $this isitemof $supervise
55
      list1=!append item $i to $list1
56
    !else
57
      list2=!append item $l to $list2
58
      prompt=!append item $first $last ($l) to $prompt
59
    !endif
23 reyssat 60
  !endif
61
!next i
62
cnt1=!itemcnt $list1
63
cnt2=!itemcnt $list2