Subversion Repositories wimsdev

Rev

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

Rev Author Line No. Line
7290 bpr 1
!! Modify informations on the exercises in a sheet
1969 guerimand 2
!!
15763 guerimand 3
!distribute lines $wims_read_parm into dir,parm_,require_,weight_,title_,desc_,dep_,comment_,feedback_,attribut_,indiv_
14268 obado 4
!! !set orgtit_=!module title $dir
13640 obado 5
!set wims_form_method=post
4861 bpr 6
!form reply
12387 bpr 7
!reset table_center
12701 bpr 8
<input type="hidden" name="modif" value="$ex_" />
9
<input type="hidden" name="job" value="modify" />
10
<fieldset class="property_fields blockcenter">
11
  <legend>$wims_name_properties</legend>
12
  <div class="field box">
14268 obado 13
    !! if the sheet is active, the fields that may be changed are
14
    !! title, description, comment, feedback, attribut
12701 bpr 15
    <label for="mod_title">$wims_name_title</label>
14268 obado 16
    !!($name_oldtitle <em>$orgtit</em>)
12701 bpr 17
    <input size="50" name="mod_title" id="mod_title" value="$title_" />
18
  </div>
19
  <div class="field box fullwidth">
20
    <label for="mod_desc">$wims_name_Description</label>
13640 obado 21
    <textarea name="mod_desc" id="mod_desc" class="iEdit" maxlength="$edesc_limit">$desc_</textarea>
22
    <div class="formHelp">(&lt; $edesc_limit)</div>
12701 bpr 23
  </div>
24
  <div class="field box">
13640 obado 25
    !read adm/class/attribut.phtml
12701 bpr 26
  </div>
27
  <div class="field box fullwidth">
28
    <label for="mod_comment">$(name_shtab[7])</label>
13640 obado 29
    <textarea name="mod_comment" id="mod_comment" class="iEdit" maxlength="$edesc_limit">$comment_</textarea>
30
    <div class="formHelp">$name_desc_comment (&lt; $edesc_limit)</div>
12701 bpr 31
  </div>
14268 obado 32
  !if $activetest <= 0
15910 guerimand 33
 
34
!! require points
14268 obado 35
    <div class="field box">
15910 guerimand 36
      !let require_list=!values 10*v for v=0 to $require_limit
37
      !if $indivtechvar=$empty
38
        <label for="mod_require">$name_pointsasked</label>
39
        !let mod_require=$require_
40
        !formselect mod_require list $require_list
41
      !else
42
        <strong>$name_pointsasked</strong>
43
        !! --------- in case of individual sheet activated by a technical variable
44
        !let tmp=!row 2 to -1 of $require_
45
        !let require_=!row 1 of $require_
46
        !let require_1_=!column 1 of $tmp
47
        !let require_2_=!column 2 of $tmp
48
        $table_header
49
          <thead>
50
            <tr>
51
              <th><label for="mod_weight">$name_default</label></th>
52
              !for k in $listval
53
                <th><label for="require$k">$k</label></th>
54
              !next k
55
            </tr>
56
          </thead>
57
          <tbody>
58
            $table_tr
59
              <td>
60
                !let mod_require=$require_
61
                !formselect mod_require list $require_list
62
              </td>
63
              !for k=1 to $nbtechvalue
64
                <td>
65
                  !let p=!positionof item $(listval[$k]) in $require_1_
66
                  !if $p!=$empty
67
                    !let require$k=!item $p of $require_2_
68
                  !else
69
                    !let require$k=$require_
70
                  !endif
71
                  !formselect require$k list $require_list
72
                </td>
73
              !next k
74
            </tr>
75
          </tbody>
76
        $table_end
77
      !endif
14268 obado 78
    </div>
79
 
15910 guerimand 80
!! exotrymax (maximum try with score for an exo)
14268 obado 81
    !set mod_exotrymax=$get_exotrymax
82
    <div class="field box">
83
      <label for="exotrymax">$name_exotrymax</label>
84
      <input size="2" maxlength="2" name="mod_exotrymax" value="$mod_exotrymax" id="exotrymax" />
85
      !set wims_ref_class=wims_button_help float_right
86
      !href target=wims_mhelp cmd=help&special_parm=exotrymax $wims_name_help
87
    </div>
15910 guerimand 88
 
89
!! weight
14268 obado 90
    <div class="field box">
15910 guerimand 91
      !if $indivtechvar=$empty
92
        <label for="mod_weight">$name_weight</label>
93
        <input size="4" name="mod_weight" id="mod_weight" value="$weight_" />
94
        !set wims_ref_class=wims_button_help float_right
95
        !href target=wims_mhelp cmd=help&special_parm=weightexo $wims_name_help
96
      !else
97
        !! --------- in case of individual sheet activated by a technical variable
