人员选择下拉框修改

main
mo 1 year ago
parent 587ee1405b
commit d848ca8f99

@ -166,7 +166,6 @@
</el-image> </el-image>
</template> </template>
</el-table-column> </el-table-column>
<!-- <el-table-column label="条码值" align="center" prop="codeValue" /> -->
<el-table-column label="装册数量" align="center" prop="packageNum" /> <el-table-column label="装册数量" align="center" prop="packageNum" />
<el-table-column label="备注" align="center" prop="remark" /> <el-table-column label="备注" align="center" prop="remark" />
<el-table-column <el-table-column
@ -277,29 +276,26 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
<!-- <el-form-item label="状态待装册,已装册" prop="status">
<el-radio-group v-model="form.status">
<el-radio label="1">请选择字典生成</el-radio>
</el-radio-group>
</el-form-item> -->
<el-row> <el-row>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="负责人" prop="manegeName"> <el-form-item label="负责人" prop="manegeName">
<el-select <el-input
v-model="form.manegeName" v-model="form.manegeName"
filterable placeholder="请选择负责人"
placeholder="负责人" readonly
value-key="id"
@change="handleSelectUser"
>
<el-option
v-for="item in userOptions"
:key="item.id"
:value="item"
:label="item.username"
> >
</el-option> <el-button
</el-select> slot="append"
@click="handleSelectUser"
icon="el-icon-search"
style="
border-color: #46a6ff;
background-color: #46a6ff;
color: white;
"
></el-button>
</el-input>
<UserSelect ref="UserSelect" @onSelected="onUserSelected" />
</el-form-item> </el-form-item>
<el-form-item label="装册时间" prop="packageTime"> <el-form-item label="装册时间" prop="packageTime">
<el-date-picker <el-date-picker
@ -347,14 +343,13 @@ import {
exportPackagesExcel, exportPackagesExcel,
} from "@/api/archives/packages"; } from "@/api/archives/packages";
import ArchivesSelect from "@/components/ArchivesSelect/single.vue"; import ArchivesSelect from "@/components/ArchivesSelect/single.vue";
import { listUser } from "@/api/system/user"; import UserSelect from "@/components/UserSelect/single.vue";
export default { export default {
name: "Packages", name: "Packages",
components: { ArchivesSelect }, components: { ArchivesSelect, UserSelect },
data() { data() {
return { return {
userOptions: [], //
// //
loading: true, loading: true,
// //
@ -407,18 +402,8 @@ export default {
}, },
created() { created() {
this.getList(); this.getList();
this.getUserList();
}, },
methods: { methods: {
//
getUserList() {
listUser().then((response) => {
this.userOptions = response.data.list;
});
},
handleSelectUser(val) {
this.form.manegeName = val.username;
},
/** 查询列表 */ /** 查询列表 */
getList() { getList() {
this.loading = true; this.loading = true;
@ -566,6 +551,17 @@ export default {
this.form.flowId = obj.flowId; this.form.flowId = obj.flowId;
} }
}, },
//
handleSelectUser() {
this.$refs.UserSelect.showFlag = true;
},
//
onUserSelected(obj) {
console.log(obj);
if (obj != undefined && obj != null) {
this.form.manegeName = obj.username;
}
},
}, },
}; };
</script> </script>

@ -253,40 +253,44 @@
<el-row> <el-row>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="移交人" prop="outputName"> <el-form-item label="移交人" prop="outputName">
<el-select <el-input
v-model="outputName" v-model="form.outputName"
filterable
placeholder="请选择移交人" placeholder="请选择移交人"
value-key="id" readonly
@change="handleSelectUser1"
>
<el-option
v-for="item in userOptions"
:key="item.id"
:value="item"
:label="item.username"
> >
</el-option> <el-button
</el-select> slot="append"
@click="handleSelectUser1"
icon="el-icon-search"
style="
border-color: #46a6ff;
background-color: #46a6ff;
color: white;
"
></el-button>
</el-input>
<UserSelect ref="UserSelect1" @onSelected="onUserSelected1" />
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="签收人" prop="inputName"> <el-form-item label="签收人" prop="inputName">
<el-select <el-input
v-model="inputName" v-model="form.inputName"
filterable
placeholder="请选择签收人" placeholder="请选择签收人"
value-key="id" readonly
@change="handleSelectUser2"
>
<el-option
v-for="item in userOptions"
:key="item.id"
:value="item"
:label="item.username"
> >
</el-option> <el-button
</el-select> slot="append"
@click="handleSelectUser2"
icon="el-icon-search"
style="
border-color: #46a6ff;
background-color: #46a6ff;
color: white;
"
></el-button>
</el-input>
<UserSelect ref="UserSelect2" @onSelected="onUserSelected2" />
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
@ -361,15 +365,14 @@ import {
getTurnOverPage, getTurnOverPage,
exportTurnOverExcel, exportTurnOverExcel,
} from "@/api/archives/turnOver"; } from "@/api/archives/turnOver";
import { getOrganizationPage } from "@/api/setting/organization";
import { listUser } from "@/api/system/user";
import { createWS } from "@/api/archives/record"; import { createWS } from "@/api/archives/record";
import { getSiteTree } from "@/api/setting/organization"; import { getSiteTree } from "@/api/setting/organization";
import FileSelect from "@/components/FileSelect/single.vue"; import FileSelect from "@/components/FileSelect/single.vue";
import UserSelect from "@/components/UserSelect/single.vue";
export default { export default {
name: "TurnOver", name: "TurnOver",
components: { FileSelect }, components: { FileSelect, UserSelect },
data() { data() {
return { return {
propName: { propName: {
@ -464,20 +467,6 @@ export default {
this.form.applyNo = response.data; this.form.applyNo = response.data;
}); });
}, },
//
getUserList() {
listUser().then((response) => {
this.userOptions = response.data.list;
});
},
handleSelectUser1(val) {
this.form.outputNameId = val.id;
this.form.outputName = val.username;
},
handleSelectUser2(val) {
this.form.inputNameId = val.id;
this.form.inputName = val.username;
},
// //
getSiteList() { getSiteList() {
getSiteTree().then((response) => { getSiteTree().then((response) => {
@ -657,6 +646,28 @@ export default {
this.createWS(obj.id); this.createWS(obj.id);
} }
}, },
//
handleSelectUser1() {
this.$refs.UserSelect1.showFlag = true;
},
//
onUserSelected1(obj) {
console.log(obj);
if (obj != undefined && obj != null) {
this.form.outputName = obj.username;
}
},
//
handleSelectUser2() {
this.$refs.UserSelect2.showFlag = true;
},
//
onUserSelected2(obj) {
console.log(obj);
if (obj != undefined && obj != null) {
this.form.inputName = obj.username;
}
},
}, },
}; };
</script> </script>

@ -104,7 +104,6 @@
<dict-tag :type="DICT_TYPE.ARCHIVES_MEDIA" :value="scope.row.media" /> <dict-tag :type="DICT_TYPE.ARCHIVES_MEDIA" :value="scope.row.media" />
</template> </template>
</el-table-column> </el-table-column>
<!-- <el-table-column label="业务实体名称" align="center" prop="company" /> -->
<el-table-column label="借阅描述" align="center" prop="describes" /> <el-table-column label="借阅描述" align="center" prop="describes" />
<el-table-column <el-table-column
label="创建日期" label="创建日期"
@ -187,19 +186,23 @@
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="借阅人" prop="userName"> <el-form-item label="借阅人" prop="userName">
<el-select <el-input
v-model="form.userName" v-model="form.userName"
filterable
placeholder="请选择借阅人" placeholder="请选择借阅人"
readonly
> >
<el-option <el-button
v-for="item in userOptions" slot="append"
:key="item.id" @click="handleSelectUser"
:value="item.username" icon="el-icon-search"
:label="item.username" style="
> border-color: #46a6ff;
</el-option> background-color: #46a6ff;
</el-select> color: white;
"
></el-button>
</el-input>
<UserSelect ref="UserSelect" @onSelected="onUserSelected" />
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
@ -300,13 +303,6 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
<!-- <el-form-item label="备注" prop="remark">
<el-input
v-model="form.remark"
type="textarea"
placeholder="请输入备注"
/>
</el-form-item> -->
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm"> </el-button> <el-button type="primary" @click="submitForm"> </el-button>
@ -326,12 +322,12 @@ import {
exportBorrowApplyExcel, exportBorrowApplyExcel,
} from "@/api/borrow/apply"; } from "@/api/borrow/apply";
import { listData } from "@/api/system/dict/data"; import { listData } from "@/api/system/dict/data";
import { listUser } from "@/api/system/user";
import { getRecordPage } from "@/api/archives/record"; import { getRecordPage } from "@/api/archives/record";
import UserSelect from "@/components/UserSelect/single.vue";
export default { export default {
name: "BorrowApply", name: "BorrowApply",
components: {}, components: { UserSelect },
data() { data() {
return { return {
// //
@ -377,7 +373,6 @@ export default {
borrowStateOptions: [], borrowStateOptions: [],
wayOptions: [], wayOptions: [],
mediaOptions: [], mediaOptions: [],
userOptions: [], //
filesNumOptions: [], // filesNumOptions: [], //
fileTypeOptions: [], // fileTypeOptions: [], //
}; };
@ -385,7 +380,6 @@ export default {
created() { created() {
this.getList(); this.getList();
this.handleInitList(); this.handleInitList();
this.getUserList();
this.getFilesNum(); this.getFilesNum();
}, },
methods: { methods: {
@ -440,12 +434,6 @@ export default {
this.fileTypeOptions = res.data.list || []; this.fileTypeOptions = res.data.list || [];
}); });
}, },
//
getUserList() {
listUser().then((response) => {
this.userOptions = response.data.list;
});
},
/** 取消按钮 */ /** 取消按钮 */
cancel() { cancel() {
this.open = false; this.open = false;
@ -571,6 +559,17 @@ export default {
}) })
.catch(() => {}); .catch(() => {});
}, },
//
handleSelectUser() {
this.$refs.UserSelect.showFlag = true;
},
//
onUserSelected(obj) {
console.log(obj);
if (obj != undefined && obj != null) {
this.form.userName = obj.username;
}
},
}, },
}; };
</script> </script>

