Эх сурвалжийг харах

refactor(saleOrder): 将clientEnvironmentId提取为计算属性

liujt 4 сар өмнө
parent
commit
fc7ed0c969

+ 5 - 2
src/views/saleManage/saleOrder/components/addDialog.vue

@@ -816,6 +816,9 @@
     },
     computed: {
       ...mapGetters(['user']),
+      clientEnvironmentId() {
+        return this.$store.state.user.info.clientEnvironmentId;
+      },
       rules() {
         let isRequired = this.isRequired;
         return {
@@ -1547,8 +1550,8 @@
       async open(type, row, contactCategoryId) {
         this.businessId = '';
         this.title = type === 'add' ? '新增' : '修改';
-        this.clientEnvironmentId =
-          this.$store.state.user.info.clientEnvironmentId;
+        // this.clientEnvironmentId =
+        //   this.$store.state.user.info.clientEnvironmentId;
         this.row = row;
         if (this.enterprisePage.length == 0) {
           await this.getEnterprisePage();