edit_first.html 37 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250
  1. <style>
  2. .heading th {
  3. text-align: center;
  4. }
  5. .form td {
  6. text-align: center;
  7. }
  8. /* 日志 */
  9. .log_top {
  10. padding-left: 1vw;
  11. }
  12. .log_top span {
  13. margin: 0 0.5vw;
  14. }
  15. /* 1,1,1 */
  16. .log_commentary {
  17. color: rgb(0, 176, 80);
  18. }
  19. .log_company {
  20. color: rgb(255, 33, 0);
  21. }
  22. .log_content {
  23. width: fit-content;
  24. margin: 0.3vw 1.5vw 1vw 1.5vw;
  25. padding: 0.5vw 0vw;
  26. text-indent: 1.2em;
  27. line-height: 2.1vh;
  28. background-color: rgb(255, 255, 255);
  29. border-radius: 0.5vw;
  30. box-shadow: 0.19vw 0.16vw 0.4vw 0.03vw rgba(0, 0, 0, 0.13);
  31. }
  32. .log_content_color {
  33. /* background-color: rgb(250,250,250); */
  34. }
  35. .log_content_img img {
  36. /* width: 10%; */
  37. border-radius: 0.5vw;
  38. margin: 0.3vw 0;
  39. padding-right: 18px;
  40. padding-bottom: 7px;
  41. padding-left: 2px;
  42. }
  43. .log_item_top {
  44. height: 70%;
  45. overflow: scroll;
  46. }
  47. .log_item_top {
  48. height: 60vh;
  49. /* background-color: rgb(255, 255, 255); */
  50. }
  51. .log_item_bottom {
  52. display: flex;
  53. /* height: 17vh; */
  54. /* border-top: 1px solid #eee; */
  55. margin: 0 1.5vw;
  56. /* background-color: rgb(250,250,250); */
  57. }
  58. .log_input input {
  59. width: 55vw;
  60. height: 10vh;
  61. border: #eee 1px solid;
  62. }
  63. .log_bottom_img {
  64. /* height: 5vh; */
  65. }
  66. .log_bottom_img img {
  67. height: 4vw;
  68. width: 6vw;
  69. border-radius: 0.5vw;
  70. margin: 0.5vw 0vw 0.5vw 0.3vw;
  71. }
  72. .log_bottom_left {
  73. width: 100%;
  74. margin-top: 1.5vh;
  75. }
  76. .log_bottom_right {
  77. width: 5%;
  78. }
  79. /* 上传图片 */
  80. .layui-upload-drag-self {
  81. background-color: #fbfdff;
  82. border: 1px dashed #c0ccda;
  83. border-radius: 6px;
  84. box-sizing: border-box;
  85. line-height: 4vw;
  86. vertical-align: top;
  87. display: inline-block;
  88. text-align: center;
  89. cursor: pointer;
  90. outline: 0;
  91. margin-right: 13px;
  92. float: left;
  93. }
  94. .layui-input-inlines-self {
  95. position: relative;
  96. margin-left: 90px;
  97. min-height: 36px;
  98. text-align: left;
  99. }
  100. .layui-upload-drag-self .layui-icon {
  101. font-size: 28px;
  102. color: #8c939d
  103. }
  104. .layui-upload-drag-self .img {
  105. position: relative;
  106. height: 148px;
  107. width: 148px;
  108. }
  109. .layui-upload-img {
  110. width: 148px;
  111. height: 148px;
  112. border-radius: 6px;
  113. margin-top: -3px;
  114. margin-left: -2px;
  115. }
  116. .handle {
  117. position: absolute;
  118. width: 148px;
  119. height: 100%;
  120. z-index: 100;
  121. border-radius: 6px;
  122. top: 0;
  123. background: rgba(59, 60, 61, 0.6);
  124. text-align: center;
  125. }
  126. .handle .icon-myself {
  127. z-index: 999;
  128. transition: all .3s;
  129. cursor: pointer;
  130. font-size: 25px;
  131. width: 25px;
  132. color: rgba(255, 255, 255, 0.91);
  133. margin: 0 4px;
  134. }
  135. .log_textarea {
  136. width: 89vw;
  137. height: 8vh;
  138. padding: 0.5vw;
  139. /* margin-right: 2vw; */
  140. margin: 1vw;
  141. }
  142. .log_button_img {
  143. width: 2vw;
  144. }
  145. .log_card {
  146. border: none !important;
  147. }
  148. /* 点击图片放大 */
  149. .content_img img {
  150. max-width: 100%;
  151. cursor: pointer;
  152. }
  153. .overlay {
  154. display: none;
  155. position: fixed;
  156. top: 0;
  157. left: 0;
  158. width: 100%;
  159. height: 100%;
  160. background-color: rgba(0, 0, 0, 0.7);
  161. justify-content: center;
  162. z-index: 1;
  163. }
  164. .overlay img {
  165. margin-top: 4%;
  166. max-width: 90%;
  167. max-height: 90%;
  168. object-fit: contain;
  169. }
  170. .p-4 {
  171. background-color: rgb(255, 255, 255);
  172. }
  173. /*表格*/
  174. #tabniubi {
  175. width: 100%;
  176. margin: 10px 0;
  177. background-color: #fff;
  178. color: #5f5f5f;
  179. }
  180. #tabniubi th {
  181. padding: 9px 15px;
  182. min-height: 20px;
  183. height: 0px;
  184. line-height:0px;
  185. text-align: center;
  186. /* font-size: 14px; */
  187. border-width: 1px;
  188. border-style: solid;
  189. border-color: #e2e2e2;
  190. font: 14px Helvetica Neue, Helvetica, PingFang SC, Tahoma, Arial, sans-serif;
  191. }
  192. #tabniubi tr:first-child {
  193. padding: 0;
  194. min-height: 0;
  195. line-height: 0;
  196. border-width: 0;
  197. border-style: none;
  198. border-color: #fff;
  199. font-size: 0;
  200. }
  201. #tabniubi tr:first-child th {
  202. padding: 0;
  203. min-height: 0;
  204. line-height: 0;
  205. border-width: 0;
  206. border-style: none;
  207. border-color: #fff;
  208. font-size: 0;
  209. height: 0 !important;
  210. }
  211. .form-title {
  212. background-color: rgb(241, 241, 241);
  213. color: rgb(95, 95, 95);
  214. border-color: rgb(241, 241, 241);
  215. font-weight: 600;
  216. }
  217. /* .fujianimg img {
  218. width: 5vw;
  219. height: 5vh;
  220. } */
  221. .forleft {
  222. text-align: left !important;
  223. }
  224. .layui-form-select dl dd.layui-this {
  225. background-color: #f8f8f8;
  226. color: rgb(23, 145, 233);
  227. font-weight: 700;
  228. }
  229. .layui-input, .layui-textarea {
  230. /* padding-left: 3.75vw; */
  231. color: #5f5f5f;
  232. }
  233. .upimg {
  234. width: 250px;
  235. height: 250px;
  236. }
  237. .fujianimg img {
  238. height: 5.5vh;
  239. }
  240. .filelist{
  241. width: 100%;
  242. overflow: auto;
  243. justify-content:flex-start;
  244. align-content: space-between;
  245. flex-direction: column-reverse;
  246. flex-wrap: wrap;
  247. display: flex;
  248. }
  249. .filelist li{
  250. padding: 0.5vw 0.8vw 0.5vw 0.8vw;
  251. white-space: nowrap;
  252. overflow: hidden;
  253. text-overflow: ellipsis;
  254. display: inline-block;
  255. border-right: 1px solid #e2e2e2;
  256. float: left;
  257. }
  258. .filelist p{
  259. margin: 3px 0 5px 0;
  260. width: 11vw;
  261. overflow: hidden;
  262. text-overflow: ellipsis;
  263. text-align: center;
  264. }
  265. #filesBox2 li{
  266. padding: 0.5vw 0.8vw 0.5vw 0.8vw;
  267. white-space: nowrap;
  268. overflow: hidden;
  269. text-overflow: ellipsis;
  270. display: inline-block;
  271. border-right: 1px solid #e2e2e2;
  272. float: left;
  273. }
  274. /* 倒计时 */
  275. .countdown {
  276. height: 8.5vh;
  277. width: 6.5vw;
  278. font-size: 1vw;
  279. text-align: center;
  280. border: 1px solid #eee;
  281. }
  282. .countdown-top {
  283. height: 3.5vh;
  284. line-height: 3.5vh;
  285. border-bottom: 1px solid #eee;
  286. color: #fff;
  287. background-color: rgb(23, 145, 233);
  288. border-bottom: 1px solid rgb(23, 145, 233);
  289. font-size: 0.95vw;
  290. padding: 0;
  291. margin: 0;
  292. }
  293. .countdown-bottom {
  294. height: 5vh;
  295. line-height: 5vh;
  296. padding: 0;
  297. margin: 0;
  298. background-color: #fff;
  299. }
  300. #filesBox2 .layui-table-tool{
  301. display: none;
  302. }
  303. #filesBox2 .layui-table-view .layui-table{
  304. width: 100% !important;
  305. }
  306. #filesBox2 .layui-table-cell{
  307. display: flex;
  308. align-items: center;
  309. justify-content: center;
  310. }
  311. .laytable-cell-1-0-1, .laytable-cell-1-0-2{
  312. justify-content: flex-start !important;
  313. }
  314. .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{
  315. display: flex;
  316. font: 14px red;
  317. font-weight: 600;
  318. color: #5f5f5f;
  319. }
  320. #tabniubi tr:first-child th{
  321. border-right: 1px solid #e2e2e2 !important;
  322. }
  323. #filesBox2 th:sixth-child{
  324. border-right: none !important;
  325. }
  326. </style>
  327. <!--审核以下-->
  328. {if $detail.project_status<3}
  329. <form class="layui-form p-4">
  330. <h3 class="pb-3">编辑造价项目</h3>
  331. <table id="tabniubi" cellpadding="1" cellspacing="1">
  332. <tr>
  333. <th style="width: 10%;height: 0;"></th>
  334. <th style="width: 10%;height: 0;"></th>
  335. <th style="width: 10%;height: 0;"></th>
  336. <th style="width: 10%;height: 0;"></th>
  337. <th style="width: 10%;height: 0;"></th>
  338. <th style="width: 10%;height: 0;"></th>
  339. <th style="width: 10%;height: 0;"></th>
  340. <th style="width: 10%;height: 0;"></th>
  341. <th style="width: 10%;height: 0;"></th>
  342. </tr>
  343. <tr border="1">
  344. {if $field.project_name == 1}
  345. <th class="form-title">项目名称 <font style="color: red !important;">*</font></th>
  346. <th colspan="2">
  347. <input type="text" name="project_name" lay-verify="required" lay-reqText="请完善项目名称" value="{$detail.project_name}" autocomplete="off" placeholder="请输入项目名称" {if $detail.project_status != 1} readonly {elseif $field_edit.project_name_edit != 1 /} readonly {/if} class="layui-input">
  348. </th>
  349. {/if}
  350. {if $field.project_num == 1}
  351. <th class="form-title">项目编号 <font style="color: red !important;">*</font></th>
  352. <th colspan="2">
  353. <input type="text" name="project_num" lay-verify="required" lay-reqText="请完善项目编号" value="{$detail.project_num}" autocomplete="off" placeholder="请输入项目编号" {if $detail.project_status != 1} readonly {elseif $field_edit.project_num_edit != 1/} readonly {/if} class="layui-input">
  354. </th>
  355. {/if}
  356. {if $field.project_time == 1}
  357. <th class="form-title">项目周期 <font style="color: red !important;">*</font></th>
  358. <th id="date" colspan="2">
  359. <div class="layui-input-inline" style="width: 47%;">
  360. <input type="text" id="start_time" name="project_start_time" readonly lay-verify="required" lay-reqText="请选择开始时间" placeholder="请选择" {if $field_edit.project_time_edit != 1} disabled {/if} class="layui-input" value="{$detail.project_start_time|date='Y-m-d'}">
  361. </div>
  362. -
  363. <div class="layui-input-inline" style="width: 47%;">
  364. <input type="text" id="end_time" name="project_end_time" readonly lay-verify="required" lay-reqText="请选择结束时间" placeholder="请选择" {if $field_edit.project_time_edit != 1} disabled {/if} class="layui-input" value="{$detail.project_end_time|date='Y-m-d'}">
  365. </div>
  366. </th>
  367. {/if}
  368. </tr>
  369. <tr>
  370. {if $field.engineering_type == 1}
  371. <th class="form-title ">项目类型 <font style="color: red !important;">*</font></th>
  372. <th colspan="2">
  373. <div>
  374. <select name="engineering_type1" lay-verify="required" lay-filter="aihao"
  375. {if $field_edit.engineering_type_edit != 1}
  376. disabled
  377. {/if}
  378. >
  379. <option value="0"></option>
  380. <option value="1" {eq name="$detail.engineering_type1" value="1"} selected {/eq}>预算</option>
  381. <option value="2"{eq name="$detail.engineering_type1" value="2"} selected {/eq}>结算</option>
  382. <option value="3" {eq name="$detail.engineering_type1" value="3"} selected {/eq}>概算</option>
  383. <option value="4" {eq name="$detail.engineering_type1" value="4"} selected {/eq}>决算</option>
  384. <option value="5" {eq name="$detail.engineering_type1" value="5"} selected {/eq}>工程总承包(EPC)</option>
  385. </select>
  386. </div>
  387. </th>
  388. <th class="form-title " style="text-align: center;">——</th>
  389. <th colspan="2">
  390. <div>
  391. <select name="engineering_type2" lay-verify="required" lay-filter="aihao"
  392. {if $field_edit.engineering_type_edit != 1}
  393. disabled
  394. {/if}
  395. >
  396. <option value=""></option>
  397. <option value="1" {eq name="$detail.engineering_type2" value="1"} selected {/eq}>审核</option>
  398. <option value="2" {eq name="$detail.engineering_type2" value="2"} selected {/eq}>编制</option>
  399. </select>
  400. </div>
  401. </th>
  402. {/if}
  403. {if $field.sent_review_amount}
  404. <th class="form-title ">送审金额 <font style="color: red !important;">*</font></th>
  405. <th colspan="2">
  406. <input type="text" id="sent_review_amount" name="sent_review_amount" autocomplete="off" placeholder="请输入送审金额"
  407. {if $field_edit.sent_review_amount_edit != 1}
  408. readonly
  409. {/if}
  410. class="layui-input" value="{$detail.sent_review_amount}">
  411. </th>
  412. {/if}
  413. <tr>
  414. <!-- 添加送审业主-->
  415. {if $detail.project_status == 1 && $detail.proprietor_stauts !=null}
  416. <tr>
  417. <th class="form-title">送审业主 <font style="color: red !important;">*</font></th>
  418. <th colspan="2">
  419. <!-- 送审单位负责人-->
  420. <select name="sent_review_head" lay-reqText="请选择送审业主">
  421. <option value="">请选择送审业主(暂时不选)</option>
  422. {volist name="person" id="v"}
  423. <option value="{$v.id}">{$v.nickname}</option>
  424. {/volist}
  425. </select>
  426. </th>
  427. </tr>
  428. {/if}
  429. {if $detail.project_status == 1}
  430. <tr>
  431. {if $field.review_unit == 1}
  432. <th class="form-title">评审单位 <font style="color: red !important;">*</font></th>
  433. <th colspan="2">
  434. <input type="text" name="review_unit_name" autocomplete="off" readonly value="{$detail.review_unit_name}"
  435. lay-verify="required" lay-reqText="请输入评审单位" placeholder="请输入评审单位"
  436. {if $field_edit.review_unit_edit != 1}
  437. readonly
  438. {/if}
  439. class="layui-input customer-picker">
  440. <input type="hidden" name="review_unit" value="{$detail.review_unit}">
  441. </th>
  442. {/if}
  443. {if $detail.project_status==1}
  444. <th class="form-title">审批人 <font style="color: red !important;">*</font></th>
  445. <th colspan="2">
  446. <select name="entrust_approver" lay-verify="required" lay-reqText="请选择审批人">
  447. <option value="">请选择审批人</option>
  448. {dump($person)}
  449. {volist name="person" id="v"}
  450. <option value="{$v.id}" {eq name="$detail.entrust_approver" value="$v.id" } selected="" {/eq}>{$v.nickname}</option>
  451. {/volist}
  452. </select>
  453. </th>
  454. <th colspan="2">
  455. <select name="entrust_second_approver" lay-reqText="请选择审批人">
  456. <option value="">请选择第二审批人(可选)</option>
  457. {dump($person)}
  458. {volist name="person" id="v"}
  459. <option value="{$v.id}" {eq name="$detail.entrust_second_approver" value="$v.id"} selected="" {/eq} {if!isset($detail.entrust_second_approver)}name=""{/if}>{$v.nickname}</option>
  460. {/volist}
  461. </select>
  462. </th>
  463. {/if}
  464. </tr>
  465. {/if}
  466. <tr>
  467. {if $detail.project_status>2}
  468. {if $field.sent_review_approver_amount == 1}
  469. <th class="form-title" colspan="2">送审单位承担审核费 <font style="color: red !important;">*</font></th>
  470. <th colspan="2">
  471. <input type="text" lay-verify="required" lay-reqText="请完善送审单位承担审核费" name="sent_review_approver_amount" value="{$detail.sent_review_approver_amount}" autocomplete="off" placeholder="请输入送审单位承担审核费"
  472. {if $field_edit.sent_review_amount_edit != 1}
  473. readonly
  474. {/if}
  475. class="layui-input">
  476. </th>
  477. {/if}
  478. {if $field.construction_approver_amount == 1}
  479. <th class="form-title" colspan="2">施工单位负责核减超5%评审费部分 <font style="color: red !important;">*</font></th>
  480. <th colspan="3">
  481. <input type="text" lay-verify="required" lay-reqText="请完善施工单位负责核减超5%评审费部分" name="construction_approver_amount" value="{$detail.construction_approver_amount}" autocomplete="off" placeholder="请输入施工单位负责核减超5%评审费部分"
  482. {if $field_edit.construction_approver_amount_edit != 1}
  483. readonly
  484. {/if}
  485. class="layui-input">
  486. </th>
  487. {/if}
  488. {/if}
  489. </tr>
  490. <tr>
  491. <th colspan="9" class="forleft">相关附件
  492. <button class="layui-btn layui-btn-xs layui-btn-danger" style="float: right;" type="button"
  493. id="uploadBtn">上传附件
  494. </button>
  495. </th>
  496. </tr>
  497. <tr>
  498. <th colspan="9" class="fujianimg" style="padding: 0 !important;">
  499. <div id="filesBox2" >
  500. <table class="layui-hide" id="get_file" lay-filter="get_file"></table>
  501. </div>
  502. </th>
  503. </tr>
  504. </table>
  505. <div class="py-3">
  506. <input type="hidden" name="id" value="{$detail.id}"/>
  507. {if $detail.project_status == 1}
  508. <button class="layui-btn layui-btn-normal" lay-submit="" lay-filter="webform">保存</button>
  509. <button class="layui-btn layui-btn-normal" lay-submit="" lay-filter="save">提交</button>
  510. {/if}
  511. {if $detail.project_status == 2}
  512. <button class="layui-btn layui-btn-normal" lay-submit="" lay-filter="withdraw">撤回</button>
  513. {/if}
  514. {if $detail.project_status != 1 && $detail.project_status != 2}
  515. <button class="layui-btn layui-btn-normal" lay-submit="" lay-filter="savetime">保存</button>
  516. {/if}
  517. </div>
  518. </form>
  519. {else/}
  520. <form class="layui-form p-4">
  521. <table id="tabniubi" cellpadding="1" cellspacing="1">
  522. <tr>
  523. <th style="width: 10%;height: 0;"></th>
  524. <th style="width: 10%;height: 0;"></th>
  525. <th style="width: 10%;height: 0;"></th>
  526. <th style="width: 10%;height: 0;"></th>
  527. <th style="width: 10%;height: 0;"></th>
  528. <th style="width: 10%;height: 0;"></th>
  529. <th style="width: 10%;height: 0;"></th>
  530. <th style="width: 10%;height: 0;"></th>
  531. <th style="width: 10%;height: 0;"></th>
  532. </tr>
  533. <tr border="1">
  534. {if $field.project_status == 1}
  535. <th class="form-title">项目状态</th>
  536. <th>
  537. {switch $detail.project_status}
  538. {case 1}立项中{/case}
  539. {case 2}审批中{/case}
  540. {case 3}待接收{/case}
  541. {case 4}待分配{/case}
  542. {case 5}作业中{/case}
  543. {case 6}归档中{/case}
  544. {case 7}退审中{/case}
  545. {case 8}已归档{/case}
  546. {case 9}已退审{/case}
  547. {default /}未知
  548. {/switch}
  549. </th>
  550. {/if}
  551. {if $field.project_name == 1}
  552. <th class="form-title">项目名称</th>
  553. <th colspan="3">{$detail.project_name}</th>
  554. {/if}
  555. {if $field.project_num == 1}
  556. <th class="form-title">项目编号</th>
  557. <th colspan="2">{$detail.project_num}</th>
  558. {/if}
  559. </tr>
  560. <tr>
  561. {if $field.project_time == 1}
  562. <th class="form-title">项目周期</th>
  563. <th id="date" colspan="8">
  564. <div class="layui-input-inline" style="width: 47%;">
  565. <input type="text" id="start_time" name="project_start_time" readonly lay-verify="required" lay-reqText="请选择开始时间" placeholder="请选择" {if $field_edit.project_time_edit != 1} disabled {/if} class="layui-input" value="{$detail.project_start_time|date='Y-m-d'}">
  566. </div>
  567. -
  568. <div class="layui-input-inline" style="width: 47%;">
  569. <input type="text" id="end_time" name="project_end_time" readonly lay-verify="required" lay-reqText="请选择结束时间" placeholder="请选择" {if $field_edit.project_time_edit != 1} disabled {/if} class="layui-input" value="{$detail.project_end_time|date='Y-m-d'}">
  570. </div>
  571. </th>
  572. {/if}
  573. </tr>
  574. <tr>
  575. {if $field.engineering_type == 1}
  576. <th class="form-title">工程类型</th>
  577. <th>
  578. {if $detail.engineering_type1==1}
  579. 预算
  580. {elseif $detail.engineering_type1==2}
  581. 结算
  582. {elseif $detail.engineering_type1==3}
  583. 概算
  584. {elseif $detail.engineering_type1==4}
  585. 决算
  586. {elseif $detail.engineering_type1==5}
  587. 工程总承包(EPC)
  588. {/if}
  589. </th>
  590. <th class="form-title">——</th>
  591. <th>
  592. {if $detail.engineering_type2==1}审核{else}编制{/if}
  593. </th>
  594. {/if}
  595. {if $field.engineering_category == 1}
  596. <th class="form-title">工程类别</th>
  597. <th>{$detail.engineering_category}</th>
  598. {/if}
  599. {if $field.project_region == 1}
  600. <th class="form-title">项目区域</th>
  601. <th colspan="2">
  602. {$detail.province}-{$detail.city}-{$detail.area}
  603. </th>
  604. {/if}
  605. </tr>
  606. <tr>
  607. {if $field.fiscal_nature == 1}
  608. <th class="form-title">资金性质</th>
  609. <th>{$detail.fiscal_nature}</th>
  610. {/if}
  611. {if $field.project_scale == 1}
  612. <th class="form-title">项目规模</th>
  613. <th colspan="3">{$detail.project_scale}</th>
  614. {/if}
  615. {if $field.charge_standard == 1}
  616. <th class="form-title">收费标准</th>
  617. <th colspan="2">{$detail.charge_standard}</th>
  618. {/if}
  619. </tr>
  620. {if $field.entrust_unit == 1 || $field.entrust_head == 1 || $field.sent_review_unit == 1 || $field.sent_review_head == 1 || $field.review_unit == 1 || $field.review_head == 1 || $field.operate_name == 1 || $field.operate_team_names == 1 || $field.construction_unit == 1 || $field.construction_head == 1}
  621. <tr>
  622. <th colspan="9" class="forleft">相关单位</th>
  623. </tr>
  624. <tr>
  625. {if $field.entrust_unit == 1}
  626. <th class="form-title">委托单位</th>
  627. <th>{$detail.entrust_unit_name}</th>
  628. {/if}
  629. {if $field.entrust_head == 1}
  630. <th class="form-title">负责人</th>
  631. <th>{$detail.entrust_maker_name}</th>
  632. {/if}
  633. {if $field.sent_review_unit == 1}
  634. <th class="form-title">送审单位</th>
  635. <th>{$detail.sent_review_unit_name}</th>
  636. {/if}
  637. {if $field.sent_review_head == 1}
  638. <th class="form-title">负责人</th>
  639. <th colspan="2">{$detail.sent_review_head_name}</th>
  640. {/if}
  641. </tr>
  642. <tr>
  643. {if $field.review_unit == 1}
  644. <th class="form-title">评审机构</th>
  645. <th>{$detail.review_unit_name}</th>
  646. {/if}
  647. {if $field.review_head == 1}
  648. <th class="form-title">项目负责人</th>
  649. <th>{$detail.review_head_name}</th>
  650. {/if}
  651. {if $field.operate_name == 1}
  652. <th class="form-title">作业负责人</th>
  653. <th>{$detail.operate_head_name}</th>
  654. {/if}
  655. {if $field.operate_team_names == 1}
  656. <th class="form-title">作业成员</th>
  657. <th colspan="2">{$detail.operate_team_names}</th>
  658. {/if}
  659. </tr>
  660. <tr>
  661. {if $field.construction_unit == 1}
  662. <th class="form-title" colspan="1">施工单位</th>
  663. <th colspan="1">{$detail.construction_unit}</th>
  664. {/if}
  665. {if $field.construction_head == 1}
  666. <th class="form-title" colspan="1">负责人</th>
  667. <th colspan="6">{$detail.construction_head}</th>
  668. {/if}
  669. </tr>
  670. {/if}
  671. {if $field.sent_review_amount == 1 || $field.authorize_amount == 1 || $field.review_add_reduce_amount == 1 || $field.review_add_reduce_rate == 1 || $field.sent_review_cost == 1 || $field.sent_review_approver_amount == 1 || $field.construction_approver_amount == 1 || $field.report_time == 1}
  672. <tr>
  673. <th colspan="9" class="forleft">金额详情</th>
  674. </tr>
  675. <tr>
  676. {if $field.sent_review_amount == 1}
  677. <th class="form-title" colspan="1">送审金额(元)</th>
  678. <th colspan="2">{$detail.sent_review_amount}</th>
  679. {/if}
  680. {if $field.authorize_amount == 1}
  681. <th class="form-title" colspan="1">审定金额(元)</th>
  682. <th colspan="2">{$detail.authorize_amount}</th>
  683. {/if}
  684. {if $field.review_add_reduce_amount == 1}
  685. <th class="form-title" colspan="1">审增金额(元)</th>
  686. <th colspan="2">{$detail.review_add_amount}</th>
  687. {/if}
  688. </tr>
  689. <tr>
  690. {if $field.review_add_reduce_amount == 1}
  691. <th class="form-title" colspan="1">审减金额(元)</th>
  692. <th colspan="2">{$detail.review_reduce_amount}</th>
  693. {/if}
  694. {if $field.review_add_reduce_rate == 1}
  695. <th class="form-title" colspan="1">审增减率(%)</th>
  696. <th colspan="2">{$detail.review_add_reduce_rate}</th>
  697. {/if}
  698. {if $field.sent_review_cost == 1}
  699. <th class="form-title" colspan="1">送审服务费 (元)</th>
  700. <th colspan="2">{$detail.sent_review_cost}</th>
  701. {/if}
  702. </tr>
  703. <tr>
  704. {if $field.sent_review_approver_amount == 1}
  705. <th class="form-title forright" colspan="1">
  706. 送审单位承担审核费(元)
  707. </th>
  708. <th colspan="2"><input type="text" lay-verify="required" lay-reqText="请完善送审单位承担审核费" name="sent_review_approver_amount" value="{$detail.sent_review_approver_amount}" autocomplete="off" placeholder="请输入送审单位承担审核费" {if $field_edit.sent_review_amount_edit !=1} readonly {/if} class="layui-input">
  709. </th>
  710. {/if}
  711. {if $field.construction_approver_amount == 1}
  712. <th class="form-title forright" colspan="2">
  713. 施工单位负责核减超5%评审费部分(元)
  714. </th>
  715. <th colspan="2"><input type="text" lay-verify="required" lay-reqText="请完善施工单位负责核减超5%评审费部分" name="construction_approver_amount" value="{$detail.construction_approver_amount}" autocomplete="off" placeholder="请输入施工单位负责核减超5%评审费部分" {if $field_edit.construction_approver_amount_edit != 1} readonly {/if} class="layui-input">
  716. </th>
  717. {/if}
  718. {if $field.report_time == 1}
  719. <th class="form-title" colspan="1">报告时间</th>
  720. <th colspan="1" style="text-align: left; padding-left: 3.5vw;">{if
  721. $detail.report_time!=0}{$detail.report_time|date="Y-m-d"}{/if}
  722. </th>
  723. {/if}
  724. </tr>
  725. {/if}
  726. <tr>
  727. <th colspan="9" class="forleft">相关附件
  728. <!--<button class="layui-btn layui-btn-xs layui-btn-danger" style="float: right;" type="button"-->
  729. <!-- id="uploadBtn">上传附件-->
  730. <!--</button>-->
  731. <!--<button type="button" class="layui-btn layui-btn-xs layui-btn-danger" lay-on="page" style="float: right;">上传附件</button>-->
  732. <button type="button" class="layui-btn layui-btn-xs layui-btn-danger" lay-on="test-iframe-handle" style="float: right;">
  733. 上传附件
  734. <span id="ID-test-iframe-mark"></span>
  735. </button>
  736. </th>
  737. </tr>
  738. <tr>
  739. <th colspan="9" class="fujianimg" style="padding: 0px 0px;">
  740. <div id="filesBox2">
  741. <table class="layui-hide" id="get_file" lay-filter="get_file"></table>
  742. </div>
  743. </th>
  744. </tr>
  745. </table>
  746. <div class="py-3">
  747. <input type="hidden" name="id" value="{$detail.id}"/>
  748. <button class="layui-btn layui-btn-normal" lay-submit="" lay-filter="savetime">保存</button>
  749. </div>
  750. </form>
  751. {/if}
  752. <script>
  753. function first(){
  754. var form = layui.form, tool = layui.tool, oaTool = layui.oaTool;
  755. let table = layui.table;
  756. //附件表格
  757. var allcount;
  758. parent.layui.get_fileTable = table.render({
  759. elem: '#get_file',
  760. title: '文档列表',
  761. toolbar: '#toolbarget_file',
  762. cellMinWidth: 80,
  763. parseData: function (res) { // 数据解析回调函数
  764. // 在这里可以获取数据总数
  765. allcount = res.data.length;
  766. return {
  767. code: res.code, // 数据状态码
  768. msg: res.msg, // 状态信息
  769. count: res.count, // 数据总数
  770. data: res.data // 当前页数据
  771. };
  772. },
  773. // className: 'layui-table-testcss', // 用于给表格主容器追加 css 类名
  774. // lineStyle: 'height: 151px;', // 定义表格的多行样式
  775. url: "/admin/project.api/get_file",
  776. where: {'id': project_id},
  777. page: true, //开启分页
  778. limit: 20,
  779. cols: [[
  780. {field: 'id', title: '序号', width: 80, align: 'center',
  781. templet: function (d) {
  782. //console.log(allcount,d.LAY_NUM)
  783. return allcount - (d.LAY_NUM - 1);
  784. }
  785. },
  786. {field: 'name', title: '附件名称', align: 'left',
  787. },
  788. {field: 'remark', title: '附件说明', align: 'left',
  789. },
  790. {field: 'admin_name', title: '上传人', align: 'center', width: 150},
  791. {field: 'create_time', title: '上传时间', align: 'center', width: 150,
  792. // templet:"<div>{{d.create_time}}</div>"
  793. templet:"<div>{{layui.util.toDateString(d.create_time*1000, 'yyyy-MM-dd HH:mm:ss')}}</div>"
  794. },
  795. {field: 'right', fixed: 'right', title: '操作', width: 150, align: 'center',
  796. templet: function (d) {
  797. var html = '<div class="layui-btn-group">';
  798. var btn1 = `<a href="https://view.officeapps.live.com/op/view.aspx?src=${d.filepath}" target="_blank" class="layui-btn layui-btn-xs">预览</a>`;
  799. var btn2 = `<a class="layui-btn layui-btn-xs layui-bg-blue" href="${d.filepath}" download="${d.name}" lay-event="">下载</a>`;
  800. var btn3 = `<span data-id="${d.id}" class="layui-btn layui-btn-xs layui-btn-danger file-del " >删除</span>`;
  801. return html + btn1 + btn2 + btn3 +'</div>';
  802. }
  803. }
  804. ]]
  805. });
  806. function res(){
  807. table.reload('get_file');
  808. }
  809. $('#filesBox2').on('click', '.file-del', function (e) {
  810. // console.log( $(this).attr('data-id'))
  811. let id = $(this).attr('data-id');
  812. layer.confirm('确定要删除该文件吗?请慎重', {icon: 3, title: '提示'}, function (index) {
  813. let callback = function (e) {
  814. layer.msg(e.msg);
  815. if (e.code == 0) {
  816. res()
  817. }
  818. }
  819. tool.delete("/admin/project.api/delete_file", {id: id}, callback);// 删除附件
  820. layer.close(index);
  821. // let callback = function (e) {
  822. // if(e.code==0){
  823. // $("#" + id + "").remove();
  824. // }
  825. // layer.closeAll();
  826. // layer.msg(e.msg);
  827. // }
  828. // tool.delete("/admin/project.api/delete_file", {id: id}, callback); // 删除附件
  829. });
  830. })
  831. //上传附件弹出窗
  832. layui.use(function(){
  833. var $ = layui.$;
  834. var layer = layui.layer;
  835. var upload = layui.upload;
  836. var util = layui.util;
  837. // 事件
  838. util.on('lay-on', {
  839. 'test-iframe-handle': function(){
  840. layer.open({
  841. type: 2,
  842. area: ['680px', '520px'],
  843. content: 'ceshi?id={$detail.id}',
  844. fixed: false, // 不固定
  845. maxmin: true,
  846. shadeClose: true,
  847. title: '上传附件',
  848. btnAlign: 'c',
  849. yes: function(index, layero){
  850. // 获取 iframe 的窗口对象
  851. var iframeWin = window[layero.find('iframe')[0]['name']];
  852. var elemMark = iframeWin.$('#mark'); // 获得 iframe 中某个输入框元素
  853. var value = elemMark.val();
  854. if($.trim(value) === '') return elemMark.focus();
  855. // 显示获得的值
  856. layer.msg('获得 iframe 中的输入框标记值:'+ value);
  857. }
  858. });
  859. },
  860. })
  861. });
  862. oaTool.addFile({
  863. type: 1,
  864. isSave: true,
  865. ajaxSave: function (res) {
  866. let callback = function (e) {
  867. if("msg" in e){
  868. layer.msg(e.msg);
  869. }else{
  870. layer.msg('上传成功!')
  871. }
  872. setTimeout(function () {
  873. $("#filesBox2").load(location.href+" #filesBox>*","type=2")
  874. }, 500)
  875. }
  876. // console.log(1);
  877. // console.log(res,"{$detail.id}")
  878. tool.post("/admin/project.api/add_file", { // 上传附件
  879. 'topic_id': "{$detail.id}",
  880. 'file_id': res.data.id,
  881. 'file_name': res.data.name,
  882. 'module': 'project'
  883. }, callback);
  884. }
  885. });
  886. // var form = layui.form, tool = layui.tool, oaTool = layui.oaTool;
  887. //日期选择
  888. layui.laydate.render({
  889. elem: '#date',
  890. range: ['#start_time', '#end_time'],
  891. rangeLinked: true
  892. });
  893. let reviewtest;
  894. $('.customer-picker').on('click', function () {
  895. let that = $(this);
  896. let callback = function (data) {
  897. // $('[name="review_unit"]').val(data.id);
  898. // $('[name="review_head"]').val(data.nickname);
  899. // $('[name="review_unit_name"]').val(data.title);
  900. // $('[name="review_head_phone"]').val(data.mobile);
  901. // getemployeelist(data.id,false)
  902. $('[name="review_unit"]').val(data.id);
  903. $('[name="review_unit_name"]').val(data.title);
  904. $('[name="review_head_phone"]').val(data.mobile);
  905. }
  906. oaTool.customerPicker(callback);
  907. });
  908. let a = 1;
  909. //监听提交
  910. form.on('submit(webform)', function (data) {
  911. if(a){
  912. let callback = function (e) {
  913. a = 1
  914. layer.msg(e.msg);
  915. if (e.code == 0) {
  916. tool.sideClose(1000);
  917. }
  918. }
  919. if(data.field.engineering_type1!==""&&data.field.engineering_type2!==""){
  920. var engineering_type1 ='';
  921. if(data.field.engineering_type1==1){
  922. engineering_type1 ='预算';
  923. }else if(data.field.engineering_type1==2){
  924. engineering_type1 ='结算';
  925. }else if(data.field.engineering_type1==3){
  926. engineering_type1 ='概算';
  927. }else if(data.field.engineering_type1==4){
  928. engineering_type1 ='决算';
  929. }else if(data.field.engineering_type1==5){
  930. engineering_type1 ='工程总承包(EPC)';
  931. }
  932. var engineering_type2 = '';
  933. if(data.field.engineering_type2==1){
  934. engineering_type2 ='审核';
  935. }else if(data.field.engineering_type2==2) {
  936. engineering_type2 = '编制';
  937. }
  938. if(engineering_type1!==""&&engineering_type2!==""){
  939. data.field.engineering_type = engineering_type1 + "-" + engineering_type2;
  940. }
  941. }
  942. tool.post("/admin/project.cost/edit", data.field, callback);
  943. }
  944. a = 0
  945. return false;
  946. });
  947. let a1 = 1;
  948. form.on('submit(save)', function (data) {
  949. if(a1){
  950. let callback = function (e) {
  951. a1 = 1
  952. layer.msg(e.msg);
  953. if (e.code == 0) {
  954. tool.sideClose(1000);
  955. }
  956. }
  957. if(data.field.engineering_type1!==""&&data.field.engineering_type2!==""){
  958. var engineering_type1 ='';
  959. if(data.field.engineering_type1==1){
  960. engineering_type1 ='预算';
  961. }else if(data.field.engineering_type1==2){
  962. engineering_type1 ='结算';
  963. }else if(data.field.engineering_type1==3){
  964. engineering_type1 ='概算';
  965. }else if(data.field.engineering_type1==4){
  966. engineering_type1 ='决算';
  967. }else if(data.field.engineering_type1==5){
  968. engineering_type1 ='工程总承包(EPC)';
  969. }
  970. var engineering_type2 = '';
  971. if(data.field.engineering_type2==1){
  972. engineering_type2 ='审核';
  973. }else if(data.field.engineering_type2==2) {
  974. engineering_type2 = '编制';
  975. }
  976. if(engineering_type1!==""&&engineering_type2!==""){
  977. data.field.engineering_type = engineering_type1 + "-" + engineering_type2;
  978. }
  979. }
  980. tool.post("/admin/project.cost/save", data.field, callback);
  981. }
  982. a1 = 0
  983. return false;
  984. });
  985. let a2 = 1;
  986. form.on('submit(withdraw)', function (data) {
  987. if(a2){
  988. let callback = function (e) {
  989. a2 = 1
  990. layer.msg(e.msg);
  991. if (e.code == 0) {
  992. tool.sideClose(1000);
  993. }
  994. }
  995. if(data.field.engineering_type1!==""&&data.field.engineering_type2!==""){
  996. var engineering_type1 ='';
  997. if(data.field.engineering_type1==1){
  998. engineering_type1 ='预算';
  999. }else if(data.field.engineering_type1==2){
  1000. engineering_type1 ='结算';
  1001. }else if(data.field.engineering_type1==3){
  1002. engineering_type1 ='概算';
  1003. }else if(data.field.engineering_type1==4){
  1004. engineering_type1 ='决算';
  1005. }else if(data.field.engineering_type1==5){
  1006. engineering_type1 ='工程总承包(EPC)';
  1007. }
  1008. var engineering_type2 = '';
  1009. if(data.field.engineering_type2==1){
  1010. engineering_type2 ='审核';
  1011. }else if(data.field.engineering_type2==2) {
  1012. engineering_type2 = '编制';
  1013. }
  1014. if(engineering_type1!==""&&engineering_type2!==""){
  1015. data.field.engineering_type = engineering_type1 + "-" + engineering_type2;
  1016. }
  1017. }
  1018. tool.post("/admin/project.cost/withdraw", data.field, callback);
  1019. }
  1020. a2 = 0
  1021. return false;
  1022. });
  1023. let a3 = 1;
  1024. form.on('submit(savetime)', function (data) {
  1025. if(a3){
  1026. let callback = function (e) {
  1027. a3 = 1
  1028. layer.msg(e.msg);
  1029. if (e.code == 0) {
  1030. tool.sideClose(1000);
  1031. }
  1032. }
  1033. if(data.field.engineering_type1!==""&&data.field.engineering_type2!==""){
  1034. var engineering_type1 ='';
  1035. if(data.field.engineering_type1==1){
  1036. engineering_type1 ='预算';
  1037. }else if(data.field.engineering_type1==2){
  1038. engineering_type1 ='结算';
  1039. }else if(data.field.engineering_type1==3){
  1040. engineering_type1 ='概算';
  1041. }else if(data.field.engineering_type1==4){
  1042. engineering_type1 ='决算';
  1043. }else if(data.field.engineering_type1==5){
  1044. engineering_type1 ='工程总承包(EPC)';
  1045. }
  1046. var engineering_type2 = '';
  1047. if(data.field.engineering_type2==1){
  1048. engineering_type2 ='审核';
  1049. }else if(data.field.engineering_type2==2) {
  1050. engineering_type2 = '编制';
  1051. }
  1052. if(engineering_type1!==""&&engineering_type2!==""){
  1053. data.field.engineering_type = engineering_type1 + "-" + engineering_type2;
  1054. }
  1055. }
  1056. tool.post("/admin/project.cost/edit", data.field, callback);
  1057. }
  1058. a3 = 0
  1059. return false;
  1060. });
  1061. }
  1062. </script>
  1063. <script>
  1064. // 获取具有指定 ID 的 <ul> 元素
  1065. var ulElement = document.getElementById("filesBox");
  1066. // 检查 <ul> 元素的子元素数量
  1067. if (ulElement.children.length === 0) {
  1068. // 如果子元素数量为 0,隐藏 <ul> 元素
  1069. ulElement.style.display = "none";
  1070. }
  1071. </script>