ajax_ticket.blade.php 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391
  1. <form id="J_ticketWrap" enctype="multipart/form-data" class="form-horizontal" action="{{ route('recruit.create_ticket') }}" method="post">
  2. <input type="hidden" name="_token" value="{{ csrf_token() }}" />
  3. <input type="hidden" name="recruit_id" value="{{ $recruit->id }}">
  4. <input type="hidden" name="ticket_type" id="ticket_type" value="pen" />
  5. <div class="box-body">
  6. <div class="nav-tabs-custom">
  7. <ul class="nav nav-tabs">
  8. @if(in_array('3',explode(',',$recruit->step)))
  9. <li data-ticketType="pen">
  10. <a href="#tab-form-1" data-toggle="tab">
  11. 笔试 <i class="fa fa-exclamation-circle text-red hide"></i>
  12. </a>
  13. </li>
  14. @endif
  15. @if(in_array('4',explode(',',$recruit->step)))
  16. <li data-ticketType="check">
  17. <a href="#tab-form-2" data-toggle="tab">
  18. 上机 <i class="fa fa-exclamation-circle text-red hide"></i>
  19. </a>
  20. </li>
  21. @endif
  22. @if(in_array('5',explode(',',$recruit->step)))
  23. <li data-ticketType="face">
  24. <a href="#tab-form-3" data-toggle="tab">
  25. 面试 <i class="fa fa-exclamation-circle text-red hide"></i>
  26. </a>
  27. </li>
  28. @endif
  29. @if(in_array('6',explode(',',$recruit->step)))
  30. <li data-ticketType="reexamine">
  31. <a href="#tab-form-4" data-toggle="tab">
  32. 复试 <i class="fa fa-exclamation-circle text-red hide"></i>
  33. </a>
  34. </li>
  35. @endif
  36. </ul>
  37. <div class="tab-content fields-group">
  38. @if(in_array('3',explode(',',$recruit->step)))
  39. <div class="tab-pane" id="tab-form-1" style="width: 1000px">
  40. @if($recruit->pen_ticket_type < 0)
  41. <div class="notice">
  42. 您已设置不需要准考证,请返回招考编辑页更改设置。
  43. </div>
  44. @else
  45. @if(empty($recruit->pen_ticket_content))
  46. <div class="notice">
  47. 您未设置笔试准考证模板,请联系技术人员上传。
  48. </div>
  49. @else
  50. @if($recruit->pen_ticket_status > 0)
  51. <div class="notice">
  52. 笔试准考证正在生成中或已生成,暂不允许操作,有疑问请联系技术人员。
  53. </div>
  54. @else
  55. <div class="tips">
  56. <p>
  57. 1.生成准考证前您可以下载已经上传的模板,确认是否有误!
  58. </p>
  59. <p>
  60. 2.生成准考证的模板变量包括:({{ $recruit->pen_ticket_field }}),非ex开头的将自动抓取报名表里面的数据。
  61. </p>
  62. <p>
  63. 3.最终生成的准考证为pdf格式。
  64. </p>
  65. <p>
  66. 4.该生成操作目前不可逆,请谨慎操作。
  67. </p>
  68. <p>
  69. 5.自动生成准考证仅能从准考证号、考室号、座位号三个进行生成,其余字段请确保模板中已存在。
  70. </p>
  71. <p>
  72. 6.<a href="{{ route('recruit.ticket_data_template',['recruit_id' => $recruit->id,'type' => 'pen']) }}" target="_blank">点我下载</a>准考证导入信息模板。
  73. </p>
  74. <p>
  75. 7.每间考场人数的设置仅在选择自动生成模式时有效。
  76. </p>
  77. </div>
  78. <div class="form-group">
  79. <label for="type" class="col-sm-2 astrisk control-label">准考证生成方式:</label>
  80. <div class="col-sm-8">
  81. <label class="radio-inline">
  82. <input type="radio" name="pen[type]" value="0" data-ref="pen" class="minimal type" style="position: absolute; opacity: 0;">&nbsp;不需要数据&nbsp;&nbsp;
  83. </label>
  84. <label class="radio-inline">
  85. <input type="radio" name="pen[type]" value="1" data-ref="pen" class="minimal type" checked="" style="position: absolute; opacity: 0;">&nbsp;自动生成&nbsp;&nbsp;
  86. </label>
  87. <label class="radio-inline">
  88. <input type="radio" name="pen[type]" value="2" data-ref="pen" class="minimal type" style="position: absolute; opacity: 0;">&nbsp;模板上传&nbsp;&nbsp;
  89. </label>
  90. </div>
  91. </div>
  92. <div class="form-group ">
  93. <label for="apply_start" class="col-sm-2 astrisk control-label">打印时间段</label>
  94. <div class="col-sm-8">
  95. <div class="row" style="width: 470px">
  96. <div class="col-lg-6">
  97. <div class="input-group">
  98. <span class="input-group-addon"><i class="fa fa-calendar"></i></span>
  99. <input type="text" name="pen[ex_start]" value="" class="form-control ex_start" style="width: 200px"></div>
  100. </div>
  101. <div class="col-lg-6">
  102. <div class="input-group">
  103. <span class="input-group-addon"><i class="fa fa-calendar"></i></span>
  104. <input type="text" name="pen[ex_end]" value="" class="form-control ex_end" style="width: 200px"></div>
  105. </div>
  106. </div>
  107. </div>
  108. </div>
  109. <div id="pen_autoCreate">
  110. <div class="form-group">
  111. <label for="auto_each_number" class="col-sm-2 control-label">每间考场人数</label>
  112. <div class="col-sm-5">
  113. <div class="input-group">
  114. <span class="input-group-addon"><i class="fa fa-pencil fa-fw"></i></span>
  115. <input type="text" id="auto_each_number" name="pen[auto_each_number]" value="35" class="form-control auto_each_number" placeholder="输入每间考场人数">
  116. </div>
  117. </div>
  118. </div>
  119. </div>
  120. <div id="pen_fetchCreate" style="display: none">
  121. <div class="form-group ">
  122. <label for="test" class="col-sm-2 control-label">准考证数据</label>
  123. <div class="col-sm-8">
  124. <div class="file-input file-input-new">
  125. <input type="file" name="pen[data]" />
  126. </div>
  127. </div>
  128. </div>
  129. </div>
  130. @endif
  131. @endif
  132. @endif
  133. </div>
  134. @endif
  135. @if(in_array('4',explode(',',$recruit->step)))
  136. <div class="tab-pane" id="tab-form-2">
  137. {{-- todo--}}
  138. </div>
  139. @endif
  140. @if(in_array('5',explode(',',$recruit->step)))
  141. <div class="tab-pane" id="tab-form-3" style="width: 1000px">
  142. @if($recruit->face_ticket_type < 0)
  143. <div class="notice">
  144. 您已设置不需要准考证,请返回招考编辑页更改设置。
  145. </div>
  146. @else
  147. @if(empty($recruit->face_ticket_content))
  148. <div class="notice">
  149. 您未设置面试准考证模板,请联系技术人员上传。
  150. </div>
  151. @else
  152. @if($recruit->face_ticket_status > 0)
  153. <div class="notice">
  154. 面试准考证正在生成中或已生成,暂不允许操作,有疑问请联系技术人员。
  155. </div>
  156. @else
  157. <div class="tips">
  158. <p>
  159. 1.生成准考证前您可以下载已经上传的模板,确认是否有误!
  160. </p>
  161. <p>
  162. 2.生成准考证的模板变量包括:({{ $recruit->face_ticket_field }}),非ex开头的将自动抓取报名表里面的数据。
  163. </p>
  164. <p>
  165. 3.最终生成的准考证为pdf格式。
  166. </p>
  167. <p>
  168. 4.该生成操作目前不可逆,请谨慎操作。
  169. </p>
  170. <p>
  171. 5.自动生成准考证仅能从准考证号、考室号、座位号三个进行生成,其余字段请确保模板中已存在。
  172. </p>
  173. <p>
  174. 6.<a href="{{ route('recruit.ticket_data_template',['recruit_id' => $recruit->id,'type' => 'face']) }}" target="_blank">点我下载</a>准考证导入信息模板。
  175. </p>
  176. <p>
  177. 7.每间考场人数的设置仅在选择自动生成模式时有效。
  178. </p>
  179. </div>
  180. <div class="form-group">
  181. <label for="type" class="col-sm-2 astrisk control-label">准考证生成方式:</label>
  182. <div class="col-sm-8">
  183. <label class="radio-inline">
  184. <input type="radio" name="face[type]" value="0" data-ref="face" class="minimal type" checked="" style="position: absolute; opacity: 0;">&nbsp;不需要准考证&nbsp;&nbsp;
  185. </label>
  186. <label class="radio-inline">
  187. <input type="radio" name="face[type]" value="1" data-ref="face" class="minimal type" style="position: absolute; opacity: 0;">&nbsp;自动生成&nbsp;&nbsp;
  188. </label>
  189. <label class="radio-inline">
  190. <input type="radio" name="face[type]" value="2" data-ref="face" class="minimal type" style="position: absolute; opacity: 0;">&nbsp;模板上传&nbsp;&nbsp;
  191. </label>
  192. </div>
  193. </div>
  194. <div class="form-group ">
  195. <label for="apply_start" class="col-sm-2 astrisk control-label">打印时间段</label>
  196. <div class="col-sm-8">
  197. <div class="row" style="width: 470px">
  198. <div class="col-lg-6">
  199. <div class="input-group">
  200. <span class="input-group-addon"><i class="fa fa-calendar"></i></span>
  201. <input type="text" name="face[ex_start]" value="" class="form-control ex_start" style="width: 200px"></div>
  202. </div>
  203. <div class="col-lg-6">
  204. <div class="input-group">
  205. <span class="input-group-addon"><i class="fa fa-calendar"></i></span>
  206. <input type="text" name="face[ex_end]" value="" class="form-control ex_end" style="width: 200px"></div>
  207. </div>
  208. </div>
  209. </div>
  210. </div>
  211. <div id="face_autoCreate" style="display: none">
  212. <div class="form-group">
  213. <label for="auto_each_number" class="col-sm-2 control-label">每间考场人数</label>
  214. <div class="col-sm-5">
  215. <div class="input-group">
  216. <span class="input-group-addon"><i class="fa fa-pencil fa-fw"></i></span>
  217. <input type="text" id="auto_each_number" name="face[auto_each_number]" value="35" class="form-control auto_each_number" placeholder="输入每间考场人数">
  218. </div>
  219. </div>
  220. </div>
  221. </div>
  222. <div id="face_fetchCreate" style="display: none">
  223. <div class="form-group ">
  224. <label for="test" class="col-sm-2 control-label">准考证数据</label>
  225. <div class="col-sm-8">
  226. <div class="file-input file-input-new">
  227. <input type="file" name="face[data]" />
  228. </div>
  229. </div>
  230. </div>
  231. </div>
  232. @endif
  233. @endif
  234. @endif
  235. </div>
  236. @endif
  237. @if(in_array('6',explode(',',$recruit->step)))
  238. <div class="tab-pane" id="tab-form-4" style="width: 1000px">
  239. @if($recruit->reexamine_ticket_type < 0)
  240. <div class="notice">
  241. 您已设置不需要准考证,请返回招考编辑页更改设置。
  242. </div>
  243. @else
  244. @if(empty($recruit->reexamine_ticket_content))
  245. <div class="notice">
  246. 您未设置复试准考证模板,请联系技术人员上传。
  247. </div>
  248. @else
  249. @if($recruit->reexamine_ticket_status > 0)
  250. <div class="notice">
  251. 复试准考证正在生成中或已生成,暂不允许操作,有疑问请联系技术人员。
  252. </div>
  253. @else
  254. <div class="tips">
  255. <p>
  256. 1.生成准考证前您可以下载已经上传的模板,确认是否有误!
  257. </p>
  258. <p>
  259. 2.生成准考证的模板变量包括:({{ $recruit->reexamine_field }}),非ex开头的将自动抓取报名表里面的数据。
  260. </p>
  261. <p>
  262. 3.最终生成的准考证为pdf格式。
  263. </p>
  264. <p>
  265. 4.该生成操作目前不可逆,请谨慎操作。
  266. </p>
  267. <p>
  268. 5.自动生成准考证仅能从准考证号、考室号、座位号三个进行生成,其余字段请确保模板中已存在。
  269. </p>
  270. <p>
  271. 6.<a href="{{ route('recruit.ticket_data_template',['recruit_id' => $recruit->id,'type' => 'reexamine']) }}" target="_blank">点我下载</a>准考证导入信息模板。
  272. </p>
  273. <p>
  274. 7.每间考场人数的设置仅在选择自动生成模式时有效。
  275. </p>
  276. </div>
  277. <div class="form-group">
  278. <label for="type" class="col-sm-2 astrisk control-label">准考证生成方式:</label>
  279. <div class="col-sm-8">
  280. <label class="radio-inline">
  281. <input type="radio" name="reexamine[type]" value="0" data-ref="reexamine" class="minimal type" checked="" style="position: absolute; opacity: 0;">&nbsp;不需要准考证&nbsp;&nbsp;
  282. </label>
  283. <label class="radio-inline">
  284. <input type="radio" name="reexamine[type]" value="1" data-ref="reexamine" class="minimal type" style="position: absolute; opacity: 0;">&nbsp;自动生成&nbsp;&nbsp;
  285. </label>
  286. <label class="radio-inline">
  287. <input type="radio" name="reexamine[type]" value="2" data-ref="reexamine" class="minimal type" style="position: absolute; opacity: 0;">&nbsp;模板上传&nbsp;&nbsp;
  288. </label>
  289. </div>
  290. </div>
  291. <div class="form-group ">
  292. <label for="apply_start" class="col-sm-2 astrisk control-label">打印时间段</label>
  293. <div class="col-sm-8">
  294. <div class="row" style="width: 470px">
  295. <div class="col-lg-6">
  296. <div class="input-group">
  297. <span class="input-group-addon"><i class="fa fa-calendar"></i></span>
  298. <input type="text" name="reexamine[ex_start]" value="" class="form-control ex_start" style="width: 200px"></div>
  299. </div>
  300. <div class="col-lg-6">
  301. <div class="input-group">
  302. <span class="input-group-addon"><i class="fa fa-calendar"></i></span>
  303. <input type="text" name="reexamine[ex_end]" value="" class="form-control ex_end" style="width: 200px"></div>
  304. </div>
  305. </div>
  306. </div>
  307. </div>
  308. <div id="reexamine_autoCreate" style="display: none">
  309. <div class="form-group">
  310. <label for="auto_each_number" class="col-sm-2 control-label">每间考场人数</label>
  311. <div class="col-sm-5">
  312. <div class="input-group">
  313. <span class="input-group-addon"><i class="fa fa-pencil fa-fw"></i></span>
  314. <input type="text" id="auto_each_number" name="reexamine[auto_each_number]" value="35" class="form-control auto_each_number" placeholder="输入每间考场人数">
  315. </div>
  316. </div>
  317. </div>
  318. </div>
  319. <div id="reexamine_fetchCreate" style="display: none">
  320. <div class="form-group ">
  321. <label for="test" class="col-sm-2 control-label">准考证数据</label>
  322. <div class="col-sm-8">
  323. <div class="file-input file-input-new">
  324. <input type="file" name="reexamine[data]" />
  325. </div>
  326. </div>
  327. </div>
  328. </div>
  329. @endif
  330. @endif
  331. @endif
  332. </div>
  333. @endif
  334. </div>
  335. </div>
  336. </div>
  337. </form>
  338. <link rel="stylesheet" href="/vendor/laravel-admin/AdminLTE/plugins/iCheck/all.css">
  339. <link rel="stylesheet" href="/vendor/laravel-admin/bootstrap-fileinput/css/fileinput.min.css">
  340. <script src="/vendor/laravel-admin/AdminLTE/plugins/iCheck/icheck.min.js"></script>
  341. <script src="/vendor/laravel-admin/bootstrap-fileinput/js/plugins/canvas-to-blob.min.js"></script>
  342. <script src="/vendor/laravel-admin/bootstrap-fileinput/js/fileinput.min.js"></script>
  343. <style>
  344. p{
  345. text-indent: 20px;
  346. }
  347. .notice{
  348. text-align: center;
  349. line-height: 80px;
  350. color: #404446;
  351. font-size: 22px;
  352. }
  353. </style>
  354. <script>
  355. $(function(){
  356. $(".nav-tabs li").click(function(){
  357. $("#ticket_type").val($(this).attr("data-ticketType"));
  358. })
  359. $(".nav-tabs").find('li:first-child').addClass('active');
  360. $(".tab-content").find('div:first-child').addClass('active');
  361. $('.type').iCheck({radioClass:'iradio_minimal-blue'});
  362. $('.type').on('ifChecked',function(e){
  363. var type = $(this).data('ref');
  364. if($(this).val() == 1){
  365. $("#"+ type +"_autoCreate").css('display','block');
  366. $("#"+ type +"_fetchCreate").css('display','none');
  367. }else if($(this).val() == 2){
  368. $("#"+ type +"_autoCreate").css('display','none');
  369. $("#"+ type +"_fetchCreate").css('display','block');
  370. } else if($(this).val() == 0) {
  371. $("#"+ type +"_autoCreate").css('display','none');
  372. $("#"+ type +"_fetchCreate").css('display','none');
  373. }
  374. });
  375. $('.ex_start').datetimepicker({"format":"YYYY-MM-DD HH:mm:ss","locale":"zh-CN"});
  376. $('.ex_end').datetimepicker({"format":"YYYY-MM-DD HH:mm:ss","locale":"zh-CN","useCurrent":false});
  377. $(".ex_start").on("dp.change", function (e) {
  378. $('.ex_end').data("DateTimePicker").minDate(e.date);
  379. });
  380. $(".ex_end").on("dp.change", function (e) {
  381. $('.ex_start').data("DateTimePicker").maxDate(e.date);
  382. });
  383. });
  384. </script>