|
@@ -225,7 +225,7 @@
|
|
<el-table-column label="报关单" prop="invoFileId" width="200">
|
|
<el-table-column label="报关单" prop="invoFileId" width="200">
|
|
<template slot-scope="scope">
|
|
<template slot-scope="scope">
|
|
<yl-upload
|
|
<yl-upload
|
|
- v-if="scope.row.prodSouc=='进口'"
|
|
|
|
|
|
+ v-if="scope.row.prodSouc=='2'"
|
|
:fileId="scope.row.invoFileId"
|
|
:fileId="scope.row.invoFileId"
|
|
@getUpload="getUpload1"
|
|
@getUpload="getUpload1"
|
|
urlName="acco"
|
|
urlName="acco"
|
|
@@ -829,7 +829,7 @@ export default {
|
|
numAll(row) {
|
|
numAll(row) {
|
|
let num = 0;
|
|
let num = 0;
|
|
this.tableData.forEach((item) => {
|
|
this.tableData.forEach((item) => {
|
|
- if (item.materialId == row.materialId) {
|
|
|
|
|
|
+ if (item.prodCode == row.prodCode) {
|
|
num += item.delvCnt;
|
|
num += item.delvCnt;
|
|
}
|
|
}
|
|
});
|
|
});
|
|
@@ -875,7 +875,7 @@ export default {
|
|
this.tableData.forEach(async (item) => {
|
|
this.tableData.forEach(async (item) => {
|
|
await this.numAll(row);
|
|
await this.numAll(row);
|
|
console.log(this.numAll(row), "he");
|
|
console.log(this.numAll(row), "he");
|
|
- if (item.materialId == row.materialId) {
|
|
|
|
|
|
+ if (item.prodCode == row.prodCode) {
|
|
if (this.numAll(row) > item.toDelvCnt) {
|
|
if (this.numAll(row) > item.toDelvCnt) {
|
|
this.$message.warning("出库数量不能大于待出库数量");
|
|
this.$message.warning("出库数量不能大于待出库数量");
|
|
row.delvCnt = 0;
|
|
row.delvCnt = 0;
|
|
@@ -961,7 +961,7 @@ export default {
|
|
console.log("索引", 0, this.count);
|
|
console.log("索引", 0, this.count);
|
|
} else {
|
|
} else {
|
|
// 判断当前项与上项的设备类别是否相同,因为是合并这一列的单元格
|
|
// 判断当前项与上项的设备类别是否相同,因为是合并这一列的单元格
|
|
- if (tableData[i].materialId == tableData[i - 1].materialId) {
|
|
|
|
|
|
+ if (tableData[i].prodCode == tableData[i - 1].prodCode) {
|
|
this.cellList[this.count] += 1; // 增加计数
|
|
this.cellList[this.count] += 1; // 增加计数
|
|
this.cellList.push(0); // 相等就往cellList数组中追加0
|
|
this.cellList.push(0); // 相等就往cellList数组中追加0
|
|
console.log("索引", i, this.count);
|
|
console.log("索引", i, this.count);
|
|
@@ -986,10 +986,8 @@ export default {
|
|
columnIndex === 8 ||
|
|
columnIndex === 8 ||
|
|
columnIndex === 9 ||
|
|
columnIndex === 9 ||
|
|
columnIndex === 10 ||
|
|
columnIndex === 10 ||
|
|
- columnIndex === 11 ||
|
|
|
|
columnIndex === 15 ||
|
|
columnIndex === 15 ||
|
|
- columnIndex === 16 ||
|
|
|
|
- columnIndex === 17
|
|
|
|
|
|
+ columnIndex === 16
|
|
) {
|
|
) {
|
|
// console.log("单元格数组,若下一项为0,则代表合并上一项", this.cellList);
|
|
// console.log("单元格数组,若下一项为0,则代表合并上一项", this.cellList);
|
|
const rowCell = this.cellList[rowIndex];
|
|
const rowCell = this.cellList[rowIndex];
|
|
@@ -1028,10 +1026,10 @@ export default {
|
|
},
|
|
},
|
|
//删除
|
|
//删除
|
|
handleDelete(row, i) {
|
|
handleDelete(row, i) {
|
|
- const index = this.tableData.findIndex((item) => item.materialId === row.materialId);
|
|
|
|
|
|
+ const index = this.tableData.findIndex((item) => item.prodCode === row.prodCode);
|
|
if (index !== -1) {
|
|
if (index !== -1) {
|
|
let qwe = this.tableData.findIndex(function (item) {
|
|
let qwe = this.tableData.findIndex(function (item) {
|
|
- return item.materialId == row.materialId;
|
|
|
|
|
|
+ return item.prodCode == row.prodCode;
|
|
});
|
|
});
|
|
this.tableData.splice(i, 1);
|
|
this.tableData.splice(i, 1);
|
|
this.cellList.splice(i, 1);
|
|
this.cellList.splice(i, 1);
|
|
@@ -1158,7 +1156,7 @@ export default {
|
|
});
|
|
});
|
|
throw new Error("本次出库数量必须大于0");
|
|
throw new Error("本次出库数量必须大于0");
|
|
}
|
|
}
|
|
- if (item.prodSouc=="进口" && !item.invoFileId) {
|
|
|
|
|
|
+ if (item.prodSouc=="2" && !item.invoFileId) {
|
|
this.$message({
|
|
this.$message({
|
|
// message: "请填写相应信息,并选择报关单和随货单",
|
|
// message: "请填写相应信息,并选择报关单和随货单",
|
|
message: "请填写相应信息,并选择报关单",
|
|
message: "请填写相应信息,并选择报关单",
|