@ -443,8 +443,24 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="处理人员 " prop="handler"> <el-form-item label="处理人" prop="handler">
<el-input v-model="form.handler" placeholder="请输入处理人员 " /> <el-input
v-model="form.handler"
placeholder="请选择处理人"
readonly
>
<el-button
slot="append"
@click="handleSelectUser"
icon="el-icon-search"
style="
border-color: #46a6ff;
background-color: #46a6ff;
color: white;
"
></el-button>
</el-input>
<UserSelect ref="UserSelect" @onSelected="onUserSelected" />
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
@ -547,6 +563,7 @@ import { listSimplePosts } from "@/api/system/post";
import Treeselect from "@riophae/vue-treeselect"; import Treeselect from "@riophae/vue-treeselect";
import "@riophae/vue-treeselect/dist/vue-treeselect.css"; import "@riophae/vue-treeselect/dist/vue-treeselect.css";
import { getAccessToken, getTenantId } from "@/utils/auth"; import { getAccessToken, getTenantId } from "@/utils/auth";
import UserSelect from "@/components/UserSelect/single.vue";
export default { export default {
name: "ElectronicConsultation", name: "ElectronicConsultation",
@ -554,6 +571,7 @@ export default {
ScrollPane, ScrollPane,
Editor, Editor,
Treeselect, Treeselect,
UserSelect,
}, },
data() { data() {
return { return {
@ -626,6 +644,7 @@ export default {
rules: {}, rules: {},
siteOptions: [], // siteOptions: [], //
siteArray: [], // siteArray: [], //
organizationList: [],
}; };
}, },
created() { created() {
@ -863,6 +882,17 @@ export default {
}) })
.catch(() => {}); .catch(() => {});
}, },
//
handleSelectUser() {
this.$refs.UserSelect.showFlag = true;
},
//
onUserSelected(obj) {
console.log(obj);
if (obj != undefined && obj != null) {
this.form.handler = obj.username;
}
},
}, },
}; };
</script> </script>

