tender.ejs 26 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8">
  5. <meta name="viewport" content="initial-scale=1, maximum-scale=1,user-scalable=no">
  6. <meta http-equiv="x-ua-compatible" content="ie=edge">
  7. <title>标段概况-计量支付</title>
  8. <link rel="stylesheet" href="/public/css/bootstrap/bootstrap.min.css">
  9. <link rel="stylesheet" href="/public/css/wap/main.css">
  10. <link rel="stylesheet" href="/public/css/toast.css">
  11. <link rel="stylesheet" href="/public/css/font-awesome/font-awesome.min.css">
  12. <script src=/public/js/echarts/echarts.min.js></script>
  13. <link rel="shortcut icon" href="/public/images/favicon.ico">
  14. <style>
  15. body {
  16. padding: 0;
  17. }
  18. </style>
  19. </head>
  20. <body>
  21. <div class="container">
  22. <!--顶部-->
  23. <nav class="fixed-top bg-dark">
  24. <div class="my-2 d-flex justify-content-between">
  25. <span class="text-white ml-3"><a href="/wap/list" class="mr-2 text-white"><i class="fa fa-chevron-left"></i></a>标段概况</span>
  26. <div class="mr-3">
  27. <div class="dropdown">
  28. <button class="btn btn-sm btn-light dropdown-toggle" type="button" data-toggle="dropdown">
  29. <%- ctx.session.sessionUser.name.substr(ctx.session.sessionUser.name.length > 2 ? ctx.session.sessionUser.name.length - 2 : 0) %>
  30. </button>
  31. <div class="dropdown-menu" aria-labelledby="dropdownMenuButton">
  32. <a class="dropdown-item" href="/wap/logout">退出登录</a>
  33. </div>
  34. </div>
  35. </div>
  36. </div>
  37. </nav>
  38. <!--标段概况-->
  39. <div class="py-6">
  40. <!--标签-->
  41. <ul class="nav nav-tabs nav-fill">
  42. <li class="nav-item">
  43. <a class="nav-link active" data-toggle="tab" href="#gaikuang" role="tab">概况</a>
  44. </li>
  45. <li class="nav-item">
  46. <a class="nav-link" data-toggle="tab" href="#jlqi" role="tab">计量期</a>
  47. </li>
  48. <li class="nav-item">
  49. <a class="nav-link" data-toggle="tab" href="#shenpi" role="tab">期审批</a>
  50. </li>
  51. </ul>
  52. <div class="tab-content">
  53. <div class="tab-pane active" id="gaikuang">
  54. <!--图表-->
  55. <div class="card mb-3 mr-1 mt-3">
  56. <div class="card-body">
  57. <h5 class="card-title">月进度表</h5>
  58. <div id="chartContainer3" style="height: 300px; width: 100%;">
  59. </div>
  60. </div>
  61. </div>
  62. <div class="card mb-3 mr-1">
  63. <div class="card-body">
  64. <h5 class="card-title">期进度表</h5>
  65. <div id="chartContainer4" style="height: 300px; width: 100%;">
  66. </div>
  67. </div>
  68. </div>
  69. </div>
  70. <div class="tab-pane" id="jlqi">
  71. <!--期列表-->
  72. <dl class="mb-2 mt-3">
  73. <% for (const s of stages) { %>
  74. <dt class="bg-light p-2 d-flex justify-content-between"><span>第<%- s.order %>期</span>
  75. <span class="<%- auditConst.auditStringClass[s.status] %>">
  76. <% if (s.curAuditor && s.status !== auditConst.status.checked) { %>
  77. <%- s.curAuditor.name %><%if (s.curAuditor.role !== '' && s.curAuditor.role !== null) { %>-<%- s.curAuditor.role %><% } %>
  78. <% } %>
  79. <%- s.status === auditConst.status.checked ? '审批完成' : auditConst.auditProgress[s.status] %>
  80. </span>
  81. </dt>
  82. <dd>
  83. <table class="table table-hover">
  84. <tbody><tr>
  85. <td>
  86. <p class="mb-0">本期合同计量</p>
  87. <b>¥<%- ctx.helper.formatMoney((s.contract_tp ? s.contract_tp : 0)) %></b>
  88. </td>
  89. <td>
  90. <p class="mb-0">本期数量变更计量</p>
  91. <b>¥<%- ctx.helper.formatMoney((s.qc_tp ? s.qc_tp : 0)) %></b>
  92. </td>
  93. </tr>
  94. <tr>
  95. <td>
  96. <p class="mb-0">本期完成计量</p>
  97. <b>¥<%- ctx.helper.formatMoney((s.tp ? s.tp : 0)) %></b>
  98. </td>
  99. <td>
  100. <p class="mb-0">截止上期完成计量</p>
  101. <b>¥<%- ctx.helper.formatMoney((s.pre_tp ? s.pre_tp : 0)) %></b>
  102. </td>
  103. </tr>
  104. <tr>
  105. <td>
  106. <p class="mb-0">截止本期完成计量</p>
  107. <b>¥<%- ctx.helper.formatMoney((s.end_tp ? s.end_tp : 0)) %></b>
  108. </td>
  109. <td>
  110. <p class="mb-0">本期应付</p>
  111. <b>¥<%- ctx.helper.formatMoney((s.yf_tp ? s.yf_tp : 0)) %></b>
  112. </td>
  113. </tr>
  114. </tbody></table>
  115. </dd>
  116. <% } %>
  117. </dl>
  118. </div>
  119. <div class="tab-pane" id="shenpi">
  120. <!--最新期-->
  121. <% let audit = 0; %>
  122. <% if (stages.length > 0 && stage) { %>
  123. <dl class="mb-2 mt-3">
  124. <dt class="bg-light p-2 d-flex justify-content-between"><span>第<%- stage.order %>期</span>
  125. <span class="<%- auditConst.auditStringClass[stage.status] %>">
  126. <% if (stage.curAuditor && stage.status !== auditConst.status.checked) { %>
  127. <%- stage.curAuditor.name %><%if (stage.curAuditor.role !== '' && stage.curAuditor.role !== null) { %>-<%- stage.curAuditor.role %><% } %>
  128. <% } %>
  129. <%- stage.status === auditConst.status.checked ? '审批完成' : auditConst.auditProgress[stage.status] %>
  130. </span>
  131. </dt>
  132. <dd>
  133. <table class="table table-hover">
  134. <tbody><tr>
  135. <td>
  136. <p class="mb-0">本期合同计量</p>
  137. <b>¥<%- ctx.helper.formatMoney((stage.contract_tp ? stage.contract_tp : 0)) %></b>
  138. </td>
  139. <td>
  140. <p class="mb-0">本期数量变更计量</p>
  141. <b>¥<%- ctx.helper.formatMoney((stage.qc_tp ? stage.qc_tp : 0)) %></b>
  142. </td>
  143. </tr>
  144. <tr>
  145. <td>
  146. <p class="mb-0">本期完成计量</p>
  147. <b>¥<%- ctx.helper.formatMoney((stage.tp ? stage.tp : 0)) %></b>
  148. </td>
  149. <td>
  150. <p class="mb-0">截止上期完成计量</p>
  151. <b>¥<%- ctx.helper.formatMoney((stage.pre_tp ? stage.pre_tp : 0)) %></b>
  152. </td>
  153. </tr>
  154. <tr>
  155. <td>
  156. <p class="mb-0">截止本期完成计量</p>
  157. <b>¥<%- ctx.helper.formatMoney((stage.end_tp ? stage.end_tp : 0)) %></b>
  158. </td>
  159. <td>
  160. <p class="mb-0">本期应付</p>
  161. <b>¥<%- ctx.helper.formatMoney((stage.yf_tp ? stage.yf_tp : 0)) %></b>
  162. </td>
  163. </tr>
  164. </tbody></table>
  165. </dd>
  166. </dl>
  167. <!--审批流程-->
  168. <div class="card mt-3">
  169. <ul class="list-group list-group-flush">
  170. <li class="list-group-item">
  171. <% if (stage.status === auditConst.status.uncheck) { %>
  172. <span class="pull-right"> 上报中</span>
  173. <% } else { %>
  174. <span class="text-success pull-right"><small><%- stage.auditors[0].begin_time.toLocaleDateString() %></small> 上报</span>
  175. <% } %>
  176. <h5 class="card-title"><i class="fa fa-play-circle fa-rotate-90 text-success"></i> <%- stage.user.name %><small class="text-muted"><%- stage.user.role %></small></h5>
  177. </li>
  178. <% for (let iA = 0; iA < stage.auditors.length; iA++) { %>
  179. <% const auditors = stage.auditors; %>
  180. <li class="list-group-item">
  181. <% if (auditors[iA].status === auditConst.status.checked) { %>
  182. <span class="text-success pull-right"><small><%- auditors[iA].end_time.toLocaleDateString() %></small> 审批通过</span>
  183. <h5 class="card-title"><i class="<%- (iA < auditors.length - 1 ? 'fa fa-chevron-circle-down text-success' : 'fa fa-stop-circle text-success') %>"></i> <%- auditors[iA].name %> <small class="text-muted"><%- auditors[iA].role %></small></h5>
  184. <p class="card-text"><%- auditors[iA].opinion %></p>
  185. <% } else if (auditors[iA].status == auditConst.status.checking) { %>
  186. <span class="pull-right">审批中</span>
  187. <h5 class="card-title"><i class="<%- (iA < auditors.length - 1 ? 'fa fa-chevron-circle-down' : 'fa fa-stop-circle') %>"></i> <%- auditors[iA].name %> <small class="text-muted"><%- auditors[iA].role %></small></h5>
  188. <% if (auditors[iA].aid === ctx.session.sessionUser.accountId) { %>
  189. <% audit = auditors[iA]; %>
  190. <div class="form-group">
  191. <div class="text-center">
  192. <button class="btn btn-success" data-toggle="modal" data-target="#sp-done" >审批通过</button>
  193. <button class="btn btn-warning" data-toggle="modal" data-target="#sp-back" >审批退回</button>
  194. </div>
  195. </div>
  196. <% } %>
  197. <% } else if (auditors[iA].status === auditConst.status.checkNoPre) { %>
  198. <% const auditorIndex = stage.auditors2.findIndex(function (item) { return item.aid === auditors[iA].aid }) %>
  199. <span class="text-warning pull-right"><small><%- auditors[iA].end_time.toLocaleDateString() %></small>审批退回 <%- stage.auditors2[auditorIndex-1].name %></span>
  200. <h5 class="card-title"><i class="<%- (iA < auditors.length - 1 ? 'fa fa-chevron-circle-down text-warning' : 'fa fa-stop-circle text-warning') %>"></i> <%- auditors[iA].name %> <small class="text-muted"><%- auditors[iA].role %></small></h5>
  201. <p class="card-text"><%- auditors[iA].opinion %></p>
  202. <% } else if (auditors[iA].status === auditConst.status.checkNo) { %>
  203. <span class="text-warning pull-right"><small><%- auditors[iA].end_time.toLocaleDateString() %></small>审批退回</span>
  204. <h5 class="card-title"><i class="<%- (iA < auditors.length - 1 ? 'fa fa-chevron-circle-down text-warning' : 'fa fa-stop-circle text-warning') %>"></i> <%- auditors[iA].name %> <small class="text-muted"><%- auditors[iA].role %></small></h5>
  205. <p class="card-text"><%- auditors[iA].opinion %></p>
  206. <% } else if (auditors[iA].status === auditConst.status.checkAgain) { %>
  207. <span class="text-warning pull-right"><small><%- auditors[iA].end_time.toLocaleDateString() %></small>重新审批</span>
  208. <h5 class="card-title"><i class="<%- (iA < auditors.length - 1 ? 'fa fa-chevron-circle-down text-warning' : 'fa fa-stop-circle text-warning') %>"></i> <%- auditors[iA].name %> <small class="text-muted"><%- auditors[iA].role %></small></h5>
  209. <p class="card-text"><%- auditors[iA].opinion %></p>
  210. <% } else { %>
  211. <h5 class="card-title"><i class="<%- (iA < auditors.length - 1 ? 'fa fa-chevron-circle-down' : 'fa fa-stop-circle') %>"></i> <%- auditors[iA].name %> <small class="text-muted"><%- auditors[iA].role %></small></h5>
  212. <% } %>
  213. </li>
  214. <% } %>
  215. </ul>
  216. </div>
  217. <% } %>
  218. </div>
  219. </div>
  220. </div>
  221. <!--底栏菜单-->
  222. <nav class="fixed-bottom navbar-dark bg-light border-top">
  223. <ul class="nav nav-fill my-2">
  224. <li class="nav-item">
  225. <a class="nav-link text-muted" href="/wap/dashboard"><i class="fa fa-check-square-o"></i> 待审批</a>
  226. </li>
  227. <li class="nav-item">
  228. <a class="nav-link active " href="/wap/list"><i class="fa fa-list-ul"></i> 项目</a>
  229. </li>
  230. </ul>
  231. </nav>
  232. </div>
  233. <% if (audit !== 0) { %>
  234. <!--审批通过弹窗-->
  235. <div class="modal" tabindex="-1" role="dialog" id="sp-done">
  236. <div class="modal-dialog" role="document">
  237. <form class="modal-content" action="/tender/<%- stage.tid %>/measure/stage/<%- stage.order %>/audit/check" method="post" onsubmit="return auditCheck(0);">
  238. <div class="modal-header">
  239. <h5 class="modal-title">审批通过</h5>
  240. <button type="button" class="close" data-dismiss="modal" aria-label="Close">
  241. <span aria-hidden="true">&times;</span>
  242. </button>
  243. </div>
  244. <div class="modal-body">
  245. <div class="form-group">
  246. <label>审批意见</label>
  247. <textarea class="form-control" rows="8" name="opinion">同意</textarea>
  248. </div>
  249. </div>
  250. <div class="modal-footer">
  251. <button type="button" class="btn btn-secondary" data-dismiss="modal">取消</button>
  252. <input type="hidden" name="_csrf" value="<%= ctx.csrf %>" />
  253. <input type="hidden" name="checkType" value="<%= auditConst.status.checked %>" />
  254. <button type="submit" class="btn btn-success">审批通过</button>
  255. </div>
  256. </form>
  257. </div>
  258. </div>
  259. <!--审批退回弹窗-->
  260. <div class="modal" tabindex="-1" role="dialog" id="sp-back">
  261. < class="modal-dialog" role="document">
  262. <form class="modal-content" action="/tender/<%- stage.tid %>/measure/stage/<%- stage.order %>/audit/check" method="post" onsubmit="return auditCheck(1);">
  263. <div class="modal-header">
  264. <h5 class="modal-title">审批通过</h5>
  265. <button type="button" class="close" data-dismiss="modal" aria-label="Close">
  266. <span aria-hidden="true">&times;</span>
  267. </button>
  268. </div>
  269. <div class="modal-body">
  270. <div class="form-group">
  271. <label>审批意见</label>
  272. <textarea class="form-control" rows="8" name="opinion">不同意</textarea>
  273. </div>
  274. <div class="alert alert-warning">
  275. <div class="custom-control custom-radio custom-control-inline">
  276. <input type="radio" id="inlineRadio1" class="custom-control-input" value="<%- auditConst.status.checkNo %>" <% if (audit.order === 1 || audit.aid === stage.auditors[0].aid) { %>checked<% } %>>
  277. <label class="custom-control-label" for="customRadioInline1">退回上报 <%- stage.user.name %></label>
  278. </div>
  279. <% if (audit.order > 1 && audit.aid !== stage.auditors[0].aid) { %>
  280. <% const auditorIndex = stage.auditors2.findIndex(function (item) { return item.aid === audit.aid }) %>
  281. <div class="custom-control custom-radio custom-control-inline">
  282. <input class="custom-control-input" type="radio" name="checkType" id="customRadioInline2" value="<%- auditConst.status.checkNoPre %>" checked>
  283. <label class="custom-control-label" for="customRadioInline2">退回上一审批人 <%- stage.auditors2[auditorIndex-1].name %></label>
  284. </div>
  285. <% } %>
  286. </div>
  287. </div>
  288. <div class="modal-footer">
  289. <button type="button" class="btn btn-secondary" data-dismiss="modal">取消</button>
  290. <input type="hidden" name="_csrf" value="<%= ctx.csrf %>" />
  291. <button type="submit" class="btn btn-warning">确认退回</button>
  292. </div>
  293. </form>
  294. </div>
  295. </div>
  296. <% } %>
  297. <!-- JS. -->
  298. <script src="/public/js/jquery/jquery-3.2.1.min.js"></script>
  299. <script src="/public/js/popper/popper.min.js"></script>
  300. <script src="/public/js/bootstrap/bootstrap.min.js"></script>
  301. <!--<script src="js/global.js"></script>-->
  302. <script type="text/javascript">
  303. //4 标段期数计量进度//
  304. var myChart = echarts.init(document.getElementById('chartContainer4'));
  305. var option = {
  306. color: ['#e9af68','#57b7b6','#e4575a','#959eac','#6699FF',
  307. '#d38b70','#8fb7cf','#cd5c5c','#ffa500','#40e0d0',
  308. '#1e90ff','#ff6347','#7b68ee','#00fa9a','#ffd700',
  309. '#5c616b','#ff6666','#3cb371','#b8860b','#30e0e0'],
  310. title : {
  311. text: ''
  312. },
  313. tooltip : {
  314. trigger: 'axis'
  315. },
  316. calculable : true,
  317. legend: {
  318. data:['本期合同计量','本期数量变更计量','截止上期累计完成','本期完成计量','完成度']
  319. },
  320. dataZoom: [
  321. {show: true,start: 0, end: 100}
  322. ],
  323. xAxis : [
  324. {
  325. type : 'category',
  326. splitLine : {show : true},
  327. data : [
  328. <% for (const s of stagesEcharts) {%>
  329. '第<%- s.order %>期',
  330. <% } %>
  331. ]
  332. }
  333. ],
  334. yAxis : [
  335. {
  336. type : 'value',
  337. name : '金额',
  338. position:'left',
  339. axisLabel : {
  340. formatter: '{value} 元'
  341. },
  342. splitArea : {show : true},
  343. splitLine : {show : true},
  344. },
  345. {
  346. type : 'value',
  347. name:'完成度',
  348. axisLabel : {
  349. formatter: '{value} %'
  350. },
  351. position: 'right',
  352. splitArea : {show : false},
  353. splitLine : {show : false},
  354. }
  355. ],
  356. series : [
  357. {
  358. name:'本期合同计量',
  359. type:'bar',
  360. tooltip : {trigger: 'item',formatter: "{b} <br/>{a}:{c}元"},
  361. stack: '合同',
  362. data:[
  363. <% for (const s of stagesEcharts) {%>
  364. <%- s.contract_tp %>,
  365. <% } %>
  366. ]
  367. },
  368. {
  369. name:'本期数量变更计量',
  370. type:'bar',
  371. tooltip : {trigger: 'item',formatter: "{b} <br/>{a}:{c}元"},
  372. stack: '变更',
  373. data:[
  374. <% for (const s of stagesEcharts) {%>
  375. <%- s.qc_tp %>,
  376. <% } %>
  377. ]
  378. },
  379. {
  380. name:'截止上期累计完成',
  381. type:'bar',
  382. tooltip : {trigger: 'item',formatter: "{b} <br/>{a}:{c}元"},
  383. stack: '完成',
  384. data:[
  385. <% for (const s of stagesEcharts) {%>
  386. <%- ctx.helper.add(s.pre_contract_tp, s.pre_qc_tp) %>,
  387. <% } %>
  388. ]
  389. },
  390. {
  391. name:'本期完成计量',
  392. type:'bar',
  393. tooltip : {trigger: 'item',formatter: "{b} <br/>{a}:{c}元"},
  394. stack: '完成',
  395. data:[
  396. <% for (const s of stagesEcharts) {%>
  397. <%- ctx.helper.add(s.contract_tp, s.qc_tp) %>,
  398. <% } %>
  399. ]
  400. },
  401. {
  402. name:'完成度',
  403. type:'line',
  404. tooltip : {trigger: 'axis',formatter: "{b}占总标段<br/>{a}:{c} %"},
  405. yAxisIndex: 1,
  406. data:[
  407. <% for (const s of stagesEcharts) {%>
  408. <%- ctx.helper.mul(ctx.helper.div(ctx.helper.add(s.contract_tp, s.qc_tp), tender.sum, 2), 100) %>,
  409. <% } %>
  410. ]
  411. },
  412. ]
  413. };
  414. // 为echarts对象加载数据
  415. myChart.setOption(option);
  416. //4 标段期数计量进度//
  417. //3 标段月进度//
  418. // 基于准备好的dom,初始化echarts图表
  419. var myChart = echarts.init(document.getElementById('chartContainer3'));
  420. var option = {
  421. color:["#e9af68","#57b7b6"],
  422. title : {
  423. text: ''
  424. },
  425. tooltip : {
  426. trigger: 'axis',
  427. formatter: function (params, ticket, callback) {
  428. let sHint = '';
  429. for (const param of params) {
  430. if (sHint !== '') {
  431. sHint += '<br>';
  432. }
  433. if (sHint === '' && param.name !== '') {
  434. sHint = param.name + '<br>';
  435. }
  436. sHint += '<span style="display:inline-block;margin-right:5px;border-radius:10px;width:9px;height:9px;background-color:' + param.color +'"></span>';
  437. if (param.data) {
  438. sHint += param.seriesName + ': ' + param.data + ' %';
  439. } else {
  440. sHint += param.seriesName + ': -';
  441. }
  442. }
  443. return sHint;
  444. },
  445. },
  446. legend: {
  447. data:['截止本月完成','本月完成']
  448. },
  449. toolbox: {
  450. show : true,
  451. feature : {
  452. magicType : {show: true, type: ['line', 'bar']}
  453. }
  454. },
  455. dataZoom : {
  456. show : true,
  457. start : 50,
  458. end : 100
  459. },
  460. xAxis : [
  461. {
  462. type : 'category',
  463. boundaryGap : true,
  464. data : [
  465. <% for (const mp of monthProgress) { %>
  466. '<%- mp.month %>',
  467. <% } %>
  468. ]
  469. }
  470. ],
  471. yAxis : [
  472. {
  473. type : 'value',
  474. axisLabel : {
  475. formatter: '{value} %'
  476. },
  477. splitArea : {show : true}
  478. }
  479. ],
  480. series : [
  481. {
  482. name:'截止本月完成',
  483. type:'line',
  484. itemStyle: {
  485. normal: {
  486. lineStyle: {
  487. shadowColor : 'rgba(0,0,0,0.4)',
  488. shadowBlur: 5,
  489. shadowOffsetX: 3,
  490. shadowOffsetY: 3
  491. }
  492. }
  493. },
  494. data:[
  495. <% for (const mp of monthProgress) { %>
  496. <%- mp.end_ratio %>,
  497. <% } %>
  498. ]
  499. },
  500. {
  501. name:'本月完成',
  502. type:'line',
  503. itemStyle: {
  504. normal: {
  505. lineStyle: {
  506. shadowColor : 'rgba(0,0,0,0.4)',
  507. shadowBlur: 5,
  508. shadowOffsetX: 3,
  509. shadowOffsetY: 3
  510. }
  511. }
  512. },
  513. data:[
  514. <% for (const mp of monthProgress) { %>
  515. <%- mp.ratio %>,
  516. <% } %>
  517. ]
  518. }
  519. ]
  520. };
  521. // 为echarts对象加载数据
  522. myChart.setOption(option);
  523. //3 标段月进度//
  524. </script>
  525. <!--sjs-->
  526. <script>
  527. $(document).ready(function () {
  528. if (window.location.hash && window.location.hash === '#shenpi') {
  529. $('#gaikuang').removeClass('active');
  530. $('#jlqi').removeClass('active');
  531. $('.nav-item a[href="#gaikuang"]').removeClass('active');
  532. $('.nav-item a[href="#jlqi"]').removeClass('active');
  533. $('#shenpi').addClass('active');
  534. $('.nav-item a[href="#shenpi"]').addClass('active');
  535. }
  536. })
  537. // texterea换行
  538. function auditCheck(i) {
  539. const opinion = $('textarea[name="opinion"]').eq(i).val().replace(/\r\n/g, '<br/>').replace(/\n/g, '<br/>').replace(/\s/g, ' ');
  540. $('textarea[name="opinion"]').eq(i).val(opinion);
  541. return true;
  542. }
  543. </script>
  544. </body>
  545. </html>