index.vue 37 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967
  1. <!--
  2. *@description: 工程历史详情
  3. *@author: yh Fu
  4. *@date: 2024-1-8 10:04:23
  5. *@version: V1.0.5
  6. -->
  7. <template>
  8. <div style="width: 100%;height: 100%;">
  9. <el-dialog
  10. :visible.sync="dialogVisible"
  11. :title="titleName"
  12. width="60%"
  13. append-to-body
  14. custom-class="ConstructionDetailsDialog">
  15. <el-tabs type="card" v-model="activeNames" @tab-click="viewSource" class="projectTabs">
  16. <el-tab-pane
  17. :label="e.label"
  18. :name="e.value"
  19. v-for="(e,idx) in currentDicts"
  20. :key="idx"
  21. >
  22. <el-checkbox-group v-model="checkList" >
  23. <el-collapse
  24. class="rmOldPie"
  25. v-for="(e,idx) in currentCollapses"
  26. :key="idx"
  27. >
  28. <el-collapse-item :name="idx">
  29. <template slot="title">
  30. <div style="display: flex;width: 100%;height: 100%;">
  31. <!-- <div-->
  32. <!-- style="width: 15px;height: 15px;margin: auto 10px;border-radius: 73%;background-color: #a3d3ff;box-shadow: 1px 1px rgb(131 131 131 / 62%);">-->
  33. <!-- </div>-->
  34. <el-checkbox :label="e.id" @change="handleCheckedCitiesChange">
  35. <h2 style="margin-left: 1%;font-weight: 700;">{{ e.updateTime }}</h2>
  36. </el-checkbox>
  37. </div>
  38. </template>
  39. <!-- 人员信息 -->
  40. <div class="personInfo">
  41. <!-- <span>负责人:{{ e.headName }} </span>-->
  42. <!-- <span>负责人电话:{{-->
  43. <!-- e.headPhone === undefined || e.headPhone === null || e.headPhone === '' ? '无' : e.headPhone-->
  44. <!-- }}</span>-->
  45. <span>施工人:{{ e.constructUser }}</span>
  46. <span>施工人电话:{{
  47. e.constructPhone === undefined || e.constructPhone === null || e.constructPhone === '' ? '无' : e.constructPhone
  48. }}</span>
  49. </div>
  50. <hr>
  51. <!-- 用料明细 -->
  52. <div
  53. v-for="(i,index) in e.zEngineeringMaterialBo || [] "
  54. :key="index"
  55. >
  56. <el-form :model="nodeInfo" class="nodeForm materialForm">
  57. <el-form-item
  58. :prop="i.materialQuality"
  59. :class="enginType != '基建工程' && enginType != '民用工程' ? 'labelWidth' : '' "
  60. :label="activeNames == '阀管' ? '灶具管厂家': '材质'"
  61. v-show="i.materialQuality != null"
  62. label-width="95px"
  63. >
  64. <el-select v-model="i.materialQuality" placeholder="请选择材质" style="width: 100%" @change="getEnginSpecificationsList(i, index,idx)" :disabled="status == 'read-only' ">
  65. <el-option
  66. v-for="e in (activeNames == '阀管' ?materialQualityList_zjg:materialQualityList)"
  67. :key="e.id"
  68. :label="e.name"
  69. :value="e.id"
  70. ></el-option>
  71. </el-select>
  72. </el-form-item>
  73. <el-form-item
  74. :prop="i.specifications"
  75. :class="enginType != '基建工程' && enginType != '民用工程' ? 'labelWidth' : '' "
  76. label="规格"
  77. v-show="i.specifications != null"
  78. label-width="95px"
  79. >
  80. <el-select v-model="i.specifications" placeholder="请选择规格" style="width: 100%" :disabled="status == 'read-only' ">
  81. <!-- <el-option
  82. v-for="e in specificationsList"
  83. :key="e.id"
  84. :label="e.name"
  85. :value="e.id"
  86. ></el-option> -->
  87. <el-option
  88. v-for="e in corrosionLevelListAll.filter(e => e.materId == i.materialQuality)"
  89. :key="e.id"
  90. :label="e.name"
  91. :value="e.id"
  92. ></el-option>
  93. </el-select>
  94. </el-form-item>
  95. <el-form-item
  96. v-if="currentDicts.some(item=>item.label==='底腿')"
  97. :prop="i.remark + ''"
  98. :class="enginType != '基建工程' && enginType != '民用工程' ? 'labelWidth' : '' "
  99. label="施工内容"
  100. v-show="currentDicts.some(item=>item.label==='底腿')"
  101. label-width="95px"
  102. >
  103. <div class="block" style="display: inline-block; margin-right: 20px;">
  104. <el-input v-model="i.remark" placeholder="请输入施工内容" style="width: 100%" maxlength="100" type="textarea" :disabled="status == 'read-only'"></el-input>
  105. </div>
  106. </el-form-item>
  107. <el-form-item
  108. v-if="currentDicts.some(item=>item.label==='底腿')"
  109. :prop="e.constructAddre + ''"
  110. :class="enginType != '基建工程' && enginType != '民用工程' ? 'labelWidth' : '' "
  111. label="位置"
  112. v-show="currentDicts.some(item=>item.label==='底腿')"
  113. label-width="95px"
  114. >
  115. <div class="block" style="display: inline-block; margin-right: 20px;">
  116. <el-select v-model="e.constructAddre" style="width: 100%;" :disabled="status == 'read-only'">
  117. <el-option
  118. v-for="e in dict.type.construct_addre"
  119. :key="e.value"
  120. :label="e.label"
  121. :value="e.value"
  122. ></el-option>
  123. </el-select>
  124. </div>
  125. </el-form-item>
  126. <el-form-item
  127. v-if="currentDicts.some(item=>item.label==='底腿')"
  128. :prop="i.remark + ''"
  129. :class="enginType != '基建工程' && enginType != '民用工程' ? 'labelWidth' : '' "
  130. label="第"
  131. v-show="i.remark != null"
  132. label-width="95px"
  133. >
  134. <div class="block" style="display: inline-block; margin-right: 20px;">
  135. <el-input v-model="i.remark" placeholder="请输入具体位置" style="width: 90%;" maxlength="255" type="number" :disabled="status == 'read-only'"/><span style="font-weight:bold;">根</span>
  136. </div>
  137. </el-form-item>
  138. <el-form-item
  139. v-if="!currentDicts.some(item=>item.label==='底腿')"
  140. :prop="i.number + ''"
  141. :class="enginType != '基建工程' && enginType != '民用工程' ? 'labelWidth' : '' "
  142. label="数量"
  143. v-show="i.number != null"
  144. label-width="95px"
  145. >
  146. <div class="block" style="display: inline-block; margin-right: 20px;">
  147. <el-input v-model="i.number" placeholder="请输入数量" style="width: 100%" oninput="value=value.match(/\d+(\.\d{0,1})?/) ? value.match(/\d+(\.\d{0,1})?/)[0] : ''" max="999999999" :disabled="status == 'read-only'"> </el-input>
  148. </div>
  149. </el-form-item>
  150. <el-form-item
  151. :prop="i.remark + ''"
  152. :class="enginType != '基建工程' && enginType != '民用工程' ? 'labelWidth' : '' "
  153. label="描述"
  154. v-show="i.remark != null&&!currentDicts.some(item=>item.label==='底腿')"
  155. >
  156. <div class="block" style="display: inline-block; margin-right: 20px;">
  157. <el-input v-model="i.remark" placeholder="请输入描述" style="width: 100%" maxlength="100" :disabled="status == 'read-only'"></el-input>
  158. </div>
  159. </el-form-item>
  160. <el-form-item
  161. :prop="i.corrosionLevel"
  162. label="腐蚀等级"
  163. v-show="i.corrosionLevel != null"
  164. label-width="95px"
  165. >
  166. <!-- :rules="{required: true, message: '请输入材质', trigger: 'blur'}"-->
  167. <!-- <el-input v-model="item.materialQuality" placeholder="请输入材质" style="width: 100%"/>-->
  168. <el-select v-model="i.corrosionLevel" placeholder="请选择腐蚀等级" style="width: 100%" :disabled="status == 'read-only' ">
  169. <el-option
  170. v-for="e in materialQualityList"
  171. :key="e.id"
  172. :label="e.name"
  173. :value="e.id"
  174. ></el-option>
  175. </el-select>
  176. </el-form-item>
  177. <el-form-item
  178. :prop="i.visitType"
  179. label="上门类型"
  180. v-show="i.visitType != null"
  181. label-width="95px"
  182. >
  183. <!-- :rules="{required: true, message: '请输入材质', trigger: 'blur'}"-->
  184. <!-- <el-input v-model="item.materialQuality" placeholder="请输入材质" style="width: 100%"/>-->
  185. <el-select v-model="i.visitType" placeholder="请选择上门类型" style="width: 100%" :disabled="status == 'read-only' ">
  186. <el-option
  187. v-for="e in dict.type.visit_type"
  188. :key="e.value"
  189. :label="e.label"
  190. :value="e.value"
  191. ></el-option>
  192. </el-select>
  193. </el-form-item>
  194. <el-form-item
  195. :prop="i.selfClosingValveType"
  196. label="自闭阀类型"
  197. v-show="i.selfClosingValveType != null"
  198. label-width="95px"
  199. >
  200. <!-- :rules="{required: true, message: '请输入材质', trigger: 'blur'}"-->
  201. <!-- <el-input v-model="item.materialQuality" placeholder="请输入材质" style="width: 100%"/>-->
  202. <el-select v-model="i.selfClosingValveType" placeholder="请选择自闭阀类型" style="width: 100%" :disabled="status == 'read-only' ">
  203. <el-option
  204. v-for="e in materialQualityList_zbf"
  205. :key="e.id"
  206. :label="e.name"
  207. :value="e.id"
  208. ></el-option>
  209. </el-select>
  210. </el-form-item>
  211. <el-form-item
  212. :prop="i.brand"
  213. label="品牌"
  214. v-show="i.brand != null"
  215. label-width="95px"
  216. >
  217. <!-- :rules="{required: true, message: '请输入材质', trigger: 'blur'}"-->
  218. <!-- <el-input v-model="item.materialQuality" placeholder="请输入材质" style="width: 100%"/>-->
  219. <el-select v-model="i.brand" placeholder="请选择品牌" style="width: 100%" :disabled="status == 'read-only' ">
  220. <el-option
  221. v-for="e in materialQualityList"
  222. :key="e.id"
  223. :label="e.name"
  224. :value="e.id"
  225. ></el-option>
  226. </el-select>
  227. </el-form-item>
  228. </el-form>
  229. <!-- <el-input size="mini" v-if="i.brand" style="width: 80%" v-model="i.brand" placeholder="请输入品牌">
  230. <template slot="prepend">品牌</template>
  231. </el-input>
  232. <el-input v-if="i.visitType" size="mini" v-model="i.visitType" placeholder="请输入品牌">
  233. <template slot="prepend">上门类型</template>
  234. </el-input>
  235. <el-input size="mini" v-if="i.corrosionLevel" v-model="i.corrosionLevel" placeholder="请输入品牌">
  236. <template slot="prepend">腐蚀等级</template>
  237. </el-input>
  238. <el-input size="mini" v-if="i.selfClosingValveType" v-model="i.selfClosingValveType"
  239. placeholder="请输入品牌">
  240. <template slot="prepend">自闭阀类型</template>
  241. </el-input> -->
  242. </div>
  243. <!-- <el-form-item label="照片" prop="zEngiineeringPhotoBoList" class="obsImage"> -->
  244. <div style="display: flex;width: 100%;height: 100%;" v-if="!(currentDicts.some(item=>item.label==='底腿'))&&!(node==='下沟')&&!(node=='回填')">
  245. <h3 style="width: 95px;font-weight: 600;text-align: center;text-indent: 41px;">图片</h3>
  246. <ObsImageUpload
  247. :class=" status == 'read-only' ? 'obsImageUploads' : '' "
  248. ref="obsImageUpload"
  249. :limit="11"
  250. :fileType="['png', 'jpg', 'jpeg']"
  251. @input="getUrl(arguments,idx)"
  252. :value="e.zEngiineeringPhotoBoList"
  253. :disabled="status == 'read-only' "
  254. ></ObsImageUpload>
  255. </div>
  256. <div style="display: flex;width: 100%;height: 100%;" v-if="node==='下沟'">
  257. <h3 style="width: 95px;font-weight: 600;text-align: center;text-indent: 41px;">管上皮深度测量照片</h3>
  258. <ObsImageUpload
  259. :class=" status == 'read-only' ? 'obsImageUploads' : '' "
  260. ref="obsImageUpload"
  261. :limit="11"
  262. :fileType="['png', 'jpg', 'jpeg']"
  263. @input="getductalEpitheliumUrl(arguments,idx)"
  264. :value="e.ductalEpithelium"
  265. :disabled="status == 'read-only' "
  266. ></ObsImageUpload>
  267. </div>
  268. <div style="display: flex;width: 100%;height: 100%;" v-if="node==='下沟'">
  269. <h3 style="width: 95px;font-weight: 600;text-align: center;text-indent: 41px;">管沟远景照片</h3>
  270. <ObsImageUpload
  271. :class=" status == 'read-only' ? 'obsImageUploads' : '' "
  272. ref="obsImageUpload"
  273. :limit="11"
  274. :fileType="['png', 'jpg', 'jpeg']"
  275. @input="gettrenchProspectUrl(arguments,idx)"
  276. :value="e.trenchProspect"
  277. :disabled="status == 'read-only' "
  278. ></ObsImageUpload>
  279. </div>
  280. <div style="display: flex;width: 100%;height: 100%;" v-if="node==='下沟'">
  281. <h3 style="width: 95px;font-weight: 600;text-align: center;text-indent: 41px;">视频</h3>
  282. <ObsVideoUpload
  283. :class=" status == 'read-only' ? 'obsImageUploads' : '' "
  284. ref="obsImageUpload"
  285. :limit="11"
  286. :fileType="['mp4']"
  287. @input="getVideoUrl(arguments,idx)"
  288. :value="e.video"
  289. :disabled="status == 'read-only' "
  290. ></ObsVideoUpload>
  291. </div>
  292. <div style="display: flex;width: 100%;height: 100%;" v-if="node==='下沟'">
  293. <h3 style="width: 95px;font-weight: 600;text-align: center;text-indent: 41px;">管道施工记录</h3>
  294. <ObsImageUpload
  295. :class=" status == 'read-only' ? 'obsImageUploads' : '' "
  296. ref="obsImageUpload"
  297. :limit="11"
  298. :fileType="['png', 'jpg', 'jpeg']"
  299. @input="getconstructionRecordsUrl(arguments,idx)"
  300. :value="e.constructionRecords"
  301. :disabled="status == 'read-only' "
  302. ></ObsImageUpload>
  303. </div>
  304. <div style="display: flex;width: 100%;height: 100%;" v-if="node==='回填'">
  305. <h3 style="width: 95px;font-weight: 600;text-align: center;text-indent: 41px;">石粉回填照片</h3>
  306. <ObsImageUpload
  307. :class=" status == 'read-only' ? 'obsImageUploads' : '' "
  308. ref="obsImageUpload"
  309. :limit="11"
  310. :fileType="['png', 'jpg', 'jpeg']"
  311. @input="getstonePowderUrl(arguments,idx)"
  312. :value="e.stonePowder"
  313. :disabled="status == 'read-only' "
  314. ></ObsImageUpload>
  315. </div>
  316. <div style="display: flex;width: 100%;height: 100%;" v-if="node==='回填'">
  317. <h3 style="width: 95px;font-weight: 600;text-align: center;text-indent: 41px;">警示带铺设</h3>
  318. <ObsImageUpload
  319. :class=" status == 'read-only' ? 'obsImageUploads' : '' "
  320. ref="obsImageUpload"
  321. :limit="11"
  322. :fileType="['png', 'jpg', 'jpeg']"
  323. @input="getwarningtTapeUrl(arguments,idx)"
  324. :value="e.warningtTape"
  325. :disabled="status == 'read-only' "
  326. ></ObsImageUpload>
  327. </div>
  328. <div style="display: flex;width: 100%;height: 100%;" v-if="node==='回填'">
  329. <h3 style="width: 95px;font-weight: 600;text-align: center;text-indent: 41px;">回填后</h3>
  330. <ObsImageUpload
  331. :class=" status == 'read-only' ? 'obsImageUploads' : '' "
  332. ref="obsImageUpload"
  333. :limit="11"
  334. :fileType="['png', 'jpg', 'jpeg']"
  335. @input="getphotosAfterUrl(arguments,idx)"
  336. :value="e.photosAfter"
  337. :disabled="status == 'read-only' "
  338. ></ObsImageUpload>
  339. </div>
  340. <div style="display: flex;width: 100%;height: 100%;" v-if="currentDicts.some(item=>item.label==='底腿')">
  341. <h3 style="width: 95px;font-weight: 600;text-align: center;text-indent: 30px;">沟上部分</h3>
  342. <ObsImageUpload
  343. :class=" status == 'read-only' ? 'obsImageUploads' : '' "
  344. ref="obsImageUpload"
  345. :limit="11"
  346. :fileType="['png', 'jpg', 'jpeg']"
  347. @input="getonTheDitchUrl(arguments,idx)"
  348. :value="e.onTheDitch"
  349. :disabled="status == 'read-only' "
  350. ></ObsImageUpload>
  351. </div>
  352. <div style="display: flex;width: 100%;height: 100%;" v-if="currentDicts.some(item=>item.label==='底腿')">
  353. <h3 style="width: 95px;font-weight: 600;text-align: center;text-indent: 41px;">开挖前</h3>
  354. <ObsImageUpload
  355. :class=" status == 'read-only' ? 'obsImageUploads' : '' "
  356. ref="obsImageUpload"
  357. :limit="11"
  358. :fileType="['png', 'jpg', 'jpeg']"
  359. @input="getbeforeBottomUrl(arguments,idx)"
  360. :value="e.beforeBottom"
  361. :disabled="status == 'read-only' "
  362. ></ObsImageUpload>
  363. </div>
  364. <div style="display: flex;width: 100%;height: 100%;" v-if="currentDicts.some(item=>item.label==='底腿')">
  365. <h3 style="width: 95px;font-weight: 600;text-align: center;text-indent: 41px;">回填</h3>
  366. <ObsImageUpload
  367. :class=" status == 'read-only' ? 'obsImageUploads' : '' "
  368. ref="obsImageUpload"
  369. :limit="11"
  370. :fileType="['png', 'jpg', 'jpeg']"
  371. @input="getlegBackfillingUrl(arguments,idx)"
  372. :value="e.legBackfilling"
  373. :disabled="status == 'read-only' "
  374. ></ObsImageUpload>
  375. </div>
  376. <div style="display: flex;width: 100%;height: 100%;" v-if="currentDicts.some(item=>item.label==='底腿')">
  377. <h3 style="width: 95px;font-weight: 600;text-align: center;text-indent: 41px;">下沟</h3>
  378. <ObsImageUpload
  379. :class=" status == 'read-only' ? 'obsImageUploads' : '' "
  380. ref="obsImageUpload"
  381. :limit="11"
  382. :fileType="['png', 'jpg', 'jpeg']"
  383. @input="getinferiorSulcusUrl(arguments,idx)"
  384. :value="e.inferiorSulcus"
  385. :disabled="status == 'read-only' "
  386. ></ObsImageUpload>
  387. </div>
  388. <!-- </el-form-item> -->
  389. <div style="display: flex; justify-content: flex-end; width: 100%;height: 100%;">
  390. <el-button plain type="danger" @click=" handleDelete(e)" v-hasPermi="['zdsz:engineeringCivilNode:remove']" style="width: 94px;">删除</el-button>
  391. <!-- <hr>-->
  392. </div>
  393. </el-collapse-item>
  394. </el-collapse>
  395. </el-checkbox-group>
  396. </el-tab-pane>
  397. <el-button class="check" plain type="danger" @click="checkWorking" v-show="currentStatus == 'check' && isChecking " style="width: 80px;" :disabled="currentCollapses.length == 0">审核</el-button>
  398. <el-button class="check" plain type="danger" @click="updateNodeOption" style="width: 94px;cursor: pointer;" v-if="currentStatus != 'check' && status != 'read-only' ">修改</el-button>
  399. </el-tabs>
  400. </el-dialog>
  401. <!-- 审核 -->
  402. <el-dialog
  403. title="审核"
  404. :visible.sync="checkingVisible"
  405. :title="titleName"
  406. width="30%"
  407. class="checkingDialog"
  408. :before-close="handleChecking">
  409. <el-form :model="checkingInfo" ref="checking" :rules="checkingRule" class="nodeForm">
  410. <el-form-item
  411. label-width="85px"
  412. label="审核状态"
  413. prop="reviewStatus"
  414. >
  415. <el-select v-model="checkingInfo.reviewStatus" placeholder="请选择审核状态" style="width: 100%" label="审核状态" @change="validateCHanged">
  416. <el-option
  417. v-for="e in reviewStatusList"
  418. :key="e.label"
  419. :label="e.label"
  420. :value="e.value"
  421. ></el-option>
  422. </el-select>
  423. </el-form-item>
  424. <el-form-item
  425. label-width="85px"
  426. label="审核内容"
  427. prop="reviewContent"
  428. >
  429. <div class="block" style="display: inline-block; margin-right: 20px;">
  430. <el-input
  431. v-model="checkingInfo.reviewContent"
  432. placeholder="请输入审核内容"
  433. type="textarea"
  434. style="width: 97%"/>
  435. </div>
  436. </el-form-item>
  437. </el-form>
  438. <span slot="footer" class="dialog-footer">
  439. <el-button @click="handleChecking">取 消</el-button>
  440. <el-button type="primary" @click=checkingSubmit>确 定</el-button>
  441. </span>
  442. </el-dialog>
  443. </div>
  444. </template>
  445. <script>
  446. import {
  447. getEnginMaterialQualityList, // 材质
  448. getEnginSpecificationsList, // 规格
  449. getDictType, deleteinfoById, // 腐蚀程度
  450. } from '@/api/zdsz/enginee'
  451. import ObsVideoUpload from "@/components/ObsVideoUpload/index.vue";
  452. import {delEngineeringCivil} from "@/api/zdsz/engineeringCivil";
  453. export default {
  454. name: 'ConstructionDetails',
  455. dicts:[
  456. 'visit_type',
  457. 'self_closing_valve_type',
  458. 'brand',
  459. 'construct_addre'
  460. ],
  461. components:{ObsVideoUpload},
  462. props: ['currentCollapses','nodeDetailType','enginType','status','zEngineeringNodeBo'],
  463. data() {
  464. return {
  465. enginSort:'',
  466. checkList:[],
  467. enginNode:'',
  468. currentDicts: [], // 当前类型工程节点项
  469. dialogVisible: false,
  470. activeNames: '',
  471. titleName: '',
  472. reviewStatusList:[
  473. {
  474. value:'1',
  475. label:'通过'
  476. },
  477. {
  478. value:'0',
  479. label:'不通过'
  480. }
  481. ],
  482. nodesource:'',// 审核状态option
  483. materialQualityList_zbf:[], // 自闭阀option
  484. materialQualityList_zjg:[], // 灶具管option
  485. materialQualityList:[], // 材质
  486. specificationsList:[], // 规格
  487. materialComponList:[],
  488. enginType:null,
  489. enginClassification:null,
  490. nodeInfo:{
  491. backfillTime:'', // 回填时间
  492. constructTime:'',
  493. constructAccordingDrawings:'',
  494. segmentedCompressionQualified:'',
  495. zEngiineeringPhotoBoList:[], // 照片集合
  496. zEngineeringMaterialBo:[], // 用料集合
  497. remark:'',
  498. constructAddre:''
  499. },
  500. checkingInfo:{
  501. reviewStatus:'', // 审核状态
  502. reviewContent:'', // 审核内容
  503. engInfoId:'', // 节点Id
  504. createTime:'', // 工程创建时间
  505. },
  506. currentStatus:null,
  507. checkingVisible:null,
  508. isChecking:true,
  509. currentEnginId:null,
  510. reviewStatus:null,
  511. corrosionLevelListAll:[],
  512. infoIdList:[],
  513. delinfoidList:[],
  514. checkingRule:{
  515. reviewStatus: [
  516. {required: true, message: "审核状态不能为空", trigger: "blur"}
  517. ],
  518. reviewContent: [
  519. {required: true, message: "审核内容不能为空", trigger: "change"}
  520. ],
  521. },node:null
  522. }
  523. },
  524. created(){
  525. // 获取材质
  526. getEnginMaterialQualityList({enginType:this.enginType,enginStep:this.activeNames}).then(res => {
  527. console.log('材质',res)
  528. this.materialQualityList = res.data
  529. })
  530. getEnginSpecificationsList().then(res => {
  531. console.log('规格',res.data)
  532. this.corrosionLevelListAll = res.data
  533. })
  534. },
  535. mounted() {
  536. },
  537. computed:{
  538. },
  539. watch: {
  540. // 此处监听variable变量,当期有变化时执行
  541. currentDicts(item1, item2) {
  542. // item1为新值,item2为旧值
  543. console.log('item1为新值,item2为旧值', item1[0].value)
  544. this.activeNames = item1[0].value
  545. this.$parent.viewNodeSource(item1[0].value)
  546. },
  547. currentCollapses(){
  548. try {
  549. this.currentCollapses[0].zEngineeringReviewBo.reviewStatus != 1 ? this.isChecking = true : false
  550. } catch (error) {
  551. this.isChecking = true
  552. }
  553. console.log('isChecking',this.isChecking)
  554. let materialQuality = []
  555. try {
  556. materialQuality = this.currentCollapses[0].zEngineeringMaterialBo[0].materialQuality
  557. } catch (error) {
  558. materialQuality = []
  559. }
  560. try {
  561. this.reviewStatus = this.currentCollapses[0].zEngineeringReviewBo.reviewStatus != '1' ? true : false
  562. } catch (error) {
  563. this.reviewStatus = true
  564. }
  565. if(materialQuality){
  566. getEnginSpecificationsList({materId:materialQuality}).then(res => {
  567. console.log('规格',res.data)
  568. this.specificationsList = res.data
  569. })
  570. }
  571. }
  572. },
  573. methods: {
  574. handleCheckedCitiesChange(e)
  575. {
  576. this.delinfoidList=this.currentCollapses.map(item=>item.id).filter(item=>this.checkList.indexOf(item)==-1)
  577. },
  578. validateCHanged(e){
  579. this.reviewStatusList[e].label == '通过' ? this.checkingRule.reviewContent[0].required = true : this.checkingRule.reviewContent[0].required = false
  580. },
  581. handleChecking(){
  582. this.checkingVisible = false
  583. this.checkingInfo = {
  584. reviewStatus:'', // 审核状态
  585. reviewContent:'', // 审核内容
  586. engInfoId:'', // 节点Id
  587. createTime:'', // 工程创建时间
  588. },
  589. this.$refs.checking.resetFields()
  590. },
  591. getSpecificationsList(id){
  592. getEnginSpecificationsList({materId:id}).then(res => {
  593. console.log('________a',res.data)
  594. return res.data
  595. })
  596. },
  597. // 保存节点Id
  598. setEngineId(e){
  599. this.currentEnginId = e
  600. },
  601. // 提交审核
  602. checkingSubmit(){
  603. this.$confirm('此操作将删除其他施工信息, 是否继续?', '提示', {
  604. confirmButtonText: '确定',
  605. cancelButtonText: '取消',
  606. type: 'warning'
  607. }).then(() => {
  608. this.shenhe()
  609. }).catch(() => {
  610. // this.$message({
  611. // type: 'info',
  612. // message: '已取消删除'
  613. // });
  614. });
  615. },
  616. shenhe()
  617. {
  618. this.$refs.checking.validate(valid => {
  619. if(valid){
  620. try {
  621. this.checkingInfo.engInfoId = this.currentEnginId
  622. this.checkingInfo.delInfoIdList=this.delinfoidList
  623. this.$emit('checkWorking',this.checkingInfo)
  624. } catch (error) {
  625. this.checkingInfo.engInfoId = null
  626. }
  627. // this.dialogVisible = false
  628. this.checkingVisible = false
  629. this.checkingInfo = {
  630. reviewStatus:'', // 审核状态
  631. reviewContent:'', // 审核内容
  632. engInfoId:'', // 节点Id
  633. createTime:'', // 工程创建时间
  634. }
  635. } else {
  636. this.$message({
  637. message: '请完善信息',
  638. type: 'error'
  639. });
  640. throw 'valid Failed'
  641. }
  642. })
  643. },
  644. // 查看单节点历史
  645. viewSource(e) {
  646. console.log('节点',e)
  647. this.node=e.name
  648. this.nodesource=e
  649. let data = {enginType:this.enginType}
  650. data.enginSort = this.enginSort
  651. data.enginStep = this.node
  652. data.enginNode = this.enginClassification
  653. if(this.node == '阀管'){
  654. data.nameType = "自闭阀厂家";
  655. getEnginMaterialQualityList(data).then(res => {
  656. this.materialQualityList_zbf = res.data
  657. })
  658. data.nameType = "灶具管厂家";
  659. getEnginMaterialQualityList(data).then(res => {
  660. this.materialQualityList_zjg = res.data
  661. })
  662. }
  663. getEnginMaterialQualityList(data).then(res => {
  664. this.materialQualityList = res.data
  665. })
  666. this.$parent.viewNodeSource(e.name)
  667. },
  668. // 单项审核
  669. checkWorking() {
  670. if (this.checkList.length==0)
  671. {
  672. this.$message.warning("请选择需要审核通过的施工信息")
  673. return
  674. }
  675. if(this.currentStatus == 'check'){
  676. this.checkingVisible = true
  677. }
  678. },
  679. updateNodeOption(){
  680. console.log(this.activeNames)
  681. console.log('最新面板',this.currentCollapses)
  682. this.$emit('updateNodeOption',this.currentCollapses)
  683. },
  684. deleteById(e)
  685. {
  686. console.log(e)
  687. deleteinfoById(e).then(res=>{
  688. this.viewSource(this.nodesource)
  689. })
  690. },
  691. handleDelete(row) {
  692. this.$modal.confirm('是否确认删除所选数据项?').then(() => {
  693. this.loading = true;
  694. return this.deleteById(row)
  695. }).then(() => {
  696. this.loading = false;
  697. this.getList();
  698. this.$modal.msgSuccess("删除成功");
  699. }).catch(() => {
  700. }).finally(() => {
  701. this.loading = false;
  702. });
  703. },
  704. /**
  705. * 查看历史
  706. * @param dicts 节点集合
  707. * @param type 字典type
  708. * @param currentStatus 审核状态
  709. * @param kind 工程类型(基建工程用)
  710. * @param title 标题
  711. * @param enginClassification 工程类型(民用工程用)
  712. * @param enginSort 工程分类
  713. * @param enginType 工程大类名称
  714. */
  715. open(dicts, type = null,currentStatus = null,kind = null,title= null,enginClassification,enginSort,enginType) {
  716. // if (kind=='民用'||kind=='基建'){
  717. this.enginType=enginType
  718. this.enginSort=enginSort
  719. this.enginClassification=enginClassification
  720. let data = {enginType:enginType}
  721. data.enginSort = enginSort
  722. data.enginNode = enginClassification
  723. data.enginStep = Array.isArray(dicts) ? dicts[0].value: null;
  724. getEnginMaterialQualityList(data).then(res => {
  725. this.materialQualityList = res.data
  726. })
  727. if(this.node == '阀管'){
  728. data.nameType = "自闭阀厂家";
  729. getEnginMaterialQualityList(data).then(res => {
  730. this.materialQualityList_zbf = res.data
  731. })
  732. data.nameType = "灶具管厂家";
  733. getEnginMaterialQualityList(data).then(res => {
  734. this.materialQualityList_zjg = res.data
  735. })
  736. }
  737. // }
  738. this.currentStatus = currentStatus
  739. this.titleName = title
  740. this.checkingVisible = false
  741. console.log(this.reviewStatus,this.currentStatus,this.isChecking)
  742. if (type == '1' || type == '2') {
  743. // 工业 市政
  744. this.$parent.viewNodeSource()
  745. this.currentDicts = [
  746. {
  747. value: "历史数据",
  748. label: "历史数据"
  749. }
  750. ]
  751. } else if (type === '危险作业工程') {
  752. this.$parent.viewNodeSource()
  753. this.currentDicts = [
  754. {
  755. value: "历史数据",
  756. label: "历史数据"
  757. }
  758. ]
  759. } else {
  760. console.log(dicts)
  761. this.dialogVisible = true
  762. if (type=='check'&&kind=='基建'){
  763. dicts=dicts.filter(item=>['水电施工','防水'].includes(item.value))
  764. }
  765. this.currentDicts = dicts
  766. }
  767. //this.currentDicts = dicts
  768. console.log("this.currentDicts",this.currentDicts)
  769. this.dialogVisible = true
  770. this.$forceUpdate()
  771. },
  772. // 获取材质规格
  773. getEnginSpecificationsList(e,idx,parentIndex){
  774. // 重置规格
  775. this.currentCollapses[parentIndex].zEngineeringMaterialBo[idx].specifications = ''
  776. getEnginSpecificationsList({materId:e.materialQuality}).then(res => {
  777. console.log('规格',res.data)
  778. this.specificationsList = res.data
  779. })
  780. },
  781. getUrl(_,idx) {
  782. this.currentCollapses[idx].zEngiineeringPhotoBoList = [...arguments][0][0].map(e=>e.url) || [];
  783. },
  784. getductalEpitheliumUrl(_,idx) {
  785. this.currentCollapses[idx].ductalEpithelium = [...arguments][0][0].map(e=>e.url) || [];
  786. },
  787. gettrenchProspectUrl(_,idx) {
  788. this.currentCollapses[idx].trenchProspect = [...arguments][0][0].map(e=>e.url) || [];
  789. },
  790. getstonePowderUrl(_,idx) {
  791. this.currentCollapses[idx].stonePowder = [...arguments][0][0].map(e=>e.url) || [];
  792. },
  793. getwarningtTapeUrl(_,idx) {
  794. this.currentCollapses[idx].warningtTape = [...arguments][0][0].map(e=>e.url) || [];
  795. },
  796. getbeforeBottomUrl(_,idx) {
  797. this.currentCollapses[idx].beforeBottom = [...arguments][0][0].map(e=>e.url) || [];
  798. },
  799. getlegBackfillingUrl(_,idx) {
  800. this.currentCollapses[idx].legBackfilling = [...arguments][0][0].map(e=>e.url) || [];
  801. },
  802. getinferiorSulcusUrl(_,idx) {
  803. this.currentCollapses[idx].inferiorSulcus = [...arguments][0][0].map(e=>e.url) || [];
  804. },
  805. getphotosAfterUrl(_,idx) {
  806. this.currentCollapses[idx].photosAfter = [...arguments][0][0].map(e=>e.url) || [];
  807. },
  808. getVideoUrl(_,idx) {
  809. this.currentCollapses[idx].video = [...arguments][0][0].map(e=>e.url) || [];
  810. console.log(this.currentCollapses[idx].video)
  811. },
  812. getconstructionRecordsUrl(_,idx)
  813. {
  814. this.currentCollapses[idx].constructionRecords = [...arguments][0][0].map(e=>e.url) || [];
  815. console.log(this.currentCollapses[idx].constructionRecords)
  816. },
  817. getonTheDitchUrl(_,idx)
  818. {
  819. this.currentCollapses[idx].onTheDitch = [...arguments][0][0].map(e=>e.url) || [];
  820. console.log(this.currentCollapses[idx].onTheDitch)
  821. }
  822. }
  823. }
  824. </script>
  825. <style lang="scss" scoped>
  826. ::v-deep .nodeForm{
  827. .el-form-item__content{
  828. display: flex;
  829. }
  830. }
  831. ::v-deep .materialForm{
  832. display: flex !important;
  833. flex-wrap: wrap;
  834. .el-form-item{
  835. width: 320px;
  836. }
  837. }
  838. ::v-deep .obsImageUpload{
  839. .el-upload--picture-card{
  840. display: block !important;
  841. }
  842. }
  843. ::v-deep .obsImageUpload >div{
  844. display: flex;
  845. }
  846. ::v-deep .el-dialog {
  847. height: 85%;
  848. .el-dialog__body {
  849. overflow: hidden;
  850. height: 91%;
  851. }
  852. }
  853. ::v-deep .el-upload-notShow{
  854. .el-upload--picture-card {
  855. display: none;
  856. }
  857. }
  858. ::v-deep .labelWidth{
  859. .el-form-item__label{
  860. width: 100px;
  861. }
  862. }
  863. ::v-deep .obsImageUploads{
  864. .el-upload--picture-card{
  865. display: none;
  866. }
  867. }
  868. .ConstructionDetailsDialog {
  869. position: absolute;
  870. .projectTabs {
  871. height: 100%;
  872. overflow: hidden;
  873. overflow-y: scroll;
  874. margin-top: 4%;
  875. ::v-deep .el-tabs__content {
  876. margin-top: 1%;
  877. }
  878. ::v-deep .el-tabs__nav {
  879. border: none;
  880. overflow: hidden;
  881. overflow-x: scroll;
  882. }
  883. ::v-deep .el-tabs__item {
  884. // width: 47%;
  885. border: 1px solid #a3d3ff;
  886. border-radius: 5px;
  887. }
  888. ::v-deep .el-tabs__item.is-active {
  889. background-color: #e8f4ff;
  890. color: #1890ff;
  891. }
  892. ::v-deep .el-tabs__header {
  893. position: fixed;
  894. width: 53%;
  895. border: none;
  896. top: 13%;
  897. }
  898. ::v-deep .el-collapse-item__wrap {
  899. padding: 0 4%;
  900. }
  901. .check {
  902. position: fixed;
  903. right: 22.1%;
  904. top: 13.1%;
  905. height: 4.6%;
  906. //background-color: #CC9900;
  907. //color: #fff;
  908. }
  909. }
  910. .projectTabs::-webkit-scrollbar {
  911. display: none;
  912. }
  913. ::v-deep .rmOldPie {
  914. .el-collapse-item {
  915. border: none;
  916. }
  917. }
  918. }
  919. .personInfo >span:not(:nth-child(1)){
  920. margin-left: 50px;
  921. }
  922. ::v-deep .checkingDialog{
  923. height: 50%;
  924. margin-top: 6%;
  925. .el-dialog__body{
  926. height: 72%;
  927. }
  928. .el-textarea__inner{
  929. width: 246%;
  930. height: 140px;
  931. }
  932. }
  933. </style>