仓库类型调整

ywj_dev
anthonywj 2 years ago
parent 04c34f2ca0
commit 1bcb58eee8

@ -16,11 +16,11 @@
placeholder="仓库类型" placeholder="仓库类型"
></el-input> ></el-input>
</el-form-item> --> </el-form-item> -->
<el-form-item label="仓库类型" prop="advanceType" > <el-form-item label="仓库类型" prop="advanceType">
<el-select v-model="subData.advanceType" placeholder="请选择仓库类型" style="width: 80%"> <el-select v-model="subData.advanceType" placeholder="请选择仓库类型" style="width: 80%">
<el-option label="入账库" value="1"/> <el-option label="入账库" :value="1"/>
<el-option label="寄售库" value="2"/> <el-option label="寄售库" :value="2"/>
<el-option label="预验收库" value="3"/> <el-option label="预验收库" :value="3"/>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
@ -43,30 +43,39 @@
<el-table-column label="序号" type="index" ref="dataForm"></el-table-column> <el-table-column label="序号" type="index" ref="dataForm"></el-table-column>
<el-table-column <el-table-column
prop="code" prop="code"
width="140"
label="仓库编码" label="仓库编码"
> >
</el-table-column> </el-table-column>
<el-table-column <el-table-column
width="160"
prop="name" prop="name"
label="仓库名称" label="仓库名称"
> >
</el-table-column> </el-table-column>
<el-table-column <el-table-column
prop="parentName" prop="parentName"
width="180"
label="所属部门" label="所属部门"
> >
</el-table-column> </el-table-column>
<el-table-column <el-table-column width="160"
prop="parentInvName" prop="parentInvName"
label="上级仓库" label="上级仓库"
> >
</el-table-column> </el-table-column>
<el-table-column <el-table-column
width="140"
prop="advanceType" prop="advanceType"
label="仓库类型" label="仓库类型"
> >
<template slot-scope="scope">
<span>{{ advanceTypeTypeMap[scope.row.advanceType] }}</span>
</template>
</el-table-column> </el-table-column>
<el-table-column label="允许供应商使用" prop="spUse"> <el-table-column label="允许供应商使用" prop="spUse" width="140">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag :type="scope.row.spUse | spUerFilterType">{{ <el-tag :type="scope.row.spUse | spUerFilterType">{{
scope.row.spUse | spUerFilterName scope.row.spUse | spUerFilterName
@ -74,7 +83,7 @@
</el-tag> </el-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作" class-name="small-padding fixed-width"> <el-table-column label="操作" width="220">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
type="text" type="text"
@ -187,8 +196,9 @@
</el-row> </el-row>
<el-row :gutter="20" class="el-row" type="flex"> <el-row :gutter="20" class="el-row" type="flex">
<el-col :span="12" class="el-col"> <el-col :span="12" class="el-col">
<el-form-item label="仓库类型" prop="advanceType" > <el-form-item label="仓库类型" prop="advanceType">
<el-select v-model="subData.advanceType" :disabled="invWouse != null" placeholder="请选择仓库类型" style="width: 80%"> <el-select v-model="subData.advanceType" :disabled="invWouse != null" placeholder="请选择仓库类型"
style="width: 80%">
<el-option label="入账库" value="1"/> <el-option label="入账库" value="1"/>
<el-option label="寄售库" value="2"/> <el-option label="寄售库" value="2"/>
<el-option label="预验收库" value="3"/> <el-option label="预验收库" value="3"/>
@ -414,17 +424,22 @@ export default {
// page: 1, // page: 1,
// limit: 10, // limit: 10,
}, },
isAdvanceTypeShow:false, isAdvanceTypeShow: false,
isShow:false, isShow: false,
loading: true, loading: true,
list: [], list: [],
isExpandAll: true, isExpandAll: true,
total: 0, total: 0,
advanceTypeTypeMap: {
1: "入账库",
2: "寄售库",
3: "预验收库",
},
formMap: { formMap: {
add: "仓库信息-新增", add: "仓库信息-新增",
edit: "仓库信息-编辑" edit: "仓库信息-编辑"
}, },
invWouse:{}, invWouse: {},
formName: null, formName: null,
configParms: {}, configParms: {},
currentCode: null, currentCode: null,
@ -467,7 +482,7 @@ export default {
}, },
sysList: [], sysList: [],
sysSubList: [], sysSubList: [],
advanceTypese:[], advanceTypese: [],
}; };
}, },
methods: { methods: {
@ -512,38 +527,38 @@ export default {
}); });
}, },
handleSubForm(data, formName) { // handleSubForm(data, formName) { //
if(data != null ){ if (data != null) {
this.invWouse=data; this.invWouse = data;
} }
this.formName = formName; this.formName = formName;
if (formName === "edit") { if (formName === "edit") {
this.subData = JSON.parse(JSON.stringify(data)); this.subData = JSON.parse(JSON.stringify(data));
this.subData.advanceType=this.subData.advanceType.toString(); this.subData.advanceType = this.subData.advanceType.toString();
if(this.subData.parentCode!=null && this.subData.parentCode!=""){ if (this.subData.parentCode != null && this.subData.parentCode != "") {
this.isAdvanceTypeShow=true; this.isAdvanceTypeShow = true;
this.isShow=false; this.isShow = false;
}else{ } else {
this.isAdvanceTypeShow=false; this.isAdvanceTypeShow = false;
this.isShow=true this.isShow = true
this.subData.parentCode=null; this.subData.parentCode = null;
} }
} else if (formName === "add") { } else if (formName === "add") {
this.isShow=true this.isShow = true
if(data==null){ if (data == null) {
this.isAdvanceTypeShow=false; this.isAdvanceTypeShow = false;
this.subData = {advanceType: '1', spUse: false,parentCode:null}; this.subData = {advanceType: '1', spUse: false, parentCode: null};
}else{ } else {
this.isAdvanceTypeShow=true; this.isAdvanceTypeShow = true;
this.subData = {advanceType: data.advanceType.toString(), spUse: false,parentCode:data.code}; this.subData = {advanceType: data.advanceType.toString(), spUse: false, parentCode: data.code};
} }
} }
// //
let advanceTypese =this.subData.advanceType let advanceTypese = this.subData.advanceType
this.subFormVisible = true; this.subFormVisible = true;
this.getSubThrsysDetailData(); this.getSubThrsysDetailData();
if(this.subData.parentCode!=null && this.subData.parentCode!=""){ if (this.subData.parentCode != null && this.subData.parentCode != "") {
filterSubAll(this.query) filterSubAll(this.query)
.then((response) => { .then((response) => {
let invList = response.data || []; let invList = response.data || [];

Loading…
Cancel
Save