9c93ddda8862d3f756a9c8c36e51c85c433ec585.svn-base 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111
  1. <!-- -->
  2. <template>
  3. <div id="popupContainer" class=''>
  4. <el-dialog :title="currentObjectName" @close="closeDialog" width="50%" :visible.sync="dialogFormVisible">
  5. <el-tabs v-model="currentViewId" type="card">
  6. <el-tab-pane
  7. :label="option.label"
  8. :name="option.label"
  9. v-for="option in options"
  10. :key="option.value">
  11. <component
  12. :is="option.value"
  13. :currentObjectRgstrId="currentObjectRgstrId"
  14. :currentObjectName="currentObjectName"
  15. :currentResCode="currentResCode"
  16. :currentObjectId="currentObjectId">
  17. </component>
  18. </el-tab-pane>
  19. </el-tabs>
  20. </el-dialog>
  21. </div>
  22. </template>
  23. <script>
  24. export default {
  25. components: {
  26. jichuxinxi:resolve => {require(['./jichuxinxi.vue'], resolve)},//基础信息
  27. // dengjixinxi:resolve => {require(['./dengjixinxi.vue'], resolve)},//登记信息
  28. zerenren:resolve => {require(['./zerenren.vue'], resolve)},//责任人
  29. gongchengshiti:resolve => {require(['./gongchengshiti.vue'], resolve)},//工程实体
  30. yunxingguanli:resolve => {require(['./yunxingguanli.vue'], resolve)},//运行管理情况
  31. problemList:resolve => {require(['./problemList.vue'], resolve)},//问题清单
  32. zrrqz:resolve => {require(['./signature.vue'], resolve)}//责任人签字
  33. },
  34. props: ["currentDuchaTpe","currentObjectRgstrId","currentResCode","currentObjectId","currentObjectName"],
  35. data() {
  36. return {
  37. currentViewId:'基础信息',
  38. dialogFormVisible:true,
  39. options:[],
  40. options_ducha: [
  41. {
  42. value: "jichuxinxi",
  43. label: "基础信息"
  44. },{
  45. value: "zerenren",
  46. label: "责任人落实情况"
  47. },{
  48. value: "gongchengshiti",
  49. label: "水库工程实体"
  50. },{
  51. value: "yunxingguanli",
  52. label: "运行管理情况"
  53. },{
  54. value: "problemList",
  55. label: '问题清单'
  56. },{
  57. value: "zrrqz",
  58. label: '责任人签字'
  59. }
  60. ],
  61. options_base: [
  62. {
  63. value: "jichuxinxi",
  64. label: "基础信息"
  65. }
  66. ],
  67. };
  68. },
  69. computed: {},
  70. watch: {},
  71. //生命周期 - 创建完成(可以访问当前this实例)
  72. created() {
  73. },
  74. //生命周期 - 挂载完成(可以访问DOM元素)
  75. mounted() {
  76. if(this.currentDuchaTpe){
  77. this.options = this.options_ducha;
  78. }else{
  79. this.options = this.options_base;
  80. }
  81. },
  82. beforeCreate() {}, //生命周期 - 创建之前
  83. beforeMount() {}, //生命周期 - 挂载之前
  84. beforeUpdate() {}, //生命周期 - 更新之前
  85. updated() {}, //生命周期 - 更新之后
  86. beforeDestroy() {}, //生命周期 - 销毁之前
  87. destroyed() {}, //生命周期 - 销毁完成
  88. activated() {}, //如果页面有keep-alive缓存功能,这个函数会触发
  89. methods: {
  90. closeDialog() {
  91. this.$emit("cancelHandler");
  92. },
  93. showDialog() {
  94. this.dialogFormVisible = true;
  95. },
  96. },
  97. }
  98. </script>
  99. <style scoped>
  100. /*@import url(); 引入公共css类*/
  101. .el-dialog__header{
  102. text-align: center !important;
  103. border-bottom: 1px dashed #C5C6C8 !important;
  104. }
  105. .el-dialog{
  106. border-radius: 4px !important;
  107. }
  108. </style>