@ -452,19 +452,23 @@
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="处理人" prop="handler"> <el-form-item label="处理人" prop="handler">
<el-select <el-input
v-model="form.handler" v-model="form.handler"
filterable
placeholder="请选择处理人" placeholder="请选择处理人"
readonly
> >
<el-option <el-button
v-for="item in userOptions" slot="append"
:key="item.id" @click="handleSelectUser"
:value="item.username" icon="el-icon-search"
:label="item.username" style="
> border-color: #46a6ff;
</el-option> background-color: #46a6ff;
</el-select> color: white;
"
></el-button>
</el-input>
<UserSelect ref="UserSelect" @onSelected="onUserSelected" />
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
@ -567,12 +571,14 @@ import { listSimplePosts } from "@/api/system/post";
import Treeselect from "@riophae/vue-treeselect"; import Treeselect from "@riophae/vue-treeselect";
import "@riophae/vue-treeselect/dist/vue-treeselect.css"; import "@riophae/vue-treeselect/dist/vue-treeselect.css";
import { getAccessToken, getTenantId } from "@/utils/auth"; import { getAccessToken, getTenantId } from "@/utils/auth";
import UserSelect from "@/components/UserSelect/single.vue";
export default { export default {
name: "ElectronicCustomerComplaint", name: "ElectronicCustomerComplaint",
components: { components: {
Editor, Editor,
Treeselect, Treeselect,
UserSelect,
}, },
data() { data() {
return { return {
@ -891,6 +897,17 @@ export default {
}) })
.catch(() => {}); .catch(() => {});
}, },
//
handleSelectUser() {
this.$refs.UserSelect.showFlag = true;
},
//
onUserSelected(obj) {
console.log(obj);
if (obj != undefined && obj != null) {
this.form.handler = obj.username;
}
},
}, },
}; };
</script> </script>

