|
@@ -83,7 +83,7 @@ const handleEditOrganizationOrFactory = (row) => {
|
|
|
const { parentId, name: parentName, type, provinceCode, cityCode, countryCode } = row;
|
|
|
formData.value = {
|
|
|
...row,
|
|
|
- parentId: type == 0 ? 0 : parentId,
|
|
|
+ // parentId: type == 0 ? 0 : parentId,
|
|
|
parentName,
|
|
|
type,
|
|
|
title: type == 0 ? "编辑集团" : "编辑水厂",
|
|
@@ -101,9 +101,7 @@ const handleDelete = async ({ id }) => {
|
|
|
|
|
|
const initPageData = async () => {
|
|
|
tableLoading.value = true;
|
|
|
-
|
|
|
const { rows } = await getOrganizationList(queryParams.value);
|
|
|
-
|
|
|
tableData.value = rows.map(item => ({
|
|
|
...item,
|
|
|
typeText: typeEmun[item.type],
|
|
@@ -292,9 +290,12 @@ onMounted(() => {
|
|
|
<el-input v-model="formData.code" placeholder="请输入编号" clearable />
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
- <el-col :span="11" v-if="formData.type == 1" prop="parentId">
|
|
|
- <el-form-item label="上级机构" prop="parentName">
|
|
|
- <span>{{ formData.parentName }}</span>
|
|
|
+ <el-col :span="11" v-if="formData.type == 1">
|
|
|
+ <el-form-item label="上级机构" prop="parentId">
|
|
|
+ <el-select v-model="formData.parentId" placeholder="请选择状态" clearable>
|
|
|
+ <el-option :label="item.name" :value="item.id" v-for="item in tableData" :key="item.id"/>
|
|
|
+ </el-select>
|
|
|
+ <!-- <span>{{ formData.parentName }}</span> -->
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="11" prop="regionList">
|