| | |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="部门"> |
| | | <!-- <el-select v-model="addPersonForm.organizationId" filterable style="width: 100%" placeholder="部门"> |
| | | <el-option v-for="item in organizationList" :key="item.id" :label="item.name" :value="item.id"/> |
| | | </el-select> --> |
| | | <!-- <el-tree-select |
| | | multiple |
| | | show-checkbox |
| | | default-expand-all |
| | | size="small" |
| | | @change = "organizationIdChange" |
| | | v-model="addPersonForm.organizationId" |
| | | clearable |
| | | node-key="id" |
| | | placeholder="部门" |
| | | ref="parentTree" |
| | | :data="parentData" |
| | | :props="{ label: 'title' }" |
| | | style="width:80%;" |
| | | :default-checked-keys="selectedIds" |
| | | :render-after-expand="false" /> --> |
| | | <el-tree-select @change= "parentIdChange" v-model="addPersonForm.organizationId" clearable placeholder="上级部门" default-expand-all check-on-click-nod :data="departmentList" check-strictly :props="{ label: 'name' }" node-key="id" ref="parentTree" style="width: 100%" /> |
| | | <el-tree-select @change= "parentIdChange" v-model="addPersonForm.organizationId" clearable placeholder="上级部门" default-expand-all check-on-click-nod :data="departmentList" check-strictly :props="{ label: 'name' }" node-key="id" ref="parentTree" style="width: 100%" /> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | |
| | | this.$HTTP.get(`/api/blade-cps/organization/tree?groupType=group_organization&groupCategory=1`).then(res=> { |
| | | if(res.code == 200) { |
| | | this.departmentList = res.data; |
| | | console.log(res.data[0].id) |
| | | this.addPersonForm.organizationId = res.data[0].id; |
| | | console.log(this.addPersonForm.organizationId) |
| | | } |
| | | }) |
| | | }, |