@ -91,21 +91,23 @@
<el-row> <el-row>
<el-col :span="14"> <el-col :span="14">
<el-form-item label="鉴定人" prop="userName"> <el-form-item label="鉴定人" prop="userName">
<el-select <el-input
v-model="userName" v-model="form.userName"
filterable
placeholder="请选择鉴定人" placeholder="请选择鉴定人"
value-key="id" readonly
@change="handleSelectUser"
> >
<el-option <el-button
v-for="item in userOptions" slot="append"
:key="item.id" @click="handleSelectUser"
:value="item" icon="el-icon-search"
:label="item.username" style="
> border-color: #46a6ff;
</el-option> background-color: #46a6ff;
</el-select> color: white;
"
></el-button>
</el-input>
<UserSelect ref="UserSelect" @onSelected="onUserSelected" />
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
@ -150,13 +152,13 @@
<script> <script>
import { listData } from "@/api/system/dict/data"; import { listData } from "@/api/system/dict/data";
import { listUser } from "@/api/system/user";
import { createAuthenticateApply } from "@/api/fileAuth/authenticate"; import { createAuthenticateApply } from "@/api/fileAuth/authenticate";
import { getRecordPage } from "@/api/archives/record"; import { getRecordPage } from "@/api/archives/record";
import UserSelect from "@/components/UserSelect/single.vue";
export default { export default {
name: "FileAuth", name: "FileAuth",
components: {}, components: { UserSelect },
data() { data() {
return { return {
// //
@ -190,7 +192,6 @@ export default {
fileStatusOptions: [], // fileStatusOptions: [], //
catalogNumOptions: [], // catalogNumOptions: [], //
caseNumOptions: [], // caseNumOptions: [], //
userOptions: [], //
userName: null, userName: null,
options: [ options: [
{ {
@ -252,16 +253,6 @@ export default {
this.fileTypeOptions = res.data.list || []; this.fileTypeOptions = res.data.list || [];
}); });
}, },
//
getUserList() {
listUser().then((response) => {
this.userOptions = response.data.list;
});
},
handleSelectUser(val) {
this.form.userId = val.id;
this.form.userName = val.username;
},
/** 取消按钮 */ /** 取消按钮 */
cancel() { cancel() {
this.open = false; this.open = false;
@ -314,6 +305,18 @@ export default {
return; return;
}); });
}, },
//
handleSelectUser() {
this.$refs.UserSelect.showFlag = true;
},
//
onUserSelected(obj) {
console.log(obj);
if (obj != undefined && obj != null) {
this.form.userName = obj.username;
this.form.userId = obj.id;
}
},
}, },
}; };
</script> </script>

