info_modal.ejs 36 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612
  1. <% if (auditStatus === 1 || auditStatus === 2) { %>
  2. <!--变更单位-->
  3. <div class="modal fade" id="editcompany" tabindex="-1" role="dialog" aria-labelledby="myModalLabel">
  4. <div class="modal-dialog" role="document">
  5. <div class="modal-content">
  6. <div class="modal-header">
  7. <h5 class="modal-title" id="myModalLabel">变更单位</h5>
  8. <button type="button" class="close" data-dismiss="modal" aria-label="Close">
  9. <span aria-hidden="true">&times;</span>
  10. </button>
  11. </div>
  12. <div class="modal-body">
  13. <div id="companyshow">
  14. <% for (const company of companyList) { %>
  15. <div class="form-group">
  16. <input type="text" id="<%= company.id %>" class="form-control" value="<%= company.name %>">
  17. </div>
  18. <% } %>
  19. </div>
  20. <div class="alert alert-warning" role="alert">修改后,已创建的变更不受影响。</div>
  21. <p><button class="btn btn-primary btn-sm" id="addcompany" role="button" title="填写公司"><b class="fa fa-plus"></b></button></p>
  22. <div id="companyadddiv">
  23. <!--<input type="text" class="form-control" placeholder="请输入公司名称">-->
  24. </div>
  25. </div>
  26. <div class="modal-footer">
  27. <button type="button" class="btn btn-secondary" data-dismiss="modal">取消</button>
  28. <button type="button" id="updatecompany" class="btn btn-primary">确定</button>
  29. </div>
  30. </div>
  31. </div>
  32. </div>
  33. <!--上报审批-->
  34. <div class="modal fade" id="sub-ap" data-backdrop="static">
  35. <div class="modal-dialog" role="document">
  36. <div class="modal-content">
  37. <div class="modal-header">
  38. <h5 class="modal-title up-change">上报审批</h5>
  39. <h5 class="modal-title save-change">保存修改</h5>
  40. </div>
  41. <form method="post" action="/tender/<%- tender.id %>/change/<%- change.cid %>/save">
  42. <div class="modal-body">
  43. <div class="form-group">
  44. <label>选择审批人</label>
  45. <div class="input-group">
  46. <div class="input-group-prepend">
  47. <select class="form-control" id="account_group">
  48. <option value="0">所有分组</option>
  49. <% for (const dw in accountGroup) { %>
  50. <option value="<%= dw %>"><%= accountGroup[dw] %></option>
  51. <% } %>
  52. </select>
  53. </div>
  54. <select class="form-control" id="account_list">
  55. <option value="0">选择审批人</option>
  56. <% for (const account of accountList) { %>
  57. <option value="<%= account.id %>"><%= account.name %><% if (account.role !== '') { %>(<%= account.role %>)<% } %><% if (account.company !== '') { %> -<%= account.company %><% } %></option>
  58. <% } %>
  59. </select>
  60. </div>
  61. </div>
  62. <div id="search_audit_list">
  63. </div>
  64. <div class="card mt-3">
  65. <div class="card-header">
  66. 审批流程
  67. </div>
  68. <ul class="list-group list-group-flush" id="auditList">
  69. <% for (const [index, audit] of auditList.entries()) { %>
  70. <% if (audit.usite !== 0) { %>
  71. <li class="list-group-item" data-auditmsg="<%= audit.uid + '/%/' + audit.name + '/%/' + audit.jobs + '/%/' + audit.company %>"
  72. data-auditid="<%= audit.uid %>">
  73. <a href="javascript:void(0)" class="text-danger pull-right remove_audit_btn">移除</a>
  74. <span><%= index %></span> <%= audit.name %> <small class="text-muted"><%= audit.jobs %></small>
  75. <p class="m-0 ml-2"><small class="text-muted"><%= audit.company %></small></p>
  76. </li>
  77. <% } %>
  78. <% } %>
  79. </ul>
  80. <input type="hidden" id="auditIdList" value="">
  81. </div>
  82. </div>
  83. <div class="modal-footer">
  84. <button type="button" class="btn btn-secondary" data-dismiss="modal">关闭</button>
  85. <button type="button" data-sumbit="sumbit_change" data-category="up_change" class="btn btn-primary up-change">确认上报</button>
  86. <button type="button" data-sumbit="sumbit_change" data-category="save_change" class="btn btn-success save-change">保存修改</button>
  87. </div>
  88. </form>
  89. </div>
  90. </div>
  91. </div>
  92. <script src="/public/js/change_company.js"></script>
  93. <!--添加清单-->
  94. <div class="modal fade " tabindex="-1" role="dialog" aria-hidden="true" id="addlist">
  95. <style>
  96. /* 设置滚动条的样式 */
  97. .fixed_headers ::-webkit-scrollbar, .fixed_headers2 ::-webkit-scrollbar {
  98. width:5px;
  99. }
  100. .fixed_headers thead tr, .fixed_headers2 thead tr {
  101. display: block;
  102. position: relative;
  103. overflow-y: scroll;
  104. }
  105. .fixed_headers tbody, .fixed_headers2 tbody {
  106. display: block;
  107. overflow-y: scroll;
  108. height: 369px;
  109. }
  110. .fixed_headers td:nth-child(1),
  111. .fixed_headers th:nth-child(1) {
  112. width: 6%;
  113. min-width: 40px;
  114. text-overflow:ellipsis;
  115. white-space:nowrap;
  116. overflow:hidden;
  117. }
  118. .fixed_headers td:nth-child(2),
  119. .fixed_headers th:nth-child(2) {
  120. width: 20%;
  121. min-width: 133px;
  122. }
  123. .fixed_headers td:nth-child(3),
  124. .fixed_headers th:nth-child(3) {
  125. width: 37%;
  126. min-width: 247px;
  127. }
  128. .fixed_headers td:nth-child(4),
  129. .fixed_headers th:nth-child(4) {
  130. width: 10%;
  131. min-width: 66px;
  132. }
  133. .fixed_headers td:nth-child(5),
  134. .fixed_headers th:nth-child(5) {
  135. width: 13%;
  136. min-width: 86px;
  137. }
  138. .fixed_headers td:nth-child(6),
  139. .fixed_headers th:nth-child(6) {
  140. width: 13%;
  141. min-width: 87px;
  142. }
  143. .fixed_headers2 td:nth-child(1),
  144. .fixed_headers2 th:nth-child(1) {
  145. width: 18%;
  146. min-width: 100px;
  147. text-overflow:ellipsis;
  148. white-space:nowrap;
  149. overflow:hidden;
  150. }
  151. .fixed_headers2 td:nth-child(2),
  152. .fixed_headers2 th:nth-child(2) {
  153. width: 23%;
  154. min-width: 113px;
  155. }
  156. .fixed_headers2 td:nth-child(3),
  157. .fixed_headers2 th:nth-child(3) {
  158. width: 25%;
  159. min-width: 124px;
  160. }
  161. .fixed_headers2 td:nth-child(4),
  162. .fixed_headers2 th:nth-child(4) {
  163. width: 16%;
  164. min-width: 82px;
  165. }
  166. .fixed_headers2 td:nth-child(5),
  167. .fixed_headers2 th:nth-child(5) {
  168. width: 8%;
  169. min-width: 41px;
  170. }
  171. .fixed_headers2 .colspan_1 {
  172. width: 95%!important;
  173. }
  174. .fixed_headers2 .colspan_2 {
  175. width: 5%!important;
  176. min-width: 41px!important;
  177. }
  178. </style>
  179. <div class="modal-dialog modal-xl">
  180. <div class="modal-content">
  181. <div class="modal-header">
  182. <h5 class="modal-title" id="mySmallModalLabel">从清单中选择</h5>
  183. <button type="button" class="close" data-dismiss="modal" aria-label="Close">
  184. <span aria-hidden="true">&times;</span>
  185. </button>
  186. </div>
  187. <div class="modal-body">
  188. <div class="row">
  189. <div class="col-7">
  190. <div style="height:400px;overflow-y:hidden">
  191. <table class="table table-striped table-bordered table-hover table-sm fixed_headers">
  192. <thead><tr><th>序号</th><th>清单编号</th><th>名称</th><th>单位</th><th>单价</th><th>数量</th></tr></thead>
  193. <tbody id="table-list-select">
  194. </tbody>
  195. </table>
  196. </div>
  197. </div>
  198. <div class="col-5">
  199. <div style="height:400px;overflow-y:hidden">
  200. <table class="table table-striped table-bordered table-hover table-sm fixed_headers2">
  201. <thead>
  202. <tr><th>项目节编号</th><th>名称</th><th>部位明细</th><th>部位数量</th><th>选择</th></tr>
  203. </thead>
  204. <tbody id="code-list" data-index="">
  205. </tbody>
  206. </table>
  207. </div>
  208. </div>
  209. </div>
  210. </div>
  211. <div class="modal-footer">
  212. <!--<button type="button" class="add-list-btn btn btn-outline-primary">添加空白清单</button>-->
  213. <button type="button" class="btn btn-secondary" data-dismiss="modal" id="cancel-list-btn">取消</button>
  214. <button type="button" class="add-list-btn btn btn-primary">添加</button>
  215. </div>
  216. </div>
  217. </div>
  218. </div>
  219. <% if (auditStatus === 2) { %>
  220. <!--重新上报-->
  221. <div class="modal fade" id="sub-sp2" data-backdrop="static">
  222. <div class="modal-dialog modal-lg" role="document">
  223. <div class="modal-content">
  224. <div class="modal-header">
  225. <h5 class="modal-title">重新上报</h5>
  226. </div>
  227. <div class="modal-body">
  228. <div class="row">
  229. <div class="col-4">
  230. <a href="#sub-ap" data-toggle="modal" data-category="" data-target="#sub-ap" id="hideSp">修改审批流程</a>
  231. <div class="card mt-3">
  232. <ul class="list-group list-group-flush">
  233. <% for (const audit of auditList) { %>
  234. <% if (audit.usite === 0) { %>
  235. <li class="list-group-item">
  236. <i class="fa fa-play-circle fa-rotate-90"></i>
  237. <%= audit.name %> <small class="text-muted"><%= audit.jobs %></small>
  238. </li>
  239. <% } %>
  240. <% } %>
  241. </ul>
  242. <ul class="list-group list-group-flush" id="shenpi-audit-list">
  243. <% for (const [index,a] of auditList.entries()) { %>
  244. <% if (a.usite !== 0 ) { %>
  245. <li class="list-group-item" data-auditid="<%= a.uid %>">
  246. <% if (index+1 !== auditList.length) { %>
  247. <i class="fa fa-chevron-circle-down"></i>
  248. <% } else if (index+1 === auditList.length) { %>
  249. <i class="fa fa-stop-circle"></i>
  250. <% } %>
  251. <%= a.name %> <small class="text-muted"><%= a.jobs %></small>
  252. </li>
  253. <% }%>
  254. <% } %>
  255. </ul>
  256. </div>
  257. </div>
  258. <div class="col-8 modal-height-500" style="overflow: auto">
  259. <% for (const time in auditList3) { %>
  260. <% if (auditList3[time].length > 0) { %>
  261. <div class="card mt-3">
  262. <ul class="list-group list-group-flush">
  263. <% for (const [aindex,al] of auditList3[time].entries()) { %>
  264. <li class="list-group-item">
  265. <% if (al.usite === 0 && al.status === 2) { %>
  266. <span class="pull-right">重新上报中</span>
  267. <% } else if (al.usite === 0 && al.status === 3) { %>
  268. <span class="text-success pull-right">上报</span>
  269. <% } else if (al.usite !== 0 && al.status === 2) { %>
  270. <span class="pull-right">审批中</span>
  271. <% } else if (al.usite !== 0 && al.status === 3) { %>
  272. <span class="text-success pull-right">审批通过</span>
  273. <% } else if (al.usite !== 0 && al.status === 4) { %>
  274. <span class="text-danger pull-right">审批终止</span>
  275. <% } else if (al.usite !== 0 && (al.status === 5 || al.status === 6)) { %>
  276. <span class="text-warning pull-right">审批退回 </span>
  277. <% } %>
  278. <h5 class="card-title">
  279. <% if (al.usite === 0 && al.status === 2 ) { %>
  280. <i class="fa fa-play-circle fa-rotate-90"></i>
  281. <% } else if (al.usite === 0 && al.status === 3 ) { %>
  282. <i class="fa fa-play-circle fa-rotate-90 text-success"></i>
  283. <% } else if (al.status === 1 || al.status === 2) { %>
  284. <i class="fa <% if (aindex+1 === auditList3[time].length) { %>fa-stop-circle<% } else { %>fa-chevron-circle-down<% } %> "></i>
  285. <% } else if (al.status === 3) { %>
  286. <i class="fa <% if (aindex+1 === auditList3[time].length) { %>fa-stop-circle<% } else { %>fa-chevron-circle-down<% } %> text-success"></i>
  287. <% } else if (al.status === 4) { %>
  288. <i class="fa <% if (aindex+1 === auditList3[time].length) { %>fa-stop-circle<% } else { %>fa-chevron-circle-down<% } %> text-danger"></i>
  289. <% } else if (al.status === 5 || al.status === 6) { %>
  290. <i class="fa <% if (aindex+1 === auditList3[time].length) { %>fa-stop-circle<% } else { %>fa-chevron-circle-down<% } %> text-warning"></i>
  291. <% } %>
  292. <%= al.name %>&nbsp;<small class="text-muted"><%= al.jobs %></small>
  293. </h5>
  294. <% if (al.sdesc !== '' && al.sdesc !== null) { %>
  295. <p class="card-text mb-1"><%= al.sdesc %></p>
  296. <% } %>
  297. <% if (al.sin_time !== null) { %>
  298. <p class="card-text"><small class="text-muted"><%= moment(al.sin_time).format('YYYY-MM-DD') %></small></p>
  299. <% } %>
  300. </li>
  301. <% } %>
  302. </ul>
  303. </div>
  304. <% } %>
  305. <% } %>
  306. </div>
  307. </div>
  308. </div>
  309. <div class="modal-footer">
  310. <button type="button" class="btn btn-secondary" data-dismiss="modal">关闭</button>
  311. <button type="button" data-sumbit="sumbit_change" data-category="up_change" class="btn btn-primary up-change">确认上报</button>
  312. <button type="button" data-sumbit="sumbit_change" data-category="save_change" class="btn btn-success save-change">保存修改</button>
  313. </div>
  314. </div>
  315. </div>
  316. </div>
  317. <% } %>
  318. <% } %>
  319. <% if (auditStatus === 3 || auditStatus === 4 || auditStatus === 5 || auditStatus === 7) { %>
  320. <!--审批流程/结果-->
  321. <div class="modal fade" id="sp-list" data-backdrop="static">
  322. <div class="modal-dialog modal-lg" role="document">
  323. <div class="modal-content">
  324. <div class="modal-header">
  325. <h5 class="modal-title">审批流程</h5>
  326. </div>
  327. <div class="modal-body">
  328. <div class="row">
  329. <div class="col-4">
  330. <div class="card mt-3">
  331. <ul class="list-group list-group-flush">
  332. <% for (const [index,a] of auditList2.entries()) { %>
  333. <li class="list-group-item">
  334. <% if (a.usite === 0 ) { %>
  335. <i class="fa fa-play-circle fa-rotate-90"></i>
  336. <% } else if (index+1 !== auditList2.length) { %>
  337. <i class="fa fa-chevron-circle-down"></i>
  338. <% } else if (index+1 === auditList2.length) { %>
  339. <i class="fa fa-stop-circle"></i>
  340. <% } %>
  341. <%= a.name %> <small class="text-muted"><%= a.jobs %></small>
  342. </li>
  343. <% } %>
  344. </ul>
  345. </div>
  346. </div>
  347. <div class="col-8 modal-height-500" style="overflow: auto">
  348. <% for (const time in auditList3) { %>
  349. <div class="card mt-3">
  350. <ul class="list-group list-group-flush">
  351. <% for (const [aindex,al] of auditList3[time].entries()) { %>
  352. <li class="list-group-item">
  353. <% if (al.usite === 0 && al.status === 2) { %>
  354. <span class="pull-right">重新上报中</span>
  355. <% } else if (al.usite === 0 && al.status === 3 && al.times === 1) { %>
  356. <span class="text-success pull-right">上报</span>
  357. <% } else if (al.usite === 0 && al.status === 3 && al.times !== 1) { %>
  358. <span class="text-success pull-right">重新上报</span>
  359. <% } else if (al.usite !== 0 && al.status === 2) { %>
  360. <span class="pull-right">审批中</span>
  361. <% } else if (al.usite !== 0 && al.status === 3) { %>
  362. <span class="text-success pull-right">审批通过</span>
  363. <% } else if (al.usite !== 0 && al.status === 4) { %>
  364. <span class="text-danger pull-right">审批终止</span>
  365. <% } else if (al.usite !== 0 && (al.status === 5 || al.status === 6)) { %>
  366. <span class="text-warning pull-right">审批退回 <% if (al.status === 5) {%><%= auditList3[time][0].name %><% } %></span>
  367. <% } else if (al.usite !== 0 && al.status === 7) { %>
  368. <span class="text-warning pull-right">重新审批</span>
  369. <% } %>
  370. <h5 class="card-title">
  371. <% if (al.usite === 0 && al.status === 2 ) { %>
  372. <i class="fa fa-play-circle fa-rotate-90"></i>
  373. <% } else if (al.usite === 0 && al.status === 3 ) { %>
  374. <i class="fa fa-play-circle fa-rotate-90 text-success"></i>
  375. <% } else if (al.status === 1 || al.status === 2) { %>
  376. <i class="fa <% if (aindex+1 === auditList3[time].length) { %>fa-stop-circle<% } else { %>fa-chevron-circle-down<% } %> "></i>
  377. <% } else if (al.status === 3) { %>
  378. <i class="fa <% if (aindex+1 === auditList3[time].length) { %>fa-stop-circle<% } else { %>fa-chevron-circle-down<% } %> text-success"></i>
  379. <% } else if (al.status === 4) { %>
  380. <i class="fa <% if (aindex+1 === auditList3[time].length) { %>fa-stop-circle<% } else { %>fa-chevron-circle-down<% } %> text-danger"></i>
  381. <% } else if (al.status === 5 || al.status === 6) { %>
  382. <i class="fa <% if (aindex+1 === auditList3[time].length) { %>fa-stop-circle<% } else { %>fa-chevron-circle-down<% } %> text-warning"></i>
  383. <% } else if (al.status === 7) { %>
  384. <i class="fa fa-chevron-circle-down text-warning"></i>
  385. <% } %>
  386. <%= al.name %>&nbsp;<small class="text-muted"><%= al.jobs %></small>
  387. </h5>
  388. <% if (al.sdesc !== '' && al.sdesc !== null) { %>
  389. <p class="card-text mb-1"><%= al.sdesc %></p>
  390. <% } %>
  391. <% if (al.sin_time !== null) { %>
  392. <p class="card-text"><small class="text-muted"><%= moment(al.sin_time).format('YYYY-MM-DD') %></small></p>
  393. <% } %>
  394. </li>
  395. <% } %>
  396. </ul>
  397. </div>
  398. <% } %>
  399. </div>
  400. </div>
  401. </div>
  402. <div class="modal-footer">
  403. <button type="button" class="btn btn-secondary" data-dismiss="modal">关闭</button>
  404. </div>
  405. </div>
  406. </div>
  407. </div>
  408. <% } %>
  409. <% if (auditStatus === 6) { %>
  410. <!--审批通过-->
  411. <div class="modal fade" id="sp-done" data-backdrop="static">
  412. <div class="modal-dialog" role="document">
  413. <div class="modal-content">
  414. <div class="modal-header">
  415. <h5 class="modal-title">审批通过</h5>
  416. </div>
  417. <form action="/change/approval?_csrf=<%= ctx.csrf %>" method="post" id="success-approval">
  418. <div class="modal-body">
  419. <div class="card mt-3">
  420. <ul class="list-group list-group-flush">
  421. <% for (const [index,a] of auditList.entries()) { %>
  422. <li class="list-group-item">
  423. <% if (a.status === 3 && a.usort === 0 && a.times === 1) { %>
  424. <span class="text-success pull-right">上报</span>
  425. <% } else if (a.status === 3 && a.usort === 0 && a.times !== 1) { %>
  426. <span class="text-success pull-right">重新上报</span>
  427. <% } else if (a.status === 3 && a.usort !== 0) { %>
  428. <span class="text-success pull-right">审批通过</span>
  429. <% } else if (a.status === 2) { %>
  430. <span class="pull-right">审批中</span>
  431. <% } %>
  432. <h5 class="card-title">
  433. <% if (a.usort === 0) { %>
  434. <i class="fa fa-play-circle fa-rotate-90 <% if (a.status === 3) { %>text-success<% } %>"></i>
  435. <% } else if (a.usort !== 0 && index+1 !== auditList.length) { %>
  436. <i class="fa fa-chevron-circle-down <% if (a.status === 3) { %>text-success<% } %>"></i>
  437. <% } else if (a.usort !== 0 && index+1 === auditList.length) { %>
  438. <i class="fa fa-stop-circle"></i>
  439. <% } %>
  440. <%= a.name %>&nbsp;<small class="text-muted"><%= a.jobs%></small>
  441. </h5>
  442. <% if (a.sdesc !== '' && a.sdesc !== null) { %>
  443. <p class="card-text mb-1"><%= a.sdesc %></p>
  444. <% } %>
  445. <% if (a.sin_time !== null) { %>
  446. <p class="card-text"><small class="text-muted"><%= moment(a.sin_time).format('YYYY-MM-DD') %></small></p>
  447. <% } %>
  448. <% if (a.status === 2) { %>
  449. <div class="form-group">
  450. <label>审批意见<b class="text-danger">*</b></label>
  451. <textarea class="form-control" name="sdesc">同意</textarea>
  452. <input type="hidden" name="audit_id" value="<%= a.id %>">
  453. <% if (a.usort !== 0 && index+1 === auditList.length) { %>
  454. <!--终审填写批复编号-->
  455. <div class="form-group mt-3">
  456. <label><b class="text-danger">*&nbsp;</b>变更令号(批复编号)</label>
  457. <input class="form-control" value="<%= change.code %>" name="p_code" type="text">
  458. </div>
  459. <% } else { %>
  460. <input type="hidden" name="audit_next_id" value="<%= auditList[index+1].id %>">
  461. <% } %>
  462. </div>
  463. <% } %>
  464. </li>
  465. <% } %>
  466. </ul>
  467. </div>
  468. </div>
  469. <div class="modal-footer">
  470. <input type="hidden" name="status" value="3">
  471. <input type="hidden" name="w_code" value="<%= change.w_code %>">
  472. <input type="hidden" name="change_id" value="<%= change.cid %>">
  473. <input type="hidden" name="bills_list" id="change-list-approval" value="">
  474. <button type="button" class="btn btn-secondary" data-dismiss="modal">关闭</button>
  475. <button type="button" class="btn btn-success approval-btn">确认通过</button>
  476. </div>
  477. </form>
  478. </div>
  479. </div>
  480. </div>
  481. <!--审批退回-->
  482. <div class="modal fade" id="sp-back" data-backdrop="static">
  483. <div class="modal-dialog" role="document">
  484. <div class="modal-content">
  485. <div class="modal-header">
  486. <h5 class="modal-title">审批退回</h5>
  487. </div>
  488. <form action="/change/approval?_csrf=<%= ctx.csrf %>" method="post" id="fail-approval">
  489. <div class="modal-body">
  490. <div class="card mt-3">
  491. <ul class="list-group list-group-flush">
  492. <% for (const [index,a] of auditList.entries()) { %>
  493. <li class="list-group-item">
  494. <% if (a.status === 3 && a.usort === 0 && a.times === 1) { %>
  495. <span class="text-success pull-right">上报</span>
  496. <% } else if (a.status === 3 && a.usort === 0 && a.times !== 1) { %>
  497. <span class="text-success pull-right">重新上报</span>
  498. <% } else if (a.status === 3 && a.usort !== 0) { %>
  499. <span class="text-success pull-right">审批通过</span>
  500. <% } else if (a.status === 2) { %>
  501. <span class="pull-right">审批中</span>
  502. <% } %>
  503. <h5 class="card-title">
  504. <% if (a.usort === 0) { %>
  505. <i class="fa fa-play-circle fa-rotate-90 <% if (a.status === 3) { %>text-success<% } %>"></i>
  506. <% } else if (a.usort !== 0 && index+1 !== auditList.length) { %>
  507. <i class="fa fa-chevron-circle-down <% if (a.status === 3) { %>text-success<% } %>"></i>
  508. <% } else if (a.usort !== 0 && index+1 === auditList.length) { %>
  509. <i class="fa fa-stop-circle"></i>
  510. <% } %>
  511. <%= a.name %>&nbsp;<small class="text-muted"><%= a.jobs%></small>
  512. </h5>
  513. <% if (a.sdesc !== '' && a.sdesc !== null) { %>
  514. <p class="card-text mb-1"><%= a.sdesc %></p>
  515. <% } %>
  516. <% if (a.sin_time !== null) { %>
  517. <p class="card-text"><small class="text-muted"><%= moment(a.sin_time).format('YYYY-MM-DD') %></small></p>
  518. <% } %>
  519. <% if (a.status === 2) { %>
  520. <div class="form-group">
  521. <label>审批意见<b class="text-danger">*</b></label>
  522. <textarea class="form-control" name="sdesc">不同意</textarea>
  523. <input type="hidden" name="audit_id" value="<%= a.id %>">
  524. </div>
  525. <div class="alert alert-warning">
  526. <div class="form-check form-check-inline">
  527. <input class="form-check-input" type="radio" name="status" id="change-back" value="5" <% if (index === 1) { %>checked<% } %>>
  528. <label class="form-check-label" for="change-back">退回上报 <%= auditList[0].name %></label>
  529. </div>
  530. <% if (index !== 1) { %>
  531. <div class="form-check form-check-inline">
  532. <input class="form-check-input" type="radio" name="status" id="chagne-backnew" value="6" <% if (index !== 1) { %>checked<% } %>>
  533. <label class="form-check-label" for="chagne-backnew">退回上一审批人 <%= auditList[index-1].name %></label>
  534. <input type="hidden" name="audit_last_id" value="<%= auditList[index-1].id %>">
  535. </div>
  536. <% } %>
  537. <!--<div class="form-check form-check-inline">-->
  538. <!--<input class="form-check-input" type="radio" name="status" id="change-stop" value="4">-->
  539. <!--<label class="form-check-label" for="change-stop">终止</label>-->
  540. <!--</div>-->
  541. </div>
  542. <div class="alert alert-danger change-approval-stop" style="display: none">
  543. 审批终止,将结束本次审批,本条变更令作废。
  544. </div>
  545. <% } %>
  546. </li>
  547. <% } %>
  548. </ul>
  549. </div>
  550. </div>
  551. <div class="modal-footer">
  552. <input type="hidden" name="w_code" value="<%= change.w_code %>">
  553. <input type="hidden" name="change_id" value="<%= change.cid %>">
  554. <button type="button" class="btn btn-secondary" data-dismiss="modal">关闭</button>
  555. <button type="button" class="btn btn-warning change-approval-back approval-btn">确认退回</button>
  556. <button type="button" class="btn btn-danger change-approval-stop approval-btn" style="display: none">确认终止</button>
  557. </div>
  558. </form>
  559. </div>
  560. </div>
  561. </div>
  562. <% } %>
  563. <!--添加附件-->
  564. <div class="modal fade" tabindex="-1" role="dialog" aria-hidden="true" id="addfujian">
  565. <div class="modal-dialog" role="document">
  566. <div class="modal-content">
  567. <div class="modal-header">
  568. <h5 class="modal-title" id="myModalLabel">上传附件</h5>
  569. <button type="button" class="close" data-dismiss="modal" aria-label="Close">
  570. <span aria-hidden="true">&times;</span>
  571. </button>
  572. </div>
  573. <div class="modal-body">
  574. <p>大小限制:30MB,支持office等文档格式、图片格式、压缩包格式</p>
  575. <p><input class="btn btn-primary" value="选择文件" type="file" id="upload-file" multiple /></p>
  576. </div>
  577. <div class="modal-footer">
  578. <button type="button" class="btn btn-secondary" data-dismiss="modal">取消</button>
  579. <button type="button" class="btn btn-primary" id="upload-file-btn">添加</button>
  580. </div>
  581. </div>
  582. </div>
  583. </div>
  584. <% if (auditStatus === 4 && ctx.session.sessionUser.accountId === auditList[auditList.length-1].uid && stageChangeNum === 0) { %>
  585. <!--重新审批-->
  586. <div class="modal fade" id="sp-down-back" data-backdrop="static">
  587. <div class="modal-dialog" role="document">
  588. <form class="modal-content" method="post" action="/change/check/again">
  589. <div class="modal-header">
  590. <h5 class="modal-title">重新审批</h5>
  591. </div>
  592. <div class="modal-body">
  593. <h5>确认由「终审-<%= auditList[auditList.length-1].name %>」重新审批「<%= change.code %>」?</h5>
  594. </div>
  595. <div class="modal-footer">
  596. <input type="hidden" name="cid" value="<%= change.cid %>">
  597. <input type="hidden" name="_csrf" value="<%= ctx.csrf %>" />
  598. <button type="button" class="btn btn-secondary" data-dismiss="modal">关闭</button>
  599. <button type="submit" class="btn btn-warning">确定重审</button>
  600. </div>
  601. </form>
  602. </div>
  603. </div>
  604. <% } %>