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

Merge remote-tracking branch 'origin/V0.0.2' into V0.0.2

jingyuanchao 2 жил өмнө
parent
commit
95727de7f9

+ 10 - 0
src/components/orgTree/index.vue

@@ -59,12 +59,22 @@ export default {
     hangsheTree:{
     hangsheTree:{
       type:Boolean,
       type:Boolean,
       default:false,
       default:false,
+    },
+    defaultProps:{
+      type:Object,
+      default:{
+        children: "children",
+        label: "name"
+      },
     }
     }
   },
   },
   watch: {
   watch: {
     // 根据名称筛选机构树
     // 根据名称筛选机构树
     deptName(val) {
     deptName(val) {
       this.$refs.tree.filter(val);
       this.$refs.tree.filter(val);
+    },
+    defaultProps(val) {
+      this.defaultProps={...val};
     }
     }
   },
   },
   created() {
   created() {

+ 1 - 1
src/views/system/dept/index.vue

@@ -381,7 +381,7 @@ export default {
       checked: false,
       checked: false,
       defaultProps: {
       defaultProps: {
         children: "children",
         children: "children",
-        label: "name",
+        label: "shortName",
       },
       },
       // 查询参数
       // 查询参数
       queryParams: {
       queryParams: {

+ 5 - 1
src/views/system/user/index.vue

@@ -4,7 +4,7 @@
       <!--机构数据-->
       <!--机构数据-->
       <el-col :span="4" :xs="24">
       <el-col :span="4" :xs="24">
         <org-tree v-model="queryParams.orgId" @defaultKey="getDefaultKey" @checkChange="checkChange"
         <org-tree v-model="queryParams.orgId" @defaultKey="getDefaultKey" @checkChange="checkChange"
-          @click="clickTreeNode"></org-tree>
+          @click="clickTreeNode" :defaultProps="defaultProps"></org-tree>
       </el-col>
       </el-col>
       <!--用户数据-->
       <!--用户数据-->
       <el-col :span="20" :xs="24">
       <el-col :span="20" :xs="24">
@@ -256,6 +256,10 @@ export default {
   mixins: [tableList],
   mixins: [tableList],
   data() {
   data() {
     return {
     return {
+      defaultProps: {
+        children: "children",
+        label: "shortName",
+      },
       // 遮罩层
       // 遮罩层
       loading: true,
       loading: true,
       // 选中数组
       // 选中数组