Merge remote-tracking branch 'origin/master'

prod
x_z 2 years ago
commit 2e796e4dba

@ -205,12 +205,14 @@ export default {
limit: 10 limit: 10
}; };
}, },
loadUserList(val) { // loadUserList() { //
if (val != null) {
this.userQuery.page = val; // if (val != null) {
} // this.userQuery.page = val;
// }
// //
warehouseUserList(this.userQuery).then((res) => { warehouseUserList(this.userQuery).then((res) => {
this.userData = res.data.list; this.userData = res.data.list;
this.userTotal = res.data.total; this.userTotal = res.data.total;
}).catch((error) => { }).catch((error) => {

@ -33,7 +33,7 @@
:default-expand-all="isExpandAll" :default-expand-all="isExpandAll"
:tree-props="{children: 'children', hasChildren: 'hasChildren'}" :tree-props="{children: 'children', hasChildren: 'hasChildren'}"
> >
<el-table-column label="序号" type="index"></el-table-column> <el-table-column label="序号" type="index" ref="dataForm"></el-table-column>
<el-table-column <el-table-column
prop="name" prop="name"
label="仓库名称" label="仓库名称"
@ -93,13 +93,13 @@
</el-table-column> </el-table-column>
</el-table> </el-table>
<pagination <!--<pagination-->
v-show="total>0" <!-- v-show="total>0"-->
:total="total" <!-- :total="total"-->
:page.sync="query.page" <!-- :page.sync="query.page"-->
:limit.sync="query.limit" <!-- :limit.sync="query.limit"-->
@pagination="getList" <!-- @pagination="getList"-->
/> <!--/>-->
<!--仓库编辑对话框--> <!--仓库编辑对话框-->
<el-dialog <el-dialog
:title="formMap[formName]" :title="formMap[formName]"
@ -131,7 +131,7 @@
<el-col :span="12" class="el-col"> <el-col :span="12" class="el-col">
<el-form-item label="上级仓库" prop="parentCode"> <el-form-item label="上级仓库" prop="parentCode">
<treeselect v-model="subData.parentCode" :options="invOptions" :normalizer="normalizer" <treeselect v-model="subData.parentInvName" :options="invOptions" :normalizer="normalizer"
:disabled="isShow" :disabled="isShow"
style="width: 80%" style="width: 80%"
placeholder="选择上级仓库"/> placeholder="选择上级仓库"/>
@ -263,7 +263,7 @@
:total="subTotal" :total="subTotal"
:page.sync="thirdSubQuery.page" :page.sync="thirdSubQuery.page"
:limit.sync="thirdSubQuery.limit" :limit.sync="thirdSubQuery.limit"
@pagination="getList" @pagination="intentSubSelect"
/> />
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
@ -327,7 +327,7 @@
<script> <script>
import { import {
filterSubAll, saveSubWarehouse, deleteSubWarehouse, filterSubAll, saveSubWarehouse, deleteSubWarehouse,
getSubThrsysDetail, bindThrSubWarehouse, unbindSubThrWarehouse getSubThrsysDetail, bindThrSubWarehouse, unbindSubThrWarehouse,
} from "@/api/system/invSubWarehouse"; } from "@/api/system/invSubWarehouse";
import {getHospitalUserList, selectNotSelectUser} from "@/api/auth/authUser"; import {getHospitalUserList, selectNotSelectUser} from "@/api/auth/authUser";
import {getJoinBussinessType} from "@/api/basic/bussinessType"; import {getJoinBussinessType} from "@/api/basic/bussinessType";
@ -353,8 +353,8 @@ export default {
name: null, name: null,
code: null, code: null,
status: "1", status: "1",
page: 1, // page: 1,
limit: 10, // limit: 10,
}, },
isShow: null, isShow: null,
loading: true, loading: true,
@ -417,20 +417,20 @@ export default {
name: "", name: "",
status: "", status: "",
}; };
this.busQuery.page = 1;
this.getList(); this.getList();
}, },
onSubmit() { // onSubmit() { //
this.getList(); this.getList();
}, },
getList() { // getList() { //
this.loading = true; this.loading = true;
filterSubAll(this.query) filterSubAll(this.query)
.then((response) => { .then((response) => {
this.loading = false; this.loading = false;
this.total = response.data.total; //this.total = response.data.total;
let invlist = response.data.list || []; let invlist = response.data || [];
this.list = this.handleTree(invlist, "code", "parentCode"); this.list = this.handleTree(invlist, "code", "parentCode");
}) })
@ -458,13 +458,25 @@ export default {
}) })
.catch(() => { .catch(() => {
}); });
this.sysSubList=null;
}, },
hideForm() { // --- hideForm() { // ---
this.formVisible = false; this.formVisible = false;
this.subFormVisible = false; this.subFormVisible = false;
this.resetForm();
return true; return true;
}, },
//
resetForm() {
if (this.$refs["dataForm"]) {
//
this.$refs["dataForm"].clearValidate();
//
this.$refs["dataForm"].resetFields();
this.getList();
}
},
forInvSubmit() { // --- forInvSubmit() { // ---
this.$refs["dataForm"].validate(valid => { this.$refs["dataForm"].validate(valid => {
if (valid) { if (valid) {
@ -567,6 +579,8 @@ export default {
hideThrWarehouseTable() { hideThrWarehouseTable() {
this.thrWareHouseVisible = false; this.thrWareHouseVisible = false;
this.thrSubWareHouseVisible = false; this.thrSubWareHouseVisible = false;
//
this.thirdSubQuery.name="";
}, },
// //
bindSubThrWarehouse() { bindSubThrWarehouse() {

@ -495,6 +495,7 @@ export default {
this.subData.thirdSysFk = data.thirdSysFk; this.subData.thirdSysFk = data.thirdSysFk;
} }
this.subFormVisible = true; this.subFormVisible = true;
localStorage.setItem("code", JSON.stringify(this.subData.code));
}, },
handleSubDel(row) { handleSubDel(row) {
@ -539,7 +540,9 @@ export default {
this.$message.error("分库名称不能为空!"); this.$message.error("分库名称不能为空!");
return; return;
} }
saveSubWarehouse(this.subData, this.subFromName).then((response) => { saveSubWarehouse(this.subData, this.subFromName).then((response) => {
if (response.code == 20000) { if (response.code == 20000) {
let row = { let row = {
code: this.subData.parentId, code: this.subData.parentId,
@ -552,6 +555,7 @@ export default {
this.subFormVisible = false; this.subFormVisible = false;
} }
}).catch(() => { }).catch(() => {
this.subData.code=JSON.parse(localStorage.getItem("code"));
this.subFormVisible = false; this.subFormVisible = false;
}); });
this.resetForm(); this.resetForm();
@ -605,7 +609,8 @@ export default {
}) })
.catch(() => { .catch(() => {
this.formLoading = false; this.formLoading = false;
this.$refs["dataForm"].resetFields(); //
this.resetForm();
}); });
} }
}); });

Loading…
Cancel
Save