gaoshp
2024-11-04 eef1ef0be935d4a3d8fc691b2666f41796b2d4a5
src/views/master/person/main/save.vue
@@ -68,10 +68,7 @@
            </el-col>
            <el-col :span="12">
               <el-form-item label="数据权限配置">
                  <el-select v-model="addPersonForm.deptId" multiple filterable style="width: 100%"
                     placeholder="数据权限配置" @change="deptIdChange">
                     <el-option v-for="item in deptIdList" :key="item.id" :label="item.title" :value="item.id" />
                  </el-select>
                  <el-tree-select v-model="addPersonForm.deptId" clearable multiple show-checkbox placeholder="数据权限配置" default-expand-all :data="deptIdList" :props="{ label: 'title' ,id: 'id',children: 'children'}" node-key="id" ref="deptIdTree" style="width: 100%" />
               </el-form-item>
            </el-col>
         </el-row>
@@ -168,7 +165,7 @@
         })
      },
      getOrganizationList() {
         this.$HTTP.get(`/api/blade-cps/organization/tree?groupType=group_organization&groupCategory=1`).then(res => {
         this.$HTTP.get(`/api/smis/organization/tree?groupType=group_organization&groupCategory=1`).then(res => {
            if (res.code == 200) {
               this.departmentList = res.data;
               this.addPersonForm.organizationId = res.data[0].id;
@@ -216,7 +213,7 @@
         obj.postId = obj.postId.join(",");
         this.$refs.dialogForm.validate(async (valid) => {
            if (valid) {
               this.$HTTP.post("/api/blade-cps/employee/submit", obj).then(res => {
               this.$HTTP.post("/api/smis/employee/submit", obj).then(res => {
                  if (res.code == 200) {
                     this.$emit('success', this.addPersonForm, this.mode);
                     this.visible = false;
@@ -232,7 +229,7 @@
      },
      //表单注入数据
      setData(data) {
         this.$HTTP.get(`/api/blade-cps/employee/detail/${data.id}`).then(res => {
         this.$HTTP.get(`/api/smis/employee/detail/${data.id}`).then(res => {
            if (res.code == 200) {
               if (res.data.postId) {
                  res.data.postId = res.data.postId.split(",");