cosmoim-852 fix 功能优化调整

master
hou 3 years ago
parent 2c91bf41ce
commit 77d360fb7a

@ -128,7 +128,7 @@ export default {
ReturnedMaterials: 'Return MAT',
Inventory_query: 'Inventory query',
Pi_PickingQuery: 'Pick up query',
Pi_OrderNo: 'Order No',
Pi_OrderNo: 'Order',
Pi_factory: 'Factory',
Pi_materielNo: 'MAT code',
Pi_order: 'Order Query',

@ -39,7 +39,7 @@ export const headers = [
},
{
label: vm.$t('message.Container'),
key: 'user_defined6',
key: 'userDefined6',
width: 400,
},
];

@ -198,7 +198,7 @@ export default class dnReceiptDom extends BasePage {
});
this.every = this.material[0];
this.materialIndex = 0;
await this.QueryLoc();
// await this.QueryLoc();
}
// receiptAmount requestAmount
materialChoice(e: any) {
@ -207,7 +207,7 @@ export default class dnReceiptDom extends BasePage {
if (item.materialCode == e.pickerName.value) {
this.every = item;
this.materialIndex = index;
await this.QueryLoc();
// await this.QueryLoc();
return;
}
});
@ -232,8 +232,14 @@ export default class dnReceiptDom extends BasePage {
value: this.Container.locCode + '(' + this.Container.sendSpot + ')',
sendSpot: this.Container.sendSpot,
};
this.Loc = [];
this.Loc.push(arr);
this.wlCode = this.Loc[0];
if (this.Container.cpRef4 == null) {
this.nowAmount = this.Container.qty;
} else {
this.nowAmount = parseFloat(this.Container.qty) - parseFloat(this.Container.cpRef4);
}
}
//
Add() {
@ -241,36 +247,36 @@ export default class dnReceiptDom extends BasePage {
this.customToast(this.$t('message.scanningContainer') as any);
return;
}
// if (this.Container.cpRef4 == null) {
// if (parseFloat(this.nowAmount) > this.Container.qty) {
// this.customToast(this.$t('message.AppendMateriel3') as any);
// return;
// }
// } else {
// if (parseFloat(this.nowAmount) > this.Container.qty - parseFloat(this.Container.cpRef4)) {
// this.customToast(this.$t('message.AppendMateriel3') as any);
// return;
// }
// }
// let codenum: number = 0;
// if (this.list.length != 0) {
// this.list.forEach((item: any) => {
// if (item.barCode == this.Container.barcode) {
// num += item.receiptAmount;
// }
// });
// }
// if (this.Container.cpRef4 == null) {
// if (parseFloat(this.nowAmount) + codenum > this.Container.qty) {
// this.customToast(this.$t('message.AppendMateriel3') as any);
// return;
// }
// } else {
// if (parseFloat(this.nowAmount) + codenum > this.Container.qty - parseFloat(this.Container.cpRef4)) {
// this.customToast(this.$t('message.AppendMateriel3') as any);
// return;
// }
// }
if (this.Container.cpRef4 == null) {
if (parseFloat(this.nowAmount) > parseFloat(this.Container.qty)) {
this.customToast(this.$t('message.AppendMateriel3') as any);
return;
}
} else {
if (parseFloat(this.nowAmount) > parseFloat(this.Container.qty) - parseFloat(this.Container.cpRef4)) {
this.customToast(this.$t('message.AppendMateriel3') as any);
return;
}
}
let codenum = 0;
if (this.list.length != 0) {
this.list.forEach((item: any) => {
if (item.barCode == this.Container.barcode) {
num += parseFloat(item.nowAmount);
}
});
}
if (this.Container.cpRef4 == null) {
if (parseFloat(this.nowAmount) + codenum > this.Container.qty) {
this.customToast(this.$t('message.AppendMateriel3') as any);
return;
}
} else {
if (parseFloat(this.nowAmount) + codenum > this.Container.qty - parseFloat(this.Container.cpRef4)) {
this.customToast(this.$t('message.AppendMateriel3') as any);
return;
}
}
if (!this.every) {
this.customToast(this.$t('message.Commission_tips6') as any);
return;
@ -317,8 +323,8 @@ export default class dnReceiptDom extends BasePage {
factoryCode: this.session.factoryCode,
wlCode: this.wlCode.label,
nowAmount: this.nowAmount,
// barCode: this.Container.barcode,
barCode: this.Barcode,
barCode: this.Container.barcode,
// barCode: this.Barcode,
};
this.list.push(arr);
this.material[this.materialIndex].outAmount += parseFloat(this.list[this.list.length - 1].nowAmount);

@ -323,7 +323,7 @@ export default class dnReceiptDom extends BasePage {
};
await this.model.searchBarcode(params);
this.Container = this.model.ContainerCode;
this.receiptAmount = this.Container.requestAmount;
this.receiptAmount = parseFloat(this.Container.requestAmount);
}
//
Add() {

@ -286,7 +286,7 @@ export class ReturningModule extends VuexModule {
ContainerCode: any = '';
@MutationAction
async searchBarcode(params: any) {
const res: any = await http.post(url.auth.query.barcode, {
const res: any = await http.post(url.auth.query.queryContainer, {
factoryCode: session.factoryCode,
loginName: session.loginName,
dnNo: params.dnNo,

@ -10,8 +10,8 @@
<u-form class="form" ref="form" :model="form" :error-type="['toast']" label-width="150rpx">
<!-- 订单号 -->
<u-form-item :required="true" :label="$t('message.Pi_OrderNo')" prop="prdOrder">
<u-search :placeholder="$t('message.po_PleaseInput')" v-model.trim="form.prdOrder" @search="query" :show-action="false"></u-search>
<u-button size="mini" style="margin-left: 10rpx" type="primary" @click="query">{{ $t('message.Query') }} </u-button>
<u-search :placeholder="$t('message.po_PleaseInput')" v-model.trim="form.prdOrder" @search="empty" :show-action="false"></u-search>
<u-button size="mini" style="margin-left: 10rpx" type="primary" @click="empty">{{ $t('message.Query') }} </u-button>
</u-form-item>
<!-- 物料号 -->
<u-form-item :required="true" :label="$t('message.Pi_materielNo')" prop="materialCode">
@ -178,6 +178,10 @@ export default class returningDom extends BasePage {
// }
}
Add() {
if (this.qty == '') {
this.customToast(this.$t('message.Summary_PleaseInputNumber') as string);
return;
}
if (parseFloat(this.qty) > parseFloat(this.form.totalAmount)) {
this.customToast(this.$t('message.return_Tip4') as string);
return;
@ -266,6 +270,7 @@ export default class returningDom extends BasePage {
this.wlCode = '';
this.checkindex = 0;
this.Location = [];
this.Barcode = '';
await this.query();
}
accSubtract(num1: any, num2: any) {

@ -315,6 +315,7 @@ export default class RawReceiptDetail extends BasePage {
value: this.Container.locCode + '(' + this.Container.sendSpot + ')',
sendSpot: this.Container.sendSpot,
};
this.Location = [];
this.Location.push(arr);
this.wlCode = this.Location[0];
let num = 0;
@ -413,7 +414,7 @@ export default class RawReceiptDetail extends BasePage {
let lineData = e.lineData;
let i: any;
this.model.blDetailList.forEach((item: any, index: any) => {
if (item.materialCode == lineData.materialCode && item.sendSpot == lineData.sendSpot) {
if (item.sapSupplyId == lineData.sapSupplyId) {
i = index;
}
});
@ -430,7 +431,10 @@ export default class RawReceiptDetail extends BasePage {
num += parseFloat(item.qty);
});
this.model.blDetailList[i].fillAmount = num;
this.model.blDetailList[i].totalFillAmount -= lineData.qty;
console.log('this.model.blDetailList[i].totalFillAmount111', this.model.blDetailList[i].totalFillAmount);
this.model.blDetailList[i].totalFillAmount -= parseFloat(lineData.qty);
console.log('this.model.blDetailList[i].totalFillAmount222', this.model.blDetailList[i].totalFillAmount);
console.log('lineData.qty', lineData.qty);
} else if (res.cancel) {
return;
}
@ -445,7 +449,6 @@ export default class RawReceiptDetail extends BasePage {
this.model.blDetailList[this.someIndex].fillAmount = num;
this.some.fillAmount = num;
this.model.blDetailList[this.someIndex].totalFillAmount += parseFloat(this.qty);
console.log('this.model.blDetailList', this.model.blDetailList);
}
async bill() {
if (this.some == {} || this.some.prdOrder == null) {

@ -73,7 +73,7 @@
</view>
<view class="library-right">
<view class="library-right-title">{{ $t('message.CommissionedThisNumber') }}</view>
<u-input v-model="receiptAmount" :placeholder="$t('message.po_PleaseInput')" type="number" :border="border" class="input" />
<u-input v-model="receiptAmount" :disabled="disabled" :placeholder="$t('message.po_PleaseInput')" type="number" :border="border" class="input" />
</view>
</view>
<view class="config">
@ -113,6 +113,7 @@ import { url } from '@/utils/url';
})
export default class dnReceiptDom extends BasePage {
model = model;
disabled = false;
form: any = {
documentNo: '',
};
@ -328,6 +329,8 @@ export default class dnReceiptDom extends BasePage {
console.log('params', params);
await this.model.searchBarcode(params);
this.Container = this.model.ContainerCode;
this.receiptAmount = parseFloat(this.Container.requestAmount);
this.disabled = true;
}
//
Add() {

@ -19,7 +19,7 @@
</view>
<view class="library">
<view class="library-left">
<view>{{ $t('message.CommissionedLocation') }}</view>
<view style="width: 50px">{{ $t('message.CommissionedLocation') }}</view>
<jPicker sureColor="#ff0000" style="width: 230rpx" @bindpicker="LocationChoice" showKey="value" valKey="value" :val="wl.value" class="search" :options="Location" />
</view>
</view>

Loading…
Cancel
Save