diff --git a/src/i18n/lang/cn.ts b/src/i18n/lang/cn.ts index f902b10..3b10134 100644 --- a/src/i18n/lang/cn.ts +++ b/src/i18n/lang/cn.ts @@ -152,7 +152,7 @@ export default { Pi_OrderNoNotSelected: '未选中订单号', Pi_NoDataFound: '未查询到数据', differences: '差异数量', - Pi_NoData: '数据为0!', + Pi_NoData: '已经没有数据可操作', Pi_QueryResults: '查询结果', Pi_Summary: '汇总', Pi_ByOrder: '按单', diff --git a/src/i18n/lang/en.ts b/src/i18n/lang/en.ts index d924b3c..b886219 100644 --- a/src/i18n/lang/en.ts +++ b/src/i18n/lang/en.ts @@ -153,7 +153,7 @@ export default { Pi_InputFactory: 'Please input factory code', Pi_OrderNoNotSelected: 'Order number not selected', Pi_NoDataFound: 'No Data Found', - Pi_NoData: 'The data is 0!', + Pi_NoData: 'No data to operate', Pi_QueryResults: 'Query result', Pi_Summary: 'By Summary', Pi_ByOrder: 'By Order', diff --git a/src/pages/login/login/index.vue b/src/pages/login/login/index.vue index cd5bce5..50795a9 100644 --- a/src/pages/login/login/index.vue +++ b/src/pages/login/login/index.vue @@ -150,7 +150,7 @@ export default class LoginPage extends BasePage { console.log('image', this.image); console.log('Version////', this.Version); } - Version = '1.0.9'; + Version = '1.0.11'; compareVersion(version1: any, version2: any) { //如果version1 大 会返回1 &&& 如果version2 大 会返回 -1 const newVersion1 = `${version1}`.split('.').length < 3 ? `${version1}`.concat('.0') : `${version1}`; diff --git a/src/pages/raw/handover/aggregating/model.ts b/src/pages/raw/handover/aggregating/model.ts index 65603c8..f632861 100644 --- a/src/pages/raw/handover/aggregating/model.ts +++ b/src/pages/raw/handover/aggregating/model.ts @@ -17,7 +17,7 @@ export class AggregatingModule extends VuexModule { proOrderList = []; param: any; orderOutIdListParams: any; - + SubmitCode: any = ''; /** * 查询结果列表 */ @@ -104,9 +104,18 @@ export class AggregatingModule extends VuexModule { * 列表提交-汇总交接 * @param params */ - @Action + @MutationAction async uploadAggregateList(params: any) { - return http.post(url.sumscan.u.hzlist, params); + const result: any = await http.post(url.sumscan.u.hzlist, params); + const SubmitCode = result.code; + console.log('yayayyayyayayayyayyayayayyay', SubmitCode); + uni.showToast({ + //icon: 'success', + title: 'success', + duration: 2000, + image: '/static/icons/icon-51.png', + }); + return { SubmitCode }; } /** @@ -221,7 +230,7 @@ export class AggregatingModule extends VuexModule { // icon: 'none', // title: 'No Data Found!', // }); - vm.customToast(vm.$t('message.Pi_NoData') as any); + vm.customToast(vm.$t('message.Pi_NoDataFound') as any); return { aggregateList }; } console.log('aggregateList', aggregateList); @@ -263,15 +272,18 @@ export class AggregatingModule extends VuexModule { * 列表提交-按单交接 * @param params */ - @Action + @MutationAction async uploadOrderList(params: any) { - await http.post(url.sumscan.u.order, params); + const result: any = await http.post(url.sumscan.u.order, params); + const SubmitCode = result.code; + console.log('yayayyayyayayayyayyayayayyay', SubmitCode); uni.showToast({ //icon: 'success', title: 'success', duration: 2000, image: '/static/icons/icon-51.png', }); + return { SubmitCode }; } /** diff --git a/src/pages/raw/handover/aggregating/order.vue b/src/pages/raw/handover/aggregating/order.vue index 4495732..e5a65b1 100644 --- a/src/pages/raw/handover/aggregating/order.vue +++ b/src/pages/raw/handover/aggregating/order.vue @@ -266,13 +266,47 @@ export default class AggregatingOrder extends BasePage { this.submitForm.password = ''; this.amountForm.amount = ''; // await this.model.queryProOrder(this.model.isFormChange); + // + console.log('123456789yayayyayayayya', this.model.SubmitCode); + if (this.model.SubmitCode == '1') { + const ServeUrl = JSON.parse(uni.getStorageSync('__GWMS_APP_STATE_DATA__')); + this.uni.request({ + url: ServeUrl.server.address + url.sumscan.query.ordoutlist, + method: 'POST', + data: this.model.param, + success: (res: any) => { + if (res.data.code != '0' && res.data.list != null) { + // this.empty(); + //this.resetForm(); + this.chaxun(); + } else if (res.data.code == '0' && res.data.list == null) { + //this.customToast(this.$t('message.Pi_NoData') as string); + uni.showToast({ + //icon: 'success', + //duration: 2000, + title: this.$t('message.Pi_NoData') as string, + icon: 'none', + }); + setTimeout(() => { + this.toPage(this.page.raw.handover.aggregating.index); + }, 2000); + + //this.empty(); + //this.form.documentNo = ''; + } + }, + }); + } + + this.$submitForm.setRules(this.submitFormRules); + } + //查询 + async chaxun() { await this.model.queryProOrderResult(this.model.param); await this.model.queryOrderList({ queryParams: this.model.orderOutIdListParams, proOrderResultList: this.model.proOrderResultList, }); - - this.$submitForm.setRules(this.submitFormRules); } /** * 解锁 diff --git a/src/pages/raw/handover/aggregating/summary.vue b/src/pages/raw/handover/aggregating/summary.vue index 34f35de..fa3e309 100644 --- a/src/pages/raw/handover/aggregating/summary.vue +++ b/src/pages/raw/handover/aggregating/summary.vue @@ -308,8 +308,36 @@ export default class AggregatingSummary extends BasePage { this.submitForm.password = ''; this.isBusinessFinished = true; // await this.model.queryProOrder(this.model.isFormChange); - await this.model.queryProOrderResult(this.model.param); - await this.model.queryAggregateList(this.model.orderOutIdListParams); + console.log('123456789yayayyayayayya', this.model.SubmitCode); + if (this.model.SubmitCode == '1') { + const ServeUrl = JSON.parse(uni.getStorageSync('__GWMS_APP_STATE_DATA__')); + this.uni.request({ + url: ServeUrl.server.address + url.sumscan.query.ordoutlist, + method: 'POST', + data: this.model.param, + success: (res: any) => { + if (res.data.code != '0' && res.data.list != null) { + // this.empty(); + //this.resetForm(); + this.chaxun(); + } else if (res.data.code == '0' && res.data.list == null) { + // this.customToast(this.$t('message.Pi_NoData') as string); + // this.toPage(this.page.raw.handover.aggregating.index); + uni.showToast({ + //icon: 'success', + //duration: 2000, + title: this.$t('message.Pi_NoData') as string, + icon: 'none', + }); + setTimeout(() => { + this.toPage(this.page.raw.handover.aggregating.index); + }, 2000); + //this.empty(); + //this.form.documentNo = ''; + } + }, + }); + } // model.aggregateList.forEach((item: any, index: any) => { // if (item.materialCode == this.spliceItem) { // model.aggregateList.splice(index, 1); @@ -323,6 +351,11 @@ export default class AggregatingSummary extends BasePage { /**this.$amountForm.setRules(this.amountFormRules);**/ this.$submitForm.setRules(this.submitFormRules); } + //查询 + async chaxun() { + await this.model.queryProOrderResult(this.model.param); + await this.model.queryAggregateList(this.model.orderOutIdListParams); + } /** * 解锁 */ diff --git a/src/pages/raw/handover/picking/BySummary.vue b/src/pages/raw/handover/picking/BySummary.vue index c054232..faf46b1 100644 --- a/src/pages/raw/handover/picking/BySummary.vue +++ b/src/pages/raw/handover/picking/BySummary.vue @@ -292,7 +292,13 @@ export default class RawReceiptDetail extends BasePage { }; await this.model.saveAggregateUpload(params); if (this.model.code == '1') { - this.customToast(this.$t('message.Warehouse_Tip9') as any); + //this.customToast(this.$t('message.Warehouse_Tip9') as any); + uni.showToast({ + //icon: 'success', + duration: 2000, + title: this.$t('message.Warehouse_Tip9') as string, + image: '/static/icons/icon-51.png', + }); // this.GetLocation(); setTimeout(() => { this.onAggregate();