|
@@ -46,7 +46,8 @@
|
|
|
</template>
|
|
|
<template slot="storageId">
|
|
|
<el-cascader v-model="form.storageId" :options="storagetreeList" :show-all-levels="false"
|
|
|
- :disabled="detailData.status == 1" :props="{ checkStrictly: true, emitPath: false, label: 'title' }"
|
|
|
+ :disabled="detailData.status == 1"
|
|
|
+ :props="{ checkStrictly: true, emitPath: false, label: 'title' }"
|
|
|
clearable @change="storagetreeChange">
|
|
|
</el-cascader>
|
|
|
</template>
|
|
@@ -130,7 +131,8 @@
|
|
|
</template>
|
|
|
</avue-crud>
|
|
|
</trade-card>
|
|
|
- <fee-info ref="feeInfo" :orderFeesList="orderFeesList" :disabled="!(form.status == 2 || form.status == 0 || !form.status)"
|
|
|
+ <fee-info ref="feeInfo" :orderFeesList="orderFeesList"
|
|
|
+ :disabled="!(form.status == 2 || form.status == 0 || !form.status)"
|
|
|
feeUrl="/blade-purchase-sales/entranceOrder/removeOrderFees" :optionType="'CMY'" :itemType="'D'"
|
|
|
:inCropId="true" @beforeFinance="beforeFinance" :delType="2" :billingShow="false"/>
|
|
|
<!-- <upload-file ref="uploadFile" title="合同附件" :disabled="detailData.status == 3" :orderFilesList="orderFilesList"
|
|
@@ -242,7 +244,7 @@ export default {
|
|
|
return {
|
|
|
activeName: 'searchList',
|
|
|
checkData: {},
|
|
|
- search:{},
|
|
|
+ search: {},
|
|
|
page: {
|
|
|
pageSize: 10,
|
|
|
currentPage: 1,
|
|
@@ -255,8 +257,8 @@ export default {
|
|
|
},
|
|
|
loading: false,
|
|
|
dialogVisible: false,
|
|
|
- dialogList:[],
|
|
|
- goodsList:[],
|
|
|
+ dialogList: [],
|
|
|
+ goodsList: [],
|
|
|
checkDialog: false,
|
|
|
form: {},
|
|
|
checkScheduleDialog: false,
|
|
@@ -379,13 +381,13 @@ export default {
|
|
|
}
|
|
|
],
|
|
|
span: 6
|
|
|
- },{
|
|
|
+ }, {
|
|
|
label: "计划出库数量",
|
|
|
prop: "purchaseQuantity",
|
|
|
- value:0,
|
|
|
+ value: 0,
|
|
|
minRows: 1,
|
|
|
span: 6
|
|
|
- },{
|
|
|
+ }, {
|
|
|
label: "计划品名",
|
|
|
prop: "planGoodsName",
|
|
|
minRows: 1,
|
|
@@ -412,7 +414,7 @@ export default {
|
|
|
oldorderFeesList: [],
|
|
|
oldorderFilesList: [],
|
|
|
roleName: localStorage.getItem("roleName"),
|
|
|
- selectionList:[]
|
|
|
+ selectionList: []
|
|
|
};
|
|
|
},
|
|
|
props: {
|
|
@@ -426,18 +428,6 @@ export default {
|
|
|
uploadFile,
|
|
|
check
|
|
|
},
|
|
|
- watch: {
|
|
|
- form: {
|
|
|
- // handler() {
|
|
|
- // if (this.form.status > 0) {
|
|
|
- // this.$set(this.option, 'disabled', true)
|
|
|
- // // this.$set(this.findObject(this.tableOption.column, "remarks"),'disabled',true)
|
|
|
- // } else {
|
|
|
- // this.$set(this.option, 'disabled', false)
|
|
|
- // }
|
|
|
- // }
|
|
|
- }
|
|
|
- },
|
|
|
async created() {
|
|
|
if (this.detailData.status == 3) {
|
|
|
this.option.disabled = true;
|
|
@@ -445,11 +435,12 @@ export default {
|
|
|
if (this.detailData.status == 1) {
|
|
|
this.option.disabled = true;
|
|
|
}
|
|
|
+ console.log(this.detailData)
|
|
|
if (this.detailData.id) {
|
|
|
this.getDetail(this.detailData.id);
|
|
|
}
|
|
|
- this.tableOption = await this.getColumnData(this.getColumnName(191),tableOption);
|
|
|
- this.tableOptionTwo = await this.getColumnData(this.getColumnName(191.1),tableOptionTwo);
|
|
|
+ this.tableOption = await this.getColumnData(this.getColumnName(191), tableOption);
|
|
|
+ this.tableOptionTwo = await this.getColumnData(this.getColumnName(191.1), tableOptionTwo);
|
|
|
getStoragetree().then(res => {
|
|
|
this.storagetreeList = res.data.data;
|
|
|
})
|
|
@@ -494,23 +485,30 @@ export default {
|
|
|
this.page.total = 0
|
|
|
}
|
|
|
},
|
|
|
- selectionChange(list){
|
|
|
+ selectionChange(list) {
|
|
|
this.selectionList = list
|
|
|
},
|
|
|
- confirmImport(){
|
|
|
+ confirmImport() {
|
|
|
+ let map = new Map();
|
|
|
+ for (let item of this.selectionList.concat(this.goodsListSave)) {
|
|
|
+ if (!map.has(item.id)) {
|
|
|
+ map.set(item.id, item);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ this.goodsListSave = [...map.values()];
|
|
|
let data = []
|
|
|
- for (let it in this.goodsListSave){
|
|
|
- for (let item in this.goodsListSave){
|
|
|
- for (let li of this.itemsVOList){
|
|
|
- if (this.goodsListSave[item].billNo == li.billNo) return this.$message.warning('第'+Number(Number(item)+1)+'条已存在,请勿重复导入!')
|
|
|
+ for (let it in this.goodsListSave) {
|
|
|
+ for (let item in this.goodsListSave) {
|
|
|
+ for (let li of this.itemsVOList) {
|
|
|
+ if (this.goodsListSave[item].billNo == li.billNo) return this.$message.warning('第' + Number(Number(item) + 1) + '条已存在,请勿重复导入!')
|
|
|
}
|
|
|
}
|
|
|
data.push({
|
|
|
...this.goodsListSave[it],
|
|
|
- srcItemId:this.goodsListSave[it].id,
|
|
|
+ srcItemId: this.goodsListSave[it].id,
|
|
|
$cellEdit: true
|
|
|
})
|
|
|
- delete data[data.length-1].id
|
|
|
+ delete data[data.length - 1].id
|
|
|
}
|
|
|
this.itemsVOList = this.itemsVOList.concat(data)
|
|
|
this.goodsListSave = []
|
|
@@ -548,6 +546,8 @@ export default {
|
|
|
this.getWorkDicts("unit").then(res => {
|
|
|
this.findObject(this.tableOption.column, "unit").dicData =
|
|
|
res.data.data;
|
|
|
+ this.findObject(this.tableOptionTwo.column, "unit").dicData =
|
|
|
+ res.data.data;
|
|
|
});
|
|
|
},
|
|
|
cellStyle() {
|
|
@@ -669,6 +669,8 @@ export default {
|
|
|
res.data.data.itemsVOList.forEach(e => {
|
|
|
e.storageInQuantity = e.balanceNumber
|
|
|
e.srcItemId = e.id
|
|
|
+ e.storageInQuantity = e.balanceNumber
|
|
|
+ e.storageAmount = e.balanceMoney
|
|
|
delete e.id
|
|
|
delete e.forklift
|
|
|
delete e.carry
|
|
@@ -744,13 +746,13 @@ export default {
|
|
|
if (status == "goBack") {
|
|
|
this.$emit("goBack");
|
|
|
}
|
|
|
- if (!this.detailData.id){
|
|
|
+ if (!this.detailData.id) {
|
|
|
this.detailData.id = res.data.data.id
|
|
|
}
|
|
|
this.getDetail(res.data.data.id)
|
|
|
}).finally(() => {
|
|
|
- this.subLoading = false;
|
|
|
- });
|
|
|
+ this.subLoading = false;
|
|
|
+ });
|
|
|
} else {
|
|
|
return false;
|
|
|
}
|
|
@@ -759,7 +761,7 @@ export default {
|
|
|
//请核
|
|
|
auditCheck() {
|
|
|
let orderFeesList = this.$refs.feeInfo.submitData();
|
|
|
- if (orderFeesList.length == 0) {
|
|
|
+ if ((orderFeesList.length == 0 && this.form.status == 2)) {
|
|
|
this.$confirm("没有应收费用,是否继续提交?", {
|
|
|
confirmButtonText: "确定",
|
|
|
cancelButtonText: "取消",
|
|
@@ -1016,8 +1018,12 @@ export default {
|
|
|
this.$refs.crudTwo.$refs.dialogColumn.columnBox = false;
|
|
|
}
|
|
|
},
|
|
|
- searchChange(params,done) {
|
|
|
- this.onLoad(this.page,this.search);
|
|
|
+ searchChange(params, done) {
|
|
|
+ if (this.search.stockTime){
|
|
|
+ this.search.stockTimeStart = this.search.stockTime[0]
|
|
|
+ this.search.stockTimeEnd = this.search.stockTime[1]
|
|
|
+ }
|
|
|
+ this.onLoad(this.page, this.search);
|
|
|
done();
|
|
|
},
|
|
|
//商品查询
|
|
@@ -1025,10 +1031,10 @@ export default {
|
|
|
let obj = this.deepClone(Object.assign(params, this.search));
|
|
|
this.loading = true;
|
|
|
scanningCodeAddPc({
|
|
|
- storageId:this.form.storageId,
|
|
|
- purchaserId:this.form.purchaserId,
|
|
|
+ storageId: this.form.storageId,
|
|
|
+ purchaserId: this.form.purchaserId,
|
|
|
...obj
|
|
|
- }).then(res=>{
|
|
|
+ }).then(res => {
|
|
|
this.dialogList = res.data.data.records
|
|
|
this.goodsList = res.data.data.records
|
|
|
this.page.total = res.data.data.total;
|