2c79339d0334cdcabb6f4bb4ab095382e83d5134.svn-base 6.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209
  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-main id="dxdcListMain" style="padding:5px 20px;">
  11. <problem-dialog
  12. v-if="dialogShow"
  13. :objType="34"
  14. :objId="currentObjectId"
  15. :objName="currentObjectName"
  16. :problemMiddleType="'小水库除险加固'"
  17. :problemSmallType="problemSmallType"
  18. @closeDialog="closePDialog"
  19. :currentObjectRgstrId="currentObjectRgstrId"
  20. />
  21. <el-tabs v-model="currentViewId" type="card" @tab-click="handleClickTabs">
  22. <el-tab-pane
  23. :label="option.label"
  24. :name="option.label"
  25. v-for="option in options"
  26. :key="option.value"
  27. >
  28. <component
  29. :is="option.value"
  30. :pType="34"
  31. :currentObjectRgstrId="currentObjectRgstrId"
  32. :currentAdcode="currentAdcode"
  33. :currentObjectName="currentObjectName"
  34. :currentResCode="currentResCode"
  35. :currentObjectId="currentObjectId"
  36. :gdX="gdX"
  37. :gdY="gdY"
  38. :openType="openType"
  39. :szRuls="szRuls"
  40. :baseId="baseId"
  41. :showOrEdit="showOrEdit"
  42. :activeLabel="activedName"
  43. :baseForm="baseForm"
  44. @cancelHandler="cancelHandler"
  45. @addShuiKuSuccess="addShuiKuSuccess"
  46. />
  47. </el-tab-pane>
  48. </el-tabs>
  49. </el-main>
  50. </el-container>
  51. </el-dialog>
  52. </div>
  53. </template>
  54. <script>
  55. import request from "@util/gw_ajax_request.js";
  56. import baseInfo from "./baseInfo.vue";
  57. import zaijian from './zaijian.vue'
  58. import daishishi from './daishishi.vue'
  59. import problemList from "./problemList.vue";
  60. import problemDialog from "../../duChaWenTi/problemDialog.vue";
  61. import signature from '../../duChaRenYuan/signature.vue'
  62. export default {
  63. components: {
  64. baseInfo,
  65. problemDialog,
  66. problemList,
  67. zaijian,
  68. daishishi,
  69. signature
  70. },
  71. props: [
  72. "rowData",
  73. "currentObjectRgstrId",
  74. "currentAdcode",
  75. "currentResCode",
  76. "currentObjectId",
  77. "showOrEdit",
  78. "currentObjectName",
  79. "gdX","gdY","baseForm","baseId","openType"
  80. ],
  81. data() {
  82. return {
  83. options: [],
  84. optionsZaijian: [
  85. {
  86. value: "baseInfo",
  87. label: "基础信息纠错"
  88. },
  89. // {
  90. // value: "zaijian",
  91. // label: "在建小型水库除险加固项目抽查情况"
  92. // },
  93. {
  94. value: "problemList",
  95. label: "问题清单"
  96. },
  97. {
  98. value: "signature",
  99. label: '责任人签字'
  100. }
  101. ],
  102. optionsDaishishi: [
  103. {
  104. value: "baseInfo",
  105. label: "基础信息纠错"
  106. },
  107. // {
  108. // value: "daishishi",
  109. // label: "待实施小型水库除险加固项目抽查情况"
  110. // },
  111. {
  112. value: "problemList",
  113. label: "问题清单"
  114. },
  115. {
  116. value: "signature",
  117. label: '责任人签字'
  118. }
  119. ],
  120. value: "",
  121. dialogShow: false,
  122. currentViewId: "基础信息纠错",
  123. dialogFormVisible: true,
  124. szRuls: [],
  125. activedName:"" ,
  126. tableName:''
  127. };
  128. },
  129. created(){
  130. if(this.rowData.type == '2'){
  131. this.options = this.optionsZaijian
  132. }else{
  133. this.options = this.optionsDaishishi
  134. }
  135. },
  136. computed: {
  137. persId() {
  138. return localStorage.getItem("userid")
  139. ? localStorage.getItem("userid")
  140. : "1098101939614724096";
  141. }
  142. },
  143. mounted() {
  144. this.getPblmType();
  145. },
  146. watch: {
  147. tableName(){
  148. this.getPblmType();
  149. }
  150. },
  151. methods: {
  152. closeHandler() {
  153. this.dialogShow = false;
  154. this.$emit("addShuiKuSuccess");
  155. },
  156. appearDialog(type) {
  157. this.dialogShow = true;
  158. },
  159. closePDialog() {
  160. this.dialogShow = false;
  161. },
  162. showDialog() {
  163. this.dialogFormVisible = true;
  164. },
  165. cancelHandler() {
  166. this.$emit("cancelHandler");
  167. },
  168. addShuiKuSuccess() {
  169. this.$emit("addShuiKuSuccess");
  170. },
  171. closeDialog() {
  172. let _self = this;
  173. this.$confirm("确认退出吗?", "提示", {
  174. confirmButtonText: "确定",
  175. cancelButtonText: "取消",
  176. type: "warning"
  177. })
  178. .then(() => {
  179. _self.$emit("cancelHandler");
  180. })
  181. .catch(() => {});
  182. },
  183. handleClickTabs(tab,event){
  184. console.log(tab.label);
  185. this.activedName = tab.label;
  186. },
  187. getPblmType(){
  188. const obj ={
  189. tname: this.tableName
  190. }
  191. request.post("/bis/insp/item/ques/info/findItemByType",obj).then(res =>{
  192. console.log(res);
  193. this.szRuls = res.data;
  194. })
  195. }
  196. }
  197. };
  198. </script>
  199. <style>
  200. #shuikutianbaoId .el-dialog {
  201. margin-top: 10vh;
  202. }
  203. </style>