aaf332f528e78cade2bb158d4f74dfc870d9b358.svn-base 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293
  1. <!-- -->
  2. <template>
  3. <div id="popupContainer" class>
  4. <el-dialog
  5. :title="dcsbTitle"
  6. @close="closeDialog"
  7. width="50%"
  8. :visible.sync="dialogFormVisible"
  9. >
  10. <el-tabs v-model="currentViewId" type="card">
  11. <el-tab-pane
  12. :label="option.label"
  13. :name="option.label"
  14. v-for="option in options"
  15. :key="option.value"
  16. >
  17. <component
  18. :is="option.value"
  19. :currentObjectId="currentObjectId"
  20. :dcsbTitle="dcsbTitle"
  21. :currentRgstectId="currentRgstectId"
  22. :currentObjectRgstrId="currentObjectRgstrId"
  23. ></component>
  24. </el-tab-pane>
  25. </el-tabs>
  26. </el-dialog>
  27. </div>
  28. </template>
  29. <script>
  30. export default {
  31. components: {
  32. duchaxinxi: resolve => {
  33. require(["./duchaxinxi.vue"], resolve);
  34. }, //基础信息
  35. problemList: resolve => {
  36. require(["./problemList.vue"], resolve);
  37. } //问题列表
  38. },
  39. props: [
  40. "currentObjectId",
  41. "currentRgstectId",
  42. "dcsbTitle",
  43. "activeName",
  44. "currentObjectRgstrId"
  45. ],
  46. data() {
  47. return {
  48. currentViewId: "督查信息",
  49. dialogFormVisible: true,
  50. options: [
  51. {
  52. value: "duchaxinxi",
  53. label: "督查信息"
  54. },
  55. {
  56. value: "problemList",
  57. label: "问题列表"
  58. }
  59. ]
  60. };
  61. },
  62. computed: {},
  63. watch: {},
  64. //生命周期 - 创建完成(可以访问当前this实例)
  65. created() {},
  66. //生命周期 - 挂载完成(可以访问DOM元素)
  67. mounted() {
  68. //页签的改变
  69. this.$nextTick(() => {
  70. this.currentViewId = this.activeName;
  71. });
  72. },
  73. beforeCreate() {}, //生命周期 - 创建之前
  74. beforeMount() {}, //生命周期 - 挂载之前
  75. beforeUpdate() {}, //生命周期 - 更新之前
  76. updated() {}, //生命周期 - 更新之后
  77. beforeDestroy() {}, //生命周期 - 销毁之前
  78. destroyed() {}, //生命周期 - 销毁完成
  79. activated() {}, //如果页面有keep-alive缓存功能,这个函数会触发
  80. methods: {
  81. closeDialog() {
  82. this.$emit("cancelHandler");
  83. },
  84. showDialog() {
  85. this.dialogFormVisible = true;
  86. }
  87. }
  88. };
  89. </script>
  90. <style scoped>
  91. /*@import url(); 引入公共css类*/
  92. </style>