project_overview.html 20 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="UTF-8">
  5. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  6. <title>Document</title>
  7. <style>
  8. .attachment{
  9. overflow-y: auto;
  10. display: -webkit-box;
  11. -webkit-overflow-scrolling: touch;
  12. }
  13. .attachment li{
  14. padding: 0.5vw 0.7vw 0.5vw 0.7vw;
  15. white-space: nowrap;
  16. display: inline-block;
  17. border-right: 1px solid #e2e2e2;
  18. }
  19. .attachment p{
  20. margin: 3px 0 5px 0;
  21. width: 11vw;
  22. overflow: hidden;
  23. text-overflow: ellipsis;
  24. text-align: center;
  25. }
  26. /* #filesBox li{
  27. width: 145px;
  28. } */
  29. .heading th, .form th{
  30. height: 54.8px;
  31. }
  32. .report-title{
  33. height: 54.8px;
  34. }
  35. .report-title th{
  36. padding-left: 15px;
  37. border: 1px solid #e2e2e2;
  38. font: 14px Helvetica Neue, Helvetica, PingFang SC, Tahoma, Arial, sans-serif;
  39. }
  40. .heading th{
  41. border: 1px solid #e2e2e2;
  42. }
  43. .form th{
  44. border: 1px solid #e2e2e2;
  45. }
  46. #filesBox2 .layui-table-tool{
  47. display: none;
  48. }
  49. #filesBox2 .layui-table-view .layui-table{
  50. width: 100% !important;
  51. }
  52. #filesBox2 .layui-table-cell{
  53. display: flex;
  54. align-items: center;
  55. justify-content: center;
  56. }
  57. .laytable-cell-1-0-1, .laytable-cell-1-0-2{
  58. justify-content: flex-start !important;
  59. }
  60. .laytable-cell-1-0-0 span, .laytable-cell-1-0-1 span, .laytable-cell-1-0-2 span, .laytable-cell-1-0-3 span, .laytable-cell-1-0-4 span, th>.laytable-cell-1-0-5 span{
  61. display: flex;
  62. font: 14px red;
  63. font-weight: 600;
  64. color: #5f5f5f;
  65. }
  66. #tabniubi tr:first-child th{
  67. border-right: 1px solid #e2e2e2 !important;
  68. }
  69. #filesBox2 th:sixth-child{
  70. border-right: none !important;
  71. }
  72. </style>
  73. </head>
  74. <body>
  75. <table id="tabniubi" cellpadding="1" cellspacing="1">
  76. <tr>
  77. <th style="width: 10%;height: 0;"></th>
  78. <th style="width: 10%;height: 0;"></th>
  79. <th style="width: 10%;height: 0;"></th>
  80. <th style="width: 10%;height: 0;"></th>
  81. <th style="width: 10%;height: 0;"></th>
  82. <th style="width: 10%;height: 0;"></th>
  83. <th style="width: 10%;height: 0;"></th>
  84. <th style="width: 10%;height: 0;"></th>
  85. <th style="width: 10%;height: 0;"></th>
  86. </tr>
  87. <tr border="1">
  88. {if $field.project_status == 1}
  89. <th class="form-title">项目状态</th>
  90. <th>
  91. {switch $detail.project_status}
  92. {case 1}立项中{/case}
  93. {case 2}审批中{/case}
  94. {case 3}待接收{/case}
  95. {case 4}待分配{/case}
  96. {case 5}作业中{/case}
  97. {case 6}归档中{/case}
  98. {case 7}退审中{/case}
  99. {case 8}已归档{/case}
  100. {case 9}已退审{/case}
  101. {default /}未知
  102. {/switch}
  103. </th>
  104. {/if}
  105. {if $field.project_name == 1}
  106. <th class="form-title">项目名称</th>
  107. <th colspan="3">{$detail.project_name}</th>
  108. {/if}
  109. {if $field.project_num == 1}
  110. <th class="form-title">项目编号</th>
  111. <th colspan="2">{$detail.project_num}</th>
  112. {/if}
  113. </tr>
  114. <tr>
  115. {if $field.project_time == 1}
  116. <th class="form-title">项目周期</th>
  117. <th colspan="8" style="text-align: left; padding-left: 3.5vw;">{$detail.project_start_time|date="Y-m-d"} 至 {$detail.project_end_time|date="Y-m-d"}</th>
  118. {/if}
  119. </tr>
  120. <tr>
  121. {if $field.engineering_type == 1}
  122. <th class="form-title">项目类型</th>
  123. <th>
  124. {if $detail.engineering_type1==1}
  125. 预算
  126. {elseif $detail.engineering_type1==2}
  127. 结算
  128. {elseif $detail.engineering_type1==3}
  129. 概算
  130. {elseif $detail.engineering_type1==4}
  131. 决算
  132. {elseif $detail.engineering_type1==5}
  133. 工程总承包(EPC)
  134. {/if}
  135. <!-- <div>
  136. <select name="type" lay-verify="required" lay-filter="aihao">
  137. <option value="1" style="align-items: center;">预算</option>
  138. <option value="2">结算</option>
  139. </select>
  140. </div>-->
  141. </th>
  142. <th class="form-title">——</th>
  143. <th>
  144. {if $detail.engineering_type2==1}
  145. 审核
  146. {elseif $detail.engineering_type2==2}
  147. 编制
  148. {/if}
  149. </th>
  150. {/if}
  151. {if $field.engineering_category == 1}
  152. <th class="form-title">工程类别</th>
  153. <th>{$detail.engineering_category}</th>
  154. {/if}
  155. {if $field.project_region == 1}
  156. <th class="form-title">项目区域</th>
  157. <th colspan="2">
  158. {$detail.province}-{$detail.city}-{$detail.area}
  159. <!--<div>
  160. <form class="layui-form">
  161. <div class="layui-form-item" style="margin-bottom: 0;">
  162. <div class="layui-input-inline" style="width: 6vw;">
  163. <select id="province" lay-filter="province" name="province">
  164. </select>
  165. </div>
  166. <div class="layui-input-inline area" style="width: 6vw;">
  167. <select id="city" lay-filter="city" name="city">
  168. </select>
  169. </div>
  170. <div class="layui-input-inline area" style="width: 6vw;">
  171. <select id="area" lay-filter="area" name="area">
  172. </select>
  173. </div>
  174. </div>
  175. </form>
  176. </div>-->
  177. </th>
  178. {/if}
  179. </tr>
  180. <tr>
  181. {if $field.fiscal_nature == 1}
  182. <th class="form-title">资金性质</th>
  183. <th>{$detail.fiscal_nature}</th>
  184. {/if}
  185. {if $field.project_scale == 1}
  186. <th class="form-title">项目规模</th>
  187. <th colspan="3">{$detail.project_scale}</th>
  188. {/if}
  189. {if $field.charge_standard == 1}
  190. <th class="form-title">收费标准</th>
  191. <th colspan="2">{$detail.charge_standard}</th>
  192. {/if}
  193. </tr>
  194. {if $field.entrust_unit == 1 || $field.entrust_head == 1 || $field.sent_review_unit == 1 || $field.sent_review_head == 1
  195. || $field.review_unit == 1 || $field.review_head == 1 || $field.operate_name == 1 || $field.operate_team_names == 1}
  196. <tr>
  197. <th colspan="9" class="forleft">相关单位</th>
  198. </tr>
  199. <tr>
  200. {if $field.entrust_unit == 1}
  201. <th class="form-title">委托单位</th>
  202. <th>{$detail.entrust_unit_name}</th>
  203. {/if}
  204. {if $field.entrust_head == 1}
  205. <th class="form-title">负责人</th>
  206. <th>{$detail.entrust_maker_name}</th>
  207. {/if}
  208. {if $field.sent_review_unit == 1}
  209. <th class="form-title">送审单位</th>
  210. <th>{$detail.sent_review_unit_name}</th>
  211. {/if}
  212. {if $field.sent_review_head == 1}
  213. <th class="form-title">负责人</th>
  214. <th colspan="2">{$detail.sent_review_head_name}</th>
  215. {/if}
  216. </tr>
  217. <tr>
  218. {if $field.review_unit == 1}
  219. <th class="form-title">评审机构</th>
  220. <th>{$detail.review_unit_name}</th>
  221. {/if}
  222. {if $field.review_head == 1}
  223. <th class="form-title">项目负责人</th>
  224. <th>{$detail.review_head_name}</th>
  225. {/if}
  226. {if $field.operate_name == 1}
  227. <th class="form-title">作业负责人</th>
  228. <th>{$detail.operate_head_name}</th>
  229. {/if}
  230. {if $field.operate_team_names == 1}
  231. <th class="form-title">作业成员</th>
  232. <th colspan="2">{$detail.operate_team_names}</th>
  233. {/if}
  234. </tr>
  235. {/if}
  236. {if $field.sent_review_amount == 1 || $field.authorize_amount == 1
  237. || $field.review_add_reduce_amount == 1 || $field.review_add_reduce_rate == 1 || $field.sent_review_cost == 1}
  238. <tr>
  239. <th colspan="9" class="forleft">金额详情</th>
  240. </tr>
  241. <tr>
  242. {if $field.sent_review_amount == 1}
  243. <th class="form-title" colspan="1">送审金额(元)</th>
  244. <th colspan="3" style="text-align: left;">{$detail.sent_review_amount}</th>
  245. {/if}
  246. {if $field.authorize_amount == 1}
  247. <th class="form-title" colspan="1">审定金额(元)</th>
  248. <th colspan="4" style="text-align: left;">{$detail.authorize_amount}</th>
  249. {/if}
  250. </tr>
  251. <tr>
  252. {if $field.review_add_reduce_amount == 1}
  253. <th class="form-title" colspan="1">审增额(元)</th>
  254. <th colspan="1">{$detail.review_add_amount}</th>
  255. <th class="form-title" colspan="1">审减额(元)</th>
  256. <th colspan="1">{$detail.review_reduce_amount}</th>
  257. {/if}
  258. {if $field.review_add_reduce_rate == 1}
  259. <th class="form-title" colspan="1">审增减率(%)</th>
  260. <th colspan="1">{$detail.review_add_reduce_rate}</th>
  261. {/if}
  262. {if $field.sent_review_cost == 1}
  263. <th class="form-title" colspan="1">送审服务费 (元)</th>
  264. <th colspan="4" style="text-align: left;">{$detail.sent_review_cost}</th>
  265. {/if}
  266. </tr>
  267. {/if}
  268. <!-- <tr>
  269. <th class="form-title" colspan="1">报告时间</th>
  270. <th colspan="8" style="text-align: left;">{$detail.report_time}</th>
  271. </tr>-->
  272. <tr>
  273. <th colspan="9" class="forleft">相关附件
  274. </th>
  275. </tr>
  276. <tr>
  277. <th colspan="9" class="fujianimg" style="padding: 0px;">
  278. <div id="filesBox2">
  279. <table class="layui-hide" id="get_file" lay-filter="get_file"></table>
  280. </div>
  281. </th>
  282. </tr>
  283. </table>
  284. <table class="layui-table layui-table-form">
  285. <table class="layui-table">
  286. <colgroup>
  287. <col width="110">
  288. <col width="800">
  289. <col width="250">
  290. <col width="250">
  291. <col width="250">
  292. </colgroup>
  293. <thead class="report-title">
  294. <tr>
  295. <th class="layui-th-gray-1 " colspan=9 style="height: 36px;">项目报告
  296. </th>
  297. </tr>
  298. {if !empty($report) }
  299. <thead>
  300. <tr class="heading" style="background-color:rgb(241, 241, 241);">
  301. <th>序号</th>
  302. <th style="text-align: left;">报告名称</th>
  303. <th>报告类型</th>
  304. <th>上传时间</th>
  305. <th>发布人</th>
  306. </tr>
  307. </thead>
  308. <tbody class="form">
  309. {volist name="report" id="vo"}
  310. <tr>
  311. <th>{$vo.id}</th>
  312. <th style="text-align: left;"><a data-id="{$vo.id}" lay-data="readreport" style="color: #187FDD;">{$vo.title}</a></th>
  313. <th> {switch $vo.type}
  314. {case 0}初审报告{/case}
  315. {case 1}对数报告{/case}
  316. {case 2}审定报告{/case}
  317. {default /}未知
  318. {/switch}
  319. </th>
  320. <th>{$vo.create_time|date="Y-m-d"}</th>
  321. <th>{$vo.nickname}</th>
  322. </tr>
  323. {/volist}
  324. </tbody>
  325. {/if}
  326. </table>
  327. {empty name="$report" }
  328. <div class="layui-data-none">暂无项目报告</div>
  329. {/empty}
  330. <table class="layui-table" >
  331. <colgroup>
  332. <col width="110">
  333. <col width="800">
  334. <col width="250">
  335. <col width="250">
  336. <col width="250">
  337. </colgroup>
  338. <thead class="heading-1">
  339. <tr>
  340. <th class="layui-td-gray-1" colspan=9 style="height: 36px;font-weight: 500;"> &nbsp;&nbsp;项目合同</th>
  341. </tr>
  342. {if !empty($contract) }
  343. <thead>
  344. <tr class="heading" >
  345. <th>序号</th>
  346. <th style="text-align: left;">合同名称</th>
  347. <th>合同性质</th>
  348. <th>签订时间</th>
  349. <th>签订人</th>
  350. </tr>
  351. </thead>
  352. <tbody class="form">
  353. {volist name="$contract" id="vo"}
  354. <tr>
  355. <td>{$vo.id}</td>
  356. <td style="text-align: left;"><a data-id="{$vo.id}" lay-data="readContract" href="" style="color: #187FDD;">{$vo.name}</a></td>
  357. <td> {switch $vo.type}
  358. {case 1}普通合同{/case}
  359. {case 2}框架合同{/case}
  360. {case 3}补充协议{/case}
  361. {case 3}其他合同{/case}
  362. {default /}未设置
  363. {/switch}
  364. </td>
  365. <td>{$vo.sign_time|date='Y-m-d'}</td>
  366. <td>{$vo.sign_name}</td>
  367. </tr>
  368. {/volist}
  369. </tbody>
  370. {/if}
  371. </table>
  372. {empty name="$contract" }
  373. <div class="layui-data-none">暂无项目合同</div>
  374. {/empty}
  375. </table>
  376. <script>
  377. function first(){
  378. let table = layui.table;
  379. //项目任务
  380. var allcount;
  381. parent.layui.get_fileTable = table.render({
  382. elem: '#get_file',
  383. title: '文档列表',
  384. toolbar: '#toolbarget_file',
  385. cellMinWidth: 80,
  386. parseData: function (res) { // 数据解析回调函数
  387. // 在这里可以获取数据总数
  388. allcount = res.data.length;
  389. return {
  390. code: res.code, // 数据状态码
  391. msg: res.msg, // 状态信息
  392. count: res.count, // 数据总数
  393. data: res.data // 当前页数据
  394. };
  395. },
  396. // className: 'layui-table-testcss', // 用于给表格主容器追加 css 类名
  397. // lineStyle: 'height: 151px;', // 定义表格的多行样式
  398. url: "/admin/project.api/get_file",
  399. where: {'id': project_id},
  400. page: true, //开启分页
  401. limit: 20,
  402. cols: [[
  403. {field: 'id', title: '序号', width: 80, align: 'center',
  404. templet: function (d) {
  405. console.log(allcount,d.LAY_NUM)
  406. return allcount - (d.LAY_NUM - 1);
  407. }
  408. },
  409. {field: 'name', title: '附件名称', align: 'left',
  410. },
  411. {field: 'remark', title: '附件说明', align: 'left',
  412. },
  413. {field: 'admin_name', title: '上传人', align: 'center', width: 150},
  414. {field: 'create_time', title: '上传时间', align: 'center', width: 100},
  415. {field: 'right', fixed: 'right', title: '操作', width: 150, align: 'center',
  416. templet: function (d) {
  417. var html = '<div class="layui-btn-group">';
  418. var btn1 = `<a href="https://view.officeapps.live.com/op/view.aspx?src=${d.filepath}" target="_blank" class="layui-btn layui-btn-xs">预览</a>`;
  419. var btn2 = `<a class="layui-btn layui-btn-xs layui-bg-blue" href="${d.filepath}" download="${d.name}" lay-event="">下载</a>`;
  420. return html + btn1 + btn2 +'</div>';
  421. }
  422. }
  423. ]]
  424. });
  425. layui.use(['form', 'jquery'], function () {
  426. var form = layui.form;
  427. const $ = layui.jquery;
  428. let adress;
  429. $.ajax({
  430. type:"get", //使用get方式
  431. url: "/static/assets/layui/adress.json", //json文件相对于这个HTML的路径
  432. dataType:"json",
  433. async: false,
  434. success:function(data) {
  435. //这个data就是json数据
  436. adress = data
  437. },
  438. error:function() {
  439. layer.alert("地址请求失败!! ");
  440. }
  441. });
  442. function getFirstAttr(obj) {
  443. for (var k in obj) return k;
  444. }
  445. function selectOption(selectedProvince, selectedCity,selectedArea) {
  446. var proStr = '', cityStr = '', areaStr = '';
  447. var pro = adress[selectedProvince], ci = adress[selectedProvince][selectedCity];
  448. for (var province in adress) {
  449. if (province == selectedProvince) proStr += '<option value="' + province + '" selected>' + province + '</option>';
  450. else proStr += '<option value="' + province + '">' + province + '</option>';
  451. }
  452. $("#province").html(proStr);
  453. for (var city in pro) {
  454. if (city == selectedCity) cityStr += '<option value="' + city + '" selected>' + city + '</option>';
  455. else cityStr += '<option value="' + city + '">' + city + '</option>';
  456. }
  457. $("#city").html(cityStr);
  458. for (var area in ci) {
  459. if(area == "remove"){
  460. continue;
  461. }
  462. if (ci[area] == selectedArea) areaStr += '<option value="' + ci[area] + '" selected>' + ci[area] + '</option>';
  463. else areaStr += '<option value="' + ci[area] + '">' + ci[area] + '</option>';
  464. }
  465. $("#area").html(areaStr);
  466. form.render();
  467. }
  468. selectOption('湖北省', getFirstAttr(adress['湖北省']),'硚口区');
  469. form.on('select(province)', function (data) {
  470. let thisProvince = data.value;
  471. let thisCity = getFirstAttr(adress[thisProvince]);
  472. selectOption(data.value, thisCity,thisCity[0]);
  473. });
  474. form.on('select(city)', function (data) {
  475. selectOption($("#province").val(), data.value,getFirstAttr(data.value));
  476. });
  477. })
  478. $('#filesBox').on('click','.file-del',function(){
  479. layer.msg("不可删除");
  480. })
  481. }
  482. </script>
  483. <script>
  484. // 获取具有指定 ID 的 <ul> 元素
  485. var ulElement = document.getElementById("filesBox");
  486. // 检查 <ul> 元素的子元素数量
  487. if (ulElement.children.length === 0) {
  488. // 如果子元素数量为 0,隐藏 <ul> 元素
  489. ulElement.style.display = "none";
  490. }
  491. </script>
  492. </body>
  493. </html>