Rev 9506 | Rev 12808 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
23 | reyssat | 1 | examtest=!sh cat $wims_home/$wims_sesdir/examreg.* 2>/dev/null |
2 | !if $examtest!=$empty |
||
3 | et=!words2items $examtest |
||
4 | !for i in $et |
||
5 | !if $i>0 |
||
6 | error=in_exam |
||
7 | type=none |
||
8 | !exit |
||
9 | !endif |
||
10 | !endif |
||
11 | |||
12 | !if $wims_user=supervisor |
||
13 | nam=sup |
||
14 | !else |
||
15 | nam=part |
||
16 | !endif |
||
10747 | bpr | 17 | !read adm/class/userdef classes,$wims_class,$wims_realuser |
18 | !set user_supervisable=!defof user_supervisable in $userdef |
||
19 | !if $user_supervisable=yes |
||
20 | !set user_supervise=!defof user_supervise in $userdef |
||
21 | !endif |
||
22 | if $wims_user=supervisor |
||
23 | !set user_supervise=!append item $wims_class to $user_supervise |
||
24 | !endif |
||
25 | !set user_participate=!defof user_participate in $userdef |
||
26 | |||
23 | reyssat | 27 | neib=!defof n_$nam in wimshome/log/classes/$wims_class/neighbors |
28 | pass=!defof user_password in $userdef |
||
29 | pass=!word 1 of $pass |
||
30 | |||
31 | directlist= |
||
9506 | bpr | 32 | |
23 | reyssat | 33 | !if $pass!=$empty |
34 | !for c in $neib |
||
35 | t=!defof n_$nam in wimshome/log/classes/$c/neighbors |
||
912 | bpr | 36 | !read adm/class/userdef classes,$c,$wims_user |
23 | reyssat | 37 | np=!defof user_password in $userdef |
38 | np=!word 1 of $np |
||
39 | np=!passcrypt $np |
||
40 | passc=!passcrypt $pass |
||
41 | !if $wims_class isitemof $t and $np=$passc |
||
5020 | bpr | 42 | !if $auth_method isitemof $auth_method_list |
43 | directlist=!append item $c $user_auth_external to $directlist |
||
44 | !else |
||
45 | directlist=!append item $c $wims_user to $directlist |
||
46 | !endif |
||
23 | reyssat | 47 | !endif |
48 | !next c |
||
49 | !endif |
||
50 | |||
51 | directlist=!append item $directlist to $wims_otherclass |
||
52 | directlist=!listuniq $directlist |
||
53 | directlist=!listcomplement $wims_class $wims_user in $directlist |
||
54 | directlist=!nonempty items $directlist |
||
5054 | bpr | 55 | directlist=!sort items $directlist |
23 | reyssat | 56 | directcnt=!itemcnt $directlist |
57 | !if $directcnt>0 |
||
9506 | bpr | 58 | !!! should be commented |
23 | reyssat | 59 | current_pass=$pass |
60 | !endif |
||
61 |