99c71f494f7dcd96eeb534e22568cf9f1ff5faed.svn-base 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373
  1. <template>
  2. <div id="shuikutianbaoId">
  3. <el-dialog
  4. :title="currentObjectName+'督查填报'"
  5. :before-close="closeDialog"
  6. :visible.sync="dialogFormVisible"
  7. width='70%'
  8. >
  9. <el-container>
  10. <!-- <el-container> -->
  11. <el-main id="dxdcListMain" style="padding:5px 20px;">
  12. <!-- <el-button
  13. type="primary"
  14. style="margin-bottom: 10px;position: relative;margin-left: 90%;"
  15. @click="appearDialog()"
  16. >添加问题</el-button> -->
  17. <problem-dialog
  18. v-if="dialogShow"
  19. :objType="0"
  20. :villType="0"
  21. :objId="currentObjectId"
  22. :objName="currentObjectName"
  23. :problemMiddleType="'小水库'"
  24. :problemSmallType="problemSmallType"
  25. @closeDialog="closePDialog"
  26. :currentObjectRgstrId="currentObjectRgstrId"
  27. ></problem-dialog>
  28. <el-tabs v-model="currentViewId" type="card" @tab-click="handleClickTabs">
  29. <el-tab-pane
  30. :label="option.label"
  31. :name="option.label"
  32. v-for="option in option"
  33. :key="option.value"
  34. >
  35. <component
  36. :is="option.value"
  37. :currentObjectEngScale="currentObjectEngScale"
  38. :currentObjectRgstrId="currentObjectRgstrId"
  39. :currentGroupId="currentGroupId"
  40. :currentAdcode="currentAdcode"
  41. :currentObjectName="currentObjectName"
  42. :currentResCode="currentResCode"
  43. :currentObjectId="currentObjectId"
  44. :gdX="gdX"
  45. :gdY="gdY"
  46. :ifView="ifView"
  47. :currentRsvrNm="currentRsvrNm"
  48. :szRuls="szRuls"
  49. :openType="openType"
  50. :showOrEdit="showOrEdit"
  51. :activedName="activedName"
  52. @cancelHandler="cancelHandler"
  53. @addShuiKuSuccess="addShuiKuSuccess"
  54. ></component>
  55. </el-tab-pane>
  56. </el-tabs>
  57. </el-main>
  58. <!-- </el-container> -->
  59. </el-container>
  60. <!-- <span slot="footer" class="dialog-footer" style="justify-content: flex-end;display: flex;margin-right: 20px;">
  61. <el-button @click="closeHandler">关 闭</el-button>
  62. <el-button type="primary" @click="submitHandler">提 交</el-button>
  63. </span>-->
  64. <!-- 添加/编辑人员弹窗 -->
  65. </el-dialog>
  66. </div>
  67. </template>
  68. <script>
  69. import request from "../../utils/gw_ajax_request.js";
  70. import Sztb_Aqglqk from "../duChaRenYuan/Sztb_Aqglqk.vue";
  71. import Sztb_RcglAndyh from "../duChaRenYuan/Sztb_RcglAndyh.vue";
  72. import Sztb_BaseInfo from "../duChaRenYuan/Sztb_BaseInfo.vue";
  73. import Sztb_Glzrtx from "../zonghexinxi/Sztb_Glzrtx.vue";
  74. import Sztb_Gcstqk from "../duChaRenYuan/Sztb_Gcstqk.vue";
  75. import Sztb_Aqztpj from "../duChaRenYuan/Sztb_Aqztpj.vue";
  76. import Sztb_Wtqd from "../duChaRenYuan/Sztb_Wtqd.vue";
  77. import problemDialog from "../duChaWenTi/problemDialog.vue";
  78. import {getrgstrIdObject} from "../../api/duChaTianBao.js";
  79. // 2020新水闸督查填报
  80. import Sztb_BasicSituation from "./shuizha/Sztb_basicSituation.vue";
  81. import Sztb_AqglqkNew from "./shuizha/Sztb_AqglqkNew.vue";
  82. import Sztb_RcglAndyhNew from "./shuizha/Sztb_RcglAndyhNew.vue";
  83. import Sztb_GlzrtxNew from "./shuizha/Sztb_GlzrtxNew.vue";
  84. import Sztb_GcstqkNew from "./shuizha/Sztb_GcstqkNew.vue";
  85. import pblmReCheck from "./shuizha/pblmReCheck.vue";
  86. import pblmConfirmShett from "../duChaDuiXiang/pblmConfirmShett"
  87. export default {
  88. components: {
  89. Sztb_Aqglqk: Sztb_Aqglqk,
  90. Sztb_RcglAndyh: Sztb_RcglAndyh,
  91. Sztb_BaseInfo: Sztb_BaseInfo,
  92. Sztb_Glzrtx: Sztb_Glzrtx,
  93. Sztb_Gcstqk: Sztb_Gcstqk,
  94. Sztb_Aqztpj: Sztb_Aqztpj,
  95. Sztb_Wtqd: Sztb_Wtqd,
  96. problemDialog: problemDialog,
  97. // 2020新水闸填报
  98. Sztb_BasicSituation,
  99. Sztb_AqglqkNew,
  100. Sztb_RcglAndyhNew,
  101. Sztb_GlzrtxNew,
  102. Sztb_GcstqkNew,
  103. pblmReCheck,
  104. pblmConfirmShett
  105. },
  106. props: [
  107. "rowData",
  108. "currentObjectRgstrId",
  109. "currentGroupId",
  110. "currentAdcode",
  111. "currentResCode",
  112. "currentObjectId",
  113. "currentObjectName",
  114. "currentObjectEngScale",
  115. "showOrEdit",
  116. "gdX", "gdY",
  117. "openType",
  118. "ifView",
  119. "currentRsvrNm"
  120. ],
  121. data() {
  122. return {
  123. option:[],
  124. options: [
  125. {
  126. value: "Sztb_BaseInfo",
  127. label: "基础信息纠错"
  128. },
  129. {
  130. value: "Sztb_Glzrtx",
  131. label: "管理责任体系建设和落实情况"
  132. },
  133. {
  134. value: "Sztb_Aqglqk",
  135. label: "安全管理情况"
  136. },
  137. {
  138. value: "Sztb_RcglAndyh",
  139. label: "日常管理和维修养护情况"
  140. },
  141. {
  142. value: "Sztb_Gcstqk",
  143. label: "工程实体情况"
  144. },
  145. {
  146. value: "Sztb_Wtqd",
  147. label: "问题清单"
  148. },
  149. // {
  150. // value: "Sztb_Aqztpj",
  151. // label: "工程安全整体评价"
  152. // }
  153. ],
  154. // 2020新水闸填报
  155. optionsNew: [
  156. {
  157. value: "Sztb_BaseInfo",
  158. label: "基础信息纠错"
  159. },
  160. {
  161. value: "Sztb_BasicSituation",
  162. label: "基本情况"
  163. },
  164. {
  165. value: "pblmReCheck",
  166. label: '问题整改复查情况'
  167. },
  168. // {
  169. // value: "Sztb_GlzrtxNew",
  170. // label: "管理责任体系"
  171. // },
  172. // {
  173. // value: "Sztb_AqglqkNew",
  174. // label: "安全管理情况"
  175. // },
  176. // {
  177. // value: "Sztb_RcglAndyhNew",
  178. // label: "日常管理与维护"
  179. // },
  180. // {
  181. // value: "Sztb_GcstqkNew",
  182. // label: "工程实体缺陷"
  183. // },
  184. {
  185. value: "Sztb_Wtqd",
  186. label: "问题清单"
  187. },
  188. {
  189. value: "pblmConfirmShett",
  190. label: '问题确认单'
  191. }
  192. ],
  193. options1: [
  194. {
  195. value: "Sztb_BaseInfo",
  196. label: "基础信息纠错"
  197. },
  198. {
  199. value: "Sztb_BasicSituation",
  200. label: "基本情况"
  201. }
  202. ],
  203. value: "",
  204. dialogShow: false,
  205. currentViewId: "基础信息纠错",
  206. dialogFormVisible: true,
  207. szRuls: [],
  208. activedName: "",
  209. tableName: 'BIS_INSP_WAGA_MRS_CI'
  210. };
  211. },
  212. created() {
  213. },
  214. computed: {
  215. persId() {
  216. return localStorage.getItem("userid")
  217. ? localStorage.getItem("userid")
  218. : "1098101939614724096";
  219. },
  220. currentRlcode() {
  221. return localStorage.getItem('currentRlcode') ? localStorage.getItem('currentRlcode') : ''
  222. }
  223. },
  224. mounted() {
  225. if (this.currentRlcode.indexOf('63') == '0' || this.currentRlcode.indexOf('66') == '0') { //青海省
  226. this.option = this.options;
  227. }else{
  228. this.option = this.optionsNew;
  229. }
  230. },
  231. watch: {
  232. currentObjectEngScale(n, o) {
  233. this.currentObjectEngScale = n;
  234. }
  235. },
  236. methods: {
  237. getItemByType() {
  238. const obj = {
  239. // tname: "BIS_INSP_WAGA_MRS_CI"
  240. tname: this.tableName
  241. }
  242. request.post("/bis/insp/item/ques/info/findItemByType", obj).then(res => {
  243. console.log(res);
  244. this.szRuls = res.data;
  245. })
  246. },
  247. submitHandler() {
  248. var _self = this;
  249. getrgstrIdObject(this.rowData.code, this.rowData.objId).then(
  250. res => {
  251. if (res.data.baseStat == "0") {
  252. this.$message({
  253. message: "请填写重点环节落实情况!",
  254. type: "warning"
  255. });
  256. return;
  257. } else if (res.data.presStat == "0") {
  258. this.$message({
  259. message: "请填写责任人状态!",
  260. type: "warning"
  261. });
  262. return;
  263. } else if (res.data.resRunStat == "0") {
  264. this.$message({
  265. message: "请填写水库工程实体和运行管理情况!",
  266. type: "warning"
  267. });
  268. return;
  269. } else if (res.data.viewStat == "0") {
  270. this.$message({
  271. message: "走访用户状态!",
  272. type: "warning"
  273. });
  274. return;
  275. }
  276. this.$confirm("请确认所有信息填报完毕?", "提示", {
  277. confirmButtonText: "确定",
  278. cancelButtonText: "取消",
  279. type: "warning"
  280. })
  281. .then(() => {
  282. let formObj = {
  283. rgstrId: this.currentObjectRgstrId,
  284. state: "2"
  285. };
  286. request.post("/dc/insp/rsvrRgstr/update", formObj).then(res => {
  287. if (res.success) {
  288. _self.$emit("addShuiKuSuccess");
  289. _self.$message.success("提交成功");
  290. } else {
  291. _self.$emit("cancelHandler");
  292. }
  293. });
  294. })
  295. .catch(() => {
  296. });
  297. },
  298. err => {
  299. }
  300. );
  301. },
  302. closeHandler() {
  303. this.dialogShow = false;
  304. this.$emit("addShuiKuSuccess");
  305. },
  306. appearDialog(type) {
  307. this.dialogShow = true;
  308. // this.problemSmallType = type
  309. },
  310. closePDialog() {
  311. this.dialogShow = false;
  312. },
  313. showDialog() {
  314. this.dialogFormVisible = true;
  315. },
  316. cancelHandler() {
  317. this.$emit("cancelHandler");
  318. },
  319. addShuiKuSuccess(val) {
  320. if(val=="1"){
  321. this.option = this.options1;
  322. }
  323. if(val=="0"){
  324. this.option = this.optionsNew;
  325. }
  326. this.$emit("addShuiKuSuccess");
  327. },
  328. closeDialog() {
  329. let _self = this;
  330. this.$confirm("确认退出吗?", "提示", {
  331. confirmButtonText: "确定",
  332. cancelButtonText: "取消",
  333. type: "warning"
  334. })
  335. .then(() => {
  336. _self.$emit("cancelHandler");
  337. })
  338. .catch(() => {
  339. });
  340. },
  341. handleClickTabs(tab, event) {
  342. console.log(tab.label);
  343. this.activedName = tab.label;
  344. if (this.activedName === '管理责任体系') {
  345. this.tableName = 'BIS_INSP_WAGA_MRS_CI';
  346. } else if (this.activedName === '安全管理情况') {
  347. this.tableName = 'BIS_INSP_WAGA_SAFE_MANAGE';
  348. } else if (this.activedName === '日常管理与维护') {
  349. this.tableName = 'BIS_INSP_WAGA_DMAM_INFO';
  350. } else if (this.activedName === '工程实体缺陷') {
  351. this.tableName = 'BIS_INSP_WAGA_PROEN_INFO';
  352. }
  353. this.getItemByType()
  354. }
  355. }
  356. };
  357. </script>
  358. <style>
  359. #shuikutianbaoId .el-dialog {
  360. margin-top: 10vh;
  361. }
  362. </style>