bug修改
This commit is contained in:
parent
18dd923bfa
commit
cac93fef29
|
|
@ -67,7 +67,11 @@
|
||||||
<el-descriptions-item>
|
<el-descriptions-item>
|
||||||
<template slot="label">备注</template>
|
<template slot="label">备注</template>
|
||||||
{{ baseInfo.remark }}
|
{{ baseInfo.remark }}
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
|
<el-descriptions-item>
|
||||||
|
<template slot="label">负责人</template>
|
||||||
|
{{ baseInfo.contractPersonName }}
|
||||||
|
</el-descriptions-item>
|
||||||
</el-descriptions>
|
</el-descriptions>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -28,7 +28,7 @@
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
<el-descriptions-item>
|
<el-descriptions-item>
|
||||||
<template slot="label">联系人</template>
|
<template slot="label">联系人</template>
|
||||||
{{ baseInfo.linkMan }}
|
{{ baseInfo.linkManName }}
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
<el-descriptions-item>
|
<el-descriptions-item>
|
||||||
<template slot="label">联系电话</template>
|
<template slot="label">联系电话</template>
|
||||||
|
|
|
||||||
|
|
@ -28,7 +28,7 @@
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
<el-descriptions-item>
|
<el-descriptions-item>
|
||||||
<template slot="label">联系人</template>
|
<template slot="label">联系人</template>
|
||||||
{{ baseInfo.linkMan }}
|
{{ baseInfo.linkManName }}
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
<el-descriptions-item>
|
<el-descriptions-item>
|
||||||
<template slot="label">联系电话</template>
|
<template slot="label">联系电话</template>
|
||||||
|
|
|
||||||
|
|
@ -36,7 +36,7 @@
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
<el-descriptions-item>
|
<el-descriptions-item>
|
||||||
<template slot="label">验货人</template>
|
<template slot="label">验货人</template>
|
||||||
{{ baseInfo.inspector }}
|
{{ baseInfo.inspectorName }}
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
<el-descriptions-item>
|
<el-descriptions-item>
|
||||||
<template slot="label">备注</template>
|
<template slot="label">备注</template>
|
||||||
|
|
|
||||||
|
|
@ -479,9 +479,9 @@ export default {
|
||||||
},
|
},
|
||||||
defaultDateRange() {
|
defaultDateRange() {
|
||||||
const end = new Date(new Date().toLocaleDateString());
|
const end = new Date(new Date().toLocaleDateString());
|
||||||
end.setTime(end.getTime() + 24 * 60 * 60 * 1000 -1);
|
end.setTime(end.getTime() + 16 * 24 * 60 * 60 * 1000 -1);
|
||||||
const start = new Date((new Date().toLocaleDateString()));
|
const start = new Date((new Date().toLocaleDateString()));
|
||||||
start.setTime(start.getTime() - 30 * 24 * 60 * 60 * 1000);
|
start.setTime(start.getTime() - 15 * 24 * 60 * 60 * 1000);
|
||||||
this.start = parseInt(start.getTime() / 1000)
|
this.start = parseInt(start.getTime() / 1000)
|
||||||
this.end = parseInt(end.getTime() / 1000)
|
this.end = parseInt(end.getTime() / 1000)
|
||||||
return [start, end]
|
return [start, end]
|
||||||
|
|
|
||||||
|
|
@ -14,9 +14,9 @@
|
||||||
<el-form-item label="仓库名称" prop="warehouseName">
|
<el-form-item label="仓库名称" prop="warehouseName">
|
||||||
<el-input v-model="queryParams.warehouseName" placeholder="请输入仓库名称" maxlength="20" clearable style="width: 220px"/>
|
<el-input v-model="queryParams.warehouseName" placeholder="请输入仓库名称" maxlength="20" clearable style="width: 220px"/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="负责人" prop="manager">
|
<!-- <el-form-item label="负责人" prop="manager">
|
||||||
<el-input v-model="queryParams.manager" placeholder="请输入负责人" maxlength="20" clearable style="width: 220px"/>
|
<el-input v-model="queryParams.manager" placeholder="请输入负责人" maxlength="20" clearable style="width: 220px"/>
|
||||||
</el-form-item>
|
</el-form-item> -->
|
||||||
<el-form-item label="仓库类别" prop="categoryId">
|
<el-form-item label="仓库类别" prop="categoryId">
|
||||||
<el-select v-model="queryParams.categoryId" placeholder="仓库类别" clearable style="width: 240px" >
|
<el-select v-model="queryParams.categoryId" placeholder="仓库类别" clearable style="width: 240px" >
|
||||||
<el-option
|
<el-option
|
||||||
|
|
@ -73,7 +73,7 @@
|
||||||
<el-table-column label="所属区域" align="center" prop="areaName" :show-overflow-tooltip="true" ></el-table-column>
|
<el-table-column label="所属区域" align="center" prop="areaName" :show-overflow-tooltip="true" ></el-table-column>
|
||||||
<el-table-column label="所属食堂" align="center" prop="canteenName" :show-overflow-tooltip="true" ></el-table-column>
|
<el-table-column label="所属食堂" align="center" prop="canteenName" :show-overflow-tooltip="true" ></el-table-column>
|
||||||
<el-table-column label="仓库地址" align="center" prop="address" :show-overflow-tooltip="true" ></el-table-column>
|
<el-table-column label="仓库地址" align="center" prop="address" :show-overflow-tooltip="true" ></el-table-column>
|
||||||
<el-table-column label="负责人" align="center" prop="manager" :show-overflow-tooltip="true" ></el-table-column>
|
<el-table-column label="负责人" align="center" prop="managerName" :show-overflow-tooltip="true" ></el-table-column>
|
||||||
<el-table-column label="手机号" align="center" prop="managerPhone" :show-overflow-tooltip="true" ></el-table-column>
|
<el-table-column label="手机号" align="center" prop="managerPhone" :show-overflow-tooltip="true" ></el-table-column>
|
||||||
<el-table-column label="操作" align="center" width="200" class-name="small-padding fixed-width" fixed="right">
|
<el-table-column label="操作" align="center" width="200" class-name="small-padding fixed-width" fixed="right">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
|
|
@ -207,8 +207,7 @@ export default {
|
||||||
dicts: ['warehouse_category'],
|
dicts: ['warehouse_category'],
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
contractPersonOptions: [], // 下拉框选项
|
contractPersonOptions: [], // 下拉框选项
|
||||||
contractPerson: '', // 绑定的值
|
|
||||||
// 遮罩层
|
// 遮罩层
|
||||||
loading: true,
|
loading: true,
|
||||||
// 选中数组
|
// 选中数组
|
||||||
|
|
@ -341,8 +340,7 @@ export default {
|
||||||
this.title = "修改";
|
this.title = "修改";
|
||||||
},
|
},
|
||||||
/** 提交按钮 */
|
/** 提交按钮 */
|
||||||
submitForm: function() {
|
submitForm: function() {
|
||||||
this.form.manager = this.contractPerson; // 将选择的负责人传给 form.manager
|
|
||||||
this.$refs["form"].validate(valid => {
|
this.$refs["form"].validate(valid => {
|
||||||
if (valid) {
|
if (valid) {
|
||||||
if (this.form.warehouseId != undefined) {
|
if (this.form.warehouseId != undefined) {
|
||||||
|
|
|
||||||
|
|
@ -425,9 +425,11 @@ export default {
|
||||||
"ifSupply": row.ifSupply
|
"ifSupply": row.ifSupply
|
||||||
}
|
}
|
||||||
if(!row.materialId){//类别
|
if(!row.materialId){//类别
|
||||||
param.categoryId = row.materialTypeId
|
param.categoryId = row.materialTypeId;
|
||||||
|
param.bingType = 2;
|
||||||
}else{//名称
|
}else{//名称
|
||||||
param.materialId = row.materialId
|
param.materialId = row.materialId
|
||||||
|
param.bingType = 1;
|
||||||
}
|
}
|
||||||
supplierBindMaterialApi(param).then(response => {
|
supplierBindMaterialApi(param).then(response => {
|
||||||
this.$modal.msgSuccess("修改成功");
|
this.$modal.msgSuccess("修改成功");
|
||||||
|
|
@ -448,8 +450,10 @@ export default {
|
||||||
}
|
}
|
||||||
if(!row.materialId){//类别
|
if(!row.materialId){//类别
|
||||||
param.categoryId = row.materialTypeId
|
param.categoryId = row.materialTypeId
|
||||||
|
param.bingType = 2;
|
||||||
}else{//名称
|
}else{//名称
|
||||||
param.materialId = row.materialId
|
param.materialId = row.materialId
|
||||||
|
param.bingType = 1;
|
||||||
}
|
}
|
||||||
supplierBindMaterialApi(param).then(response => {
|
supplierBindMaterialApi(param).then(response => {
|
||||||
this.$modal.msgSuccess("修改成功");
|
this.$modal.msgSuccess("修改成功");
|
||||||
|
|
@ -472,8 +476,10 @@ export default {
|
||||||
}
|
}
|
||||||
if(!row.materialId){//类别
|
if(!row.materialId){//类别
|
||||||
param.categoryId = row.materialTypeId
|
param.categoryId = row.materialTypeId
|
||||||
|
param.bingType = 1;
|
||||||
}else{//名称
|
}else{//名称
|
||||||
param.materialId = row.materialId
|
param.materialId = row.materialId
|
||||||
|
param.bingType = 1;
|
||||||
}
|
}
|
||||||
if(row.supplierIdList&&row.supplierIdList.length>0){
|
if(row.supplierIdList&&row.supplierIdList.length>0){
|
||||||
row.supplierIdList.forEach(item => {
|
row.supplierIdList.forEach(item => {
|
||||||
|
|
@ -569,11 +575,13 @@ export default {
|
||||||
"ifSupply": "1"
|
"ifSupply": "1"
|
||||||
}
|
}
|
||||||
this.batchRows.forEach(item=>{
|
this.batchRows.forEach(item=>{
|
||||||
if(!item.materialId){
|
if(!item.materialId){//类别
|
||||||
param.categoryIds.push(item.materialTypeId)
|
param.categoryIds.push(item.materialTypeId)
|
||||||
|
param.bingType = 1;
|
||||||
param.materialIds=null
|
param.materialIds=null
|
||||||
}else{
|
}else{//名称
|
||||||
param.materialIds.push(item.materialId)
|
param.materialIds.push(item.materialId)
|
||||||
|
param.bingType = 2;
|
||||||
param.categoryIds=null
|
param.categoryIds=null
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
@ -626,7 +634,7 @@ export default {
|
||||||
}
|
}
|
||||||
materialTypeBindSupplierPageApi(param).then(response => {
|
materialTypeBindSupplierPageApi(param).then(response => {
|
||||||
this.tableListData2 = response.rows;
|
this.tableListData2 = response.rows;
|
||||||
this.tableListData2.forEach(item=>{
|
this.tableListData2.forEach((item,index)=>{
|
||||||
let arr=[]
|
let arr=[]
|
||||||
if(item.alternativeSuppliers&&item.alternativeSuppliers.length>0){
|
if(item.alternativeSuppliers&&item.alternativeSuppliers.length>0){
|
||||||
item.alternativeSuppliers.forEach(sub=>{
|
item.alternativeSuppliers.forEach(sub=>{
|
||||||
|
|
@ -634,6 +642,10 @@ export default {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
this.$set(item,"supplierIdList",arr)
|
this.$set(item,"supplierIdList",arr)
|
||||||
|
if(item.parentId==-1){
|
||||||
|
// if(item.materialTypeName=='原料'){
|
||||||
|
this.tableListData2.splice(index,1)
|
||||||
|
}
|
||||||
})
|
})
|
||||||
this.total2 = Number(response.total);
|
this.total2 = Number(response.total);
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
|
|
|
||||||
|
|
@ -282,7 +282,7 @@ export default {
|
||||||
handleUpdate(row) {
|
handleUpdate(row) {
|
||||||
console.log("row", row);
|
console.log("row", row);
|
||||||
this.reset();
|
this.reset();
|
||||||
getListApi(row.id).then(response => {
|
getListApi({id:row.id}).then(response => {
|
||||||
console.log("response",response);
|
console.log("response",response);
|
||||||
this.form = response.rows[0];
|
this.form = response.rows[0];
|
||||||
if(response.rows[0].photoUrl){
|
if(response.rows[0].photoUrl){
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue