|
@@ -878,7 +878,7 @@
|
|
|
>
|
|
|
</el-table-column>
|
|
|
<el-table-column
|
|
|
- prop="fgrossweight"
|
|
|
+ prop="fGrossweight"
|
|
|
header-align="center"
|
|
|
width="180px"
|
|
|
align="center"
|
|
@@ -895,7 +895,7 @@
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
<el-table-column
|
|
|
- prop="fnetweight"
|
|
|
+ prop="fNetweight"
|
|
|
header-align="center"
|
|
|
width="180px"
|
|
|
align="center"
|
|
@@ -912,7 +912,7 @@
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
<el-table-column
|
|
|
- prop="fqty"
|
|
|
+ prop="fQty"
|
|
|
header-align="center"
|
|
|
width="180px"
|
|
|
align="center"
|
|
@@ -921,6 +921,7 @@
|
|
|
<template slot-scope="scope">
|
|
|
<el-input
|
|
|
oninput='this.value=this.value.replace(/[^\-?\d]/g,"").replace(/^(\-)*(\d+)\.(\d\d).*$/, "")'
|
|
|
+ @change="qtyChange(scope.row)"
|
|
|
v-model="scope.row.fQty"
|
|
|
:disabled="browseStatus"
|
|
|
placeholder="出库件数"
|
|
@@ -962,7 +963,7 @@
|
|
|
/>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
-
|
|
|
+
|
|
|
<el-table-column
|
|
|
prop="fCntrno"
|
|
|
header-align="center"
|
|
@@ -2365,7 +2366,6 @@ export default {
|
|
|
});
|
|
|
return false;
|
|
|
}
|
|
|
-
|
|
|
this.whgenlegList = [];
|
|
|
this.dialogWhgenlegList = [];
|
|
|
this.whgenlegTotal = 0;
|
|
@@ -2374,39 +2374,22 @@ export default {
|
|
|
},
|
|
|
// 库存总账导出数据
|
|
|
whgenlegData() {
|
|
|
- console.log(this.dialogWhgenlegList);
|
|
|
- console.log(this.whgenlegList);
|
|
|
- if (this.dialogWhgenlegList.length == 0) {
|
|
|
- this.dataList.push({
|
|
|
- fMblno: this.whgenlegList[0].fMblno,
|
|
|
- fGoodsid: this.whgenlegList[0].fGoodsid,
|
|
|
- fCntrtype: null,
|
|
|
- fQtyblc: this.whgenlegList[0].fQtyblc,
|
|
|
- fWarehouseLocationids: this.whgenlegList[0]
|
|
|
- .fWarehouseLocationids,
|
|
|
- fGoodsids: this.whgenlegList[0].fGoodsids,
|
|
|
- fGrossweight: 0,
|
|
|
- fNetweight: 0,
|
|
|
- fQty: 0,
|
|
|
- fCntqty: 1,
|
|
|
- fPackagespecs: null,
|
|
|
- fWarehouselocid: this.whgenlegList[0].fWarehouseLocationid,
|
|
|
- fCntrno: this.whgenlegList[0].fCntrno,
|
|
|
- fGoodsval: null,
|
|
|
- fTruckno: null,
|
|
|
- remark: null,
|
|
|
- });
|
|
|
- this.whgenlegVisible = false;
|
|
|
- return
|
|
|
+ if (this.dialogWhgenlegList.length === 0) {
|
|
|
+ this.$message({message: '未勾选信息', type: 'warning'})
|
|
|
+ return false
|
|
|
}
|
|
|
for (let whgen in this.dialogWhgenlegList) {
|
|
|
+ if (!this.form.fMblno || this.form.fMblno === '') {
|
|
|
+ this.$set(this.form, 'fMblno', this.dialogWhgenlegList[whgen].fMblno)
|
|
|
+ }
|
|
|
this.dataList.push({
|
|
|
fMblno: this.dialogWhgenlegList[whgen].fMblno,
|
|
|
fGoodsid: this.dialogWhgenlegList[whgen].fGoodsid,
|
|
|
fCntrtype: null,
|
|
|
fQtyblc: this.dialogWhgenlegList[whgen].fQtyblc,
|
|
|
- fWarehouseLocationids: this.dialogWhgenlegList[whgen]
|
|
|
- .fWarehouseLocationids,
|
|
|
+ fNetweightblc: this.dialogWhgenlegList[whgen].fNetweightblc,
|
|
|
+ fGrossweightblc: this.dialogWhgenlegList[whgen].fGrossweightblc,
|
|
|
+ fWarehouseLocationids: this.dialogWhgenlegList[whgen].fWarehouseLocationids,
|
|
|
fGoodsids: this.dialogWhgenlegList[whgen].fGoodsids,
|
|
|
fGrossweight: 0,
|
|
|
fNetweight: 0,
|
|
@@ -2506,7 +2489,6 @@ export default {
|
|
|
this.whgenlegParams.fCorpid = this.form.fCorpid;
|
|
|
this.whgenlegParams.fWarehouseid = this.form.fWarehouseid;
|
|
|
this.whgenlegParams.fTrademodeid = this.form.fTrademodeid;
|
|
|
-
|
|
|
listWhgenleg(this.whgenlegParams).then((response) => {
|
|
|
this.whgenlegList = response.rows;
|
|
|
console.log(this.whgenlegList);
|
|
@@ -3182,6 +3164,20 @@ export default {
|
|
|
this.download(response.msg);
|
|
|
});
|
|
|
},
|
|
|
+ // 出库件数的计算
|
|
|
+ qtyChange(row) {
|
|
|
+ if (!row.fQty || row.fQty === '') {
|
|
|
+ this.$set(row, 'fNetweight', 0)
|
|
|
+ this.$set(row, 'fGrossweight', 0)
|
|
|
+ return false
|
|
|
+ }
|
|
|
+ // 净重 fNetweightblc
|
|
|
+ // 毛重 fGrossweightblc
|
|
|
+ let netweight = parseFloat(Number(row.fNetweightblc) / Number(row.fQtyblc)).toFixed(6)
|
|
|
+ let grossweigh = parseFloat(Number(row.fGrossweightblc) / Number(row.fQtyblc)).toFixed(6)
|
|
|
+ this.$set(row, 'fNetweight', parseFloat(Number(netweight) * Number(row.fQty)).toFixed(6))
|
|
|
+ this.$set(row, 'fGrossweight', parseFloat(Number(grossweigh) * Number(row.fQty)).toFixed(6))
|
|
|
+ },
|
|
|
deleteRow(index, rows) {
|
|
|
rows.splice(index, 1);
|
|
|
},
|