Quellcode durchsuchen

支部资源绑定显隐

slowslo vor 4 Jahren
Ursprung
Commit
44560f876c
1 geänderte Dateien mit 13 neuen und 4 gelöschten Zeilen
  1. 13 4
      src/views/party/branch.vue

+ 13 - 4
src/views/party/branch.vue

@@ -200,7 +200,7 @@
               span:24,
               span:24,
               // dicUrl: "/api/cyzh-community/residential/list?agencyId={{key}}",
               // dicUrl: "/api/cyzh-community/residential/list?agencyId={{key}}",
               // dicUrl: "/api/cyzh-community/residential/list?size=500",
               // dicUrl: "/api/cyzh-community/residential/list?size=500",
-              dicUrl: "/api/cyzh-community/residential/select?size=1000",
+              dicUrl: "/api/cyzh-community/agency/list?size=1000",
               dicFormatter:(res)=>{
               dicFormatter:(res)=>{
                 return res.data.records;//返回字典的层级结构
                 return res.data.records;//返回字典的层级结构
               },
               },
@@ -214,7 +214,7 @@
                 message: "请选择所属小区",
                 message: "请选择所属小区",
                 trigger: "blur"
                 trigger: "blur"
               }]
               }]
-            }
+            },
           ]
           ]
         },
         },
         data: []
         data: []
@@ -271,11 +271,20 @@
     watch: {
     watch: {
       'form.resourceType': {
       'form.resourceType': {
         handler(val) {
         handler(val) {
+          console.log(val,"val")
           let resourceIds = this.findObject(this.option.column, "resourceIds");
           let resourceIds = this.findObject(this.option.column, "resourceIds");
           if (val == 1) {
           if (val == 1) {
+            this.option.column[7].props.label="name"
+            resourceIds.dicUrl = `/api/cyzh-community/agency/list?size=500&name={{key}}`
+          } else if (val==2){
+            this.option.column[7].props.label="name"
+            resourceIds.dicUrl = "/api/cyzh-community/residentail/list?size=9999";
+          }else if(val==3){
+            this.option.column[7].props.label="name"
             resourceIds.dicUrl = `/api/cyzh-community/agency/list?size=500&name={{key}}`
             resourceIds.dicUrl = `/api/cyzh-community/agency/list?size=500&name={{key}}`
-          } else {
-            resourceIds.dicUrl = "/api/cyzh-community/residential/list?size=99999";
+          }else{
+            resourceIds.dicUrl = "/api/cyzh-enterprise/enterprise/list?size=500";
+            this.option.column[7].props.label="enterpriseName"
           }
           }
         }
         }
       }
       }