98
        <strong>$name_weight</strong>
99
        !let tmp=!row 2 to -1 of $weight_
100
        !let weight_=!row 1 of $weight_
101
        !let weight_1_=!column 1 of $tmp
102
        !let weight_2_=!column 2 of $tmp
103
        $table_header
104
          <thead>
105
            <tr>
106
              <th><label for="mod_weight">$name_default</label></th>
107
              !for k in $listval
108
                <th><label for="mod_weight$k">$k</label></th>
109
              !next k
110
            </tr>
111
          </thead>
112
          <tbody>
113
            $table_tr
114
              <td>
115
                <input size="4" name="mod_weight" id="mod_weight" value="$weight_" />
116
              </td>
117
              !for k=1 to $nbtechvalue
118
                <td>
119
                  !let p=!positionof item $(listval[$k]) in $weight_1_
120
                  !if $p!=$empty
121
                    !let v=!item $p of $weight_2_
122
                  !else
123
                    !let v=$weight_
124
                  !endif
125
                  <input size="4" name="weight$k" id="mod_weight$k" value="$v" />
126
                </td>
127
              !next k
128
            </tr>
129
          </tbody>
130
        $table_end
131
      !endif
14268 obado 132
    </div>
15910 guerimand 133
 
134
!! dependancies
14268 obado 135
    <div class="field box">
136
      <label for="mod_dep">$(name_shtab[6])</label>
137
      <input size="40" name="mod_dep" id="mod_dep" value="$dep_" />
138
      !set wims_ref_class=wims_button_help float_right
139
      !href target=wims_mhelp cmd=help&special_parm=dependancies $wims_name_help
140
      !reset mod_dep
141
    </div>
15910 guerimand 142
 
143
!! manage for indiv with techvar
15763 guerimand 144
    !if $indivtechvar!=$empty
145
      <div class="field box">
146
        <label for="indiv">$name_individualisation</label>
147
        !let mod_indiv=!listintersect $indiv_ and $listval
148
        !formcheckbox mod_indiv list $listval
149
        !set wims_ref_class=wims_button_help float_right
150
        !href target=wims_mhelp cmd=help&special_parm=indivtechvar $wims_name_help
151
        <div class="formHelp">$name_indiv_desc</div>
152
      </div>
153
    !endif
14268 obado 154
  !endif
14646 bpr 155
  !set feedback__=!rows2lines $feedback_
12701 bpr 156
  <div class="field box">
14268 obado 157
    <label for="mod_feedback">$(name_shtab[10])</label>
14646 bpr 158
    <textarea name="mod_feedback" id="mod_feedback" cols="60" class="nowrap">$feedback__</textarea>
14268 obado 159
    !set wims_ref_class=wims_button_help float_right
160
    !href target=wims_mhelp cmd=help&special_parm=feedback $wims_name_help
12701 bpr 161
  </div>
11037 obado 162
 
14268 obado 163
  !if $activetest <= 0
164
    !let oef=!defof category in wimshome/public_html/modules/$dir/INDEX
165
    !default oef=!defof category in wimshome/public_html/modules/$dir/index
166
    !if oef isitemof $oef
12701 bpr 167
      <div class="field box">
14268 obado 168
        <strong>$(name_shtab[9])</strong>
169
        !set parm__=$parm_
170
        !let parm_=!replace internal & by ; in $parm_;
171
        !let parm_=!replace internal scoredelay=; by scoredelay=0; in $parm_
172
        !let parm_=!replace internal exo=; by exo=0; in $parm_
173
        !let tmp_=!replace internal = by , in $parm_
174
        !let tmp2_=!column 1 of $tmp_
175
        !let tmp2_=!positionof item exo in $tmp2_
176
        !let tmp_=!column 2 of $tmp_
177
        !let tmp_=!item $tmp2_ of $tmp_
178
        !let tmp_=!nospace $tmp_
179
        !set wims_ref_class=wims_button float_right
180
        !href cmd=intro&module=$dir&special_parm=&special_parm2=&special_parm3=exo=$tmp_;$parm_&special_parm4=$sheet,$modif $(seriesaction[1])
181
        <pre>$dir
182
$parm_</pre>
183
      </div>
7400 bpr 184
 
14268 obado 185
      !read getparm $parm__ exo qnum random
186
      !set exocnt_=!itemcnt $get_exo
187
      !read adm/class/exo_order.phtml
188
 
12701 bpr 189
    !endif
14268 obado 190
  !endif activetest
191
</fieldset>
5926 bpr 192
 
14268 obado 193
<div class="wimscenter wimsform">
194
  <input type="submit" value="$wims_name_tosave" /> &nbsp;
195
  !set wims_ref_class=wims_button wims_secondary_button
196
  !href cmd=resume $wims_name_giveup
197
</div>
5926 bpr 198
!formend