Subversion Repositories wimsdev

Rev

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

  1. !nocache
  2. !if $oefsteps!=$empty
  3.   !set fieldtot=!itemcnt $thisstep
  4. !else
  5.   !set fieldtot=$[$choicecnt+$replycnt]
  6. !endif
  7.  
  8. !if $fieldtot<1
  9.   !changeto oef/noreply.phtml
  10. !endif
  11.  
  12. <!-- Begin oef/form.phtml-->
  13. !if $hasembedding!=yes
  14.   <fieldset class="oefform">
  15.   !set enter_reply_tag=legend
  16. !else
  17.   !set enter_reply_tag=h2
  18. !endif
  19.  
  20. !set N_=!itemcnt $embedded
  21. !if $fieldtot<=$N_
  22.   !goto send
  23. !endif
  24.  
  25. <$enter_reply_tag class="oef_enterreply">
  26. !if $error=$empty
  27.   $name_enterreply:
  28. !else
  29.   $name_correctreply:
  30. !endif
  31. </$enter_reply_tag>
  32.  
  33. !if $hasembedding!=yes
  34.   <datalist id="emptylist"><option value="??"></datalist>
  35.   !form reply name="replyform" onsubmit="return formcheck();" id="a_oefform" autocomplete="off" spellcheck="false"
  36. !endif
  37.  
  38. !if $oefsteps!=$empty and $oefstepcnt>1
  39.   <div>
  40.   !if $dynsteps=yes
  41.     ($name_step $oefstep)
  42.   !else
  43.     ($name_step $oefstep/$oefstepcnt)
  44.   !endif
  45.   </div>
  46. !endif
  47.  
  48. <table class="oefnoembed">
  49. !distribute item 1,1 into cntr,cntc
  50. !for t in $ansorder
  51.   !if $oefsteps=$empty or $t$(cnt$t) isitemof $thisstep
  52.     !read oef/form$t.phtml $(cnt$t)
  53.   !endif
  54.   !advance cnt$t
  55. !next t
  56. </table> <!-- end table oefnoembed -->
  57.  
  58. :send
  59. !if $wims_fill_list!=$empty and $fillcnt>0 and $wims_fill_type!=$empty
  60.   !read anstype/$wims_fill_type.after
  61. !endif
  62. !if $oef_formnosubmit!=yes
  63.   !if $oef_js_submit!=
  64.     !set oef_js_submit=onclick="javascript:$oef_js_submit;"
  65.   !else
  66.     !set oef_js_submit=
  67.   !endif
  68.   <div class="send_answer">
  69.     !if _check notin $wims_session
  70.       <input type="submit" $oef_js_submit value="$name_sendanswer">
  71.     !else
  72.       <input type="submit" $oef_js_submit value="$name_sendanswer" disabled="disabled">
  73.     !endif
  74.     !if $jquery_defined=yes
  75.       <div class="reveal" id="exo_formCheck" data-reveal>
  76.         <h1>$name_are_you_sure</h1>
  77.         <div class="wims_msg info small">$name_exo_form_check</div>
  78.         <button class="close-button" data-close aria-label="Close modal" type="button">
  79.           <span aria-hidden="true">&times;</span>
  80.         </button>
  81.         <div class="wimscenter">
  82.           <button class="submit wims_button" onclick="document.getElementById('a_oefform').submit();">$wims_name_yes</button>
  83.           <button type="button" class="wims_button wims_secondary_button" data-close>$wims_name_no</button>
  84.         </div>
  85.       </div>
  86.     !endif
  87.   </div>
  88. !endif
  89.  
  90. !formend
  91. !if $hasembedding!=yes and $fieldtot>0
  92.   </fieldset>
  93.   !! end of "oefform" fieldset
  94. !endif
  95.  
  96. !if $qcmgood<1 and $choicecnt>0
  97.   <p class="small">$name_remark</p>
  98. !endif
  99.