@ -45,14 +45,6 @@
:default-time="['00:00:00', '23:59:59']" :default-time="['00:00:00', '23:59:59']"
/> />
</el-form-item> </el-form-item>
<!-- <el-form-item label="立档单位名称" prop="organizationName">
<el-input
v-model="queryParams.organizationName"
placeholder="请输入立档单位名称"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item> -->
<el-form-item> <el-form-item>
<el-button type="primary" icon="el-icon-search" @click="handleQuery" <el-button type="primary" icon="el-icon-search" @click="handleQuery"
>搜索</el-button >搜索</el-button
@ -94,7 +86,6 @@
<!-- 列表 --> <!-- 列表 -->
<el-table v-loading="loading" :data="list"> <el-table v-loading="loading" :data="list">
<!-- <el-table-column label="主键ID" align="center" prop="id" /> -->
<el-table-column label="库房名称" align="center" prop="name" /> <el-table-column label="库房名称" align="center" prop="name" />
<el-table-column label="库房编号" align="center" prop="code" /> <el-table-column label="库房编号" align="center" prop="code" />
<el-table-column label="库房地址" align="center" prop="address" /> <el-table-column label="库房地址" align="center" prop="address" />
@ -179,21 +170,23 @@
<el-row> <el-row>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="管理者姓名" prop="manegerName"> <el-form-item label="管理者姓名" prop="manegerName">
<el-select <el-input
v-model="manegerName" v-model="form.manegerName"
filterable
placeholder="请选择管理者" placeholder="请选择管理者"
value-key="id" readonly
@change="handleSelectUser"
>
<el-option
v-for="item in userOptions"
:key="item.id"
:value="item"
:label="item.username"
> >
</el-option> <el-button
</el-select> slot="append"
@click="handleSelectUser"
icon="el-icon-search"
style="
border-color: #46a6ff;
background-color: #46a6ff;
color: white;
"
></el-button>
</el-input>
<UserSelect ref="UserSelect" @onSelected="onUserSelected" />
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
@ -242,11 +235,11 @@ import {
exportDepotExcel, exportDepotExcel,
} from "@/api/setting/depot"; } from "@/api/setting/depot";
import { getOrganizationPage } from "@/api/setting/organization"; import { getOrganizationPage } from "@/api/setting/organization";
import { listUser } from "@/api/system/user"; import UserSelect from "@/components/UserSelect/single.vue";
export default { export default {
name: "Depot", name: "Depot",
components: {}, components: { UserSelect },
data() { data() {
return { return {
// //
@ -280,9 +273,7 @@ export default {
// //
rules: {}, rules: {},
organizationList: [], // organizationList: [], //
userOptions: [], //
organizationName: null, organizationName: null,
manegerName: null,
}; };
}, },
created() { created() {
@ -312,17 +303,6 @@ export default {
this.form.organizationId = val.id; this.form.organizationId = val.id;
this.form.organizationName = val.organizationName; this.form.organizationName = val.organizationName;
}, },
//
getUserList() {
listUser().then((response) => {
this.userOptions = response.data.list;
});
},
handleSelectUser(val) {
console.log(val);
this.form.manegerId = val.id;
this.form.manegerName = val.username;
},
/** 取消按钮 */ /** 取消按钮 */
cancel() { cancel() {
this.open = false; this.open = false;
@ -346,7 +326,6 @@ export default {
company: undefined, company: undefined,
remark: undefined, remark: undefined,
}; };
this.manegerName = undefined;
this.organizationName = undefined; this.organizationName = undefined;
this.resetForm("form"); this.resetForm("form");
}, },
@ -373,7 +352,6 @@ export default {
getDepot(id).then((response) => { getDepot(id).then((response) => {
this.form = response.data; this.form = response.data;
this.organizationName = response.data.organizationName; this.organizationName = response.data.organizationName;
this.manegerName = response.data.manegerName;
this.open = true; this.open = true;
this.title = "修改库房管理"; this.title = "修改库房管理";
}); });
@ -433,6 +411,17 @@ export default {
}) })
.catch(() => {}); .catch(() => {});
}, },
//
handleSelectUser() {
this.$refs.UserSelect.showFlag = true;
},
//
onUserSelected(obj) {
console.log(obj);
if (obj != undefined && obj != null) {
this.form.manegerName = obj.username;
}
},
}, },
}; };
</script> </script>

@ -45,15 +45,6 @@
:default-time="['00:00:00', '23:59:59']" :default-time="['00:00:00', '23:59:59']"
/> />
</el-form-item> </el-form-item>
<!-- <el-form-item label="管理者姓名" prop="manegerName">
<el-input
v-model="queryParams.manegerName"
placeholder="请输入管理者姓名"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item> -->
<el-form-item> <el-form-item>
<el-button type="primary" icon="el-icon-search" @click="handleQuery" <el-button type="primary" icon="el-icon-search" @click="handleQuery"
>搜索</el-button >搜索</el-button
@ -95,7 +86,6 @@
<!-- 列表 --> <!-- 列表 -->
<el-table v-loading="loading" :data="list"> <el-table v-loading="loading" :data="list">
<!-- <el-table-column label="所属库房ID" align="center" prop="depotId" /> -->
<el-table-column label="柜子名称" align="center" prop="name" /> <el-table-column label="柜子名称" align="center" prop="name" />
<el-table-column label="柜子编号" align="center" prop="code" /> <el-table-column label="柜子编号" align="center" prop="code" />
<el-table-column label="库房地址" align="center" prop="address" /> <el-table-column label="库房地址" align="center" prop="address" />
@ -191,21 +181,23 @@
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="管理者姓名" prop="manegerName"> <el-form-item label="管理者姓名" prop="manegerName">
<el-select <el-input
v-model="manegerName" v-model="form.manegerName"
filterable
placeholder="请选择管理者" placeholder="请选择管理者"
value-key="id" readonly
@change="handleSelectUser"
> >
<el-option <el-button
v-for="item in userOptions" slot="append"
:key="item.id" @click="handleSelectUser"
:value="item" icon="el-icon-search"
:label="item.username" style="
> border-color: #46a6ff;
</el-option> background-color: #46a6ff;
</el-select> color: white;
"
></el-button>
</el-input>
<UserSelect ref="UserSelect" @onSelected="onUserSelected" />
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
@ -235,11 +227,11 @@ import {
exportDepotCabinetExcel, exportDepotCabinetExcel,
} from "@/api/setting/depotCabinet"; } from "@/api/setting/depotCabinet";
import { getDepotPage } from "@/api/setting/depot"; import { getDepotPage } from "@/api/setting/depot";
import { listUser } from "@/api/system/user"; import UserSelect from "@/components/UserSelect/single.vue";
export default { export default {
name: "DepotCabinet", name: "DepotCabinet",
components: {}, components: { UserSelect },
data() { data() {
return { return {
// //
@ -278,15 +270,12 @@ export default {
form: {}, form: {},
// //
rules: {}, rules: {},
userOptions: [], //
addressList: [], // addressList: [], //
manegerName: null,
}; };
}, },
created() { created() {
this.getList(); this.getList();
this.getAddressList(); this.getAddressList();
this.getUserList();
}, },
methods: { methods: {
/** 查询列表 */ /** 查询列表 */
@ -299,28 +288,12 @@ export default {
this.loading = false; this.loading = false;
}); });
}, },
//
getUserList() {
listUser().then((response) => {
this.userOptions = response.data.list;
});
},
// //
getAddressList() { getAddressList() {
getDepotPage().then((response) => { getDepotPage().then((response) => {
this.addressList = response.data.list; this.addressList = response.data.list;
}); });
}, },
// handleSelectAddress(val) {
// console.log(val);
// this.form.depotId = val.id;
// this.form.depotName = val.name;
// },
handleSelectUser(val) {
console.log(val);
this.form.manegerId = val.id;
this.form.manegerName = val.username;
},
/** 取消按钮 */ /** 取消按钮 */
cancel() { cancel() {
this.open = false; this.open = false;
@ -344,7 +317,6 @@ export default {
remark: undefined, remark: undefined,
cabinetNum: undefined, cabinetNum: undefined,
}; };
this.manegerName = undefined;
this.resetForm("form"); this.resetForm("form");
}, },
/** 搜索按钮操作 */ /** 搜索按钮操作 */
@ -369,7 +341,6 @@ export default {
const id = row.id; const id = row.id;
getDepotCabinet(id).then((response) => { getDepotCabinet(id).then((response) => {
this.form = response.data; this.form = response.data;
this.manegerName = response.data.manegerName;
this.open = true; this.open = true;
this.title = "修改档案柜管理"; this.title = "修改档案柜管理";
}); });
@ -429,6 +400,17 @@ export default {
}) })
.catch(() => {}); .catch(() => {});
}, },
//
handleSelectUser() {
this.$refs.UserSelect.showFlag = true;
},
//
onUserSelected(obj) {
console.log(obj);
if (obj != undefined && obj != null) {
this.form.manegerName = obj.username;
}
},
}, },
}; };
</script> </script>

Loading…
Cancel
Save