From be99dff8908d3fc7654e2961abc14fb95278a9bf Mon Sep 17 00:00:00 2001 From: hou <1601990943@qq.com> Date: Thu, 17 Feb 2022 09:46:02 +0800 Subject: [PATCH] no message --- src/i18n/lang/cn.ts | 1 + src/i18n/lang/en.ts | 1 + .../warehouse/LocationInventory/index.vue | 61 +++++++++------ .../warehouse/LocationInventory/model.ts | 2 +- .../warehouse/MaterialInventory/model.ts | 2 +- src/pages/raw/handover/aggregating/model.ts | 54 +++++++------ src/pages/raw/handover/aggregating/order.vue | 1 + .../raw/handover/aggregating/summary.vue | 1 + src/pages/raw/handover/picking/ByOrder.vue | 75 +++++++++--------- src/pages/raw/handover/picking/BySummary.vue | 77 ++++++++++--------- .../raw/warehouse/rowInventory/index.vue | 4 + 11 files changed, 156 insertions(+), 123 deletions(-) diff --git a/src/i18n/lang/cn.ts b/src/i18n/lang/cn.ts index 7a89606..45b04d7 100644 --- a/src/i18n/lang/cn.ts +++ b/src/i18n/lang/cn.ts @@ -49,6 +49,7 @@ export default { workArea_WarehouseClassify: '仓库类', workArea_Confirm: '确定', ReservoirArea: '库区', + Confirm:'是否确认', //原材料菜单 rawMenu_ReceivingGoods: '收货', rawMenu_Handover: '交接', diff --git a/src/i18n/lang/en.ts b/src/i18n/lang/en.ts index c3f0e93..5b5416d 100644 --- a/src/i18n/lang/en.ts +++ b/src/i18n/lang/en.ts @@ -56,6 +56,7 @@ export default { workArea_RegionName: 'Region name', workArea_WorkAreaName: 'Work area name', workArea_WarehouseClassify: 'WH classify', + Confirm:'Confirm', workArea_Confirm: 'Confirm', //jpicker提示 unselected: 'Unchecked', diff --git a/src/pages/product/warehouse/LocationInventory/index.vue b/src/pages/product/warehouse/LocationInventory/index.vue index 147187d..9f5bfab 100644 --- a/src/pages/product/warehouse/LocationInventory/index.vue +++ b/src/pages/product/warehouse/LocationInventory/index.vue @@ -168,31 +168,42 @@ export default class ProductCheckReceipt extends BasePage { this.customToast(this.$t('message.product_Tip3') as string); return; } - const params = { - factoryCode: session.factoryCode, - user: session.loginName, - pddno: this.form.pddNo, - regionCode: this.Some.regionCode, - areaCode: this.Some.areaCode, - whCode: this.Some.whCode, - snFlag: '1', - pdMode: '10', - }; - await this.model.onTakeoutConfirm(params); - if (this.model.status == 'S') { - uni.showToast({ - icon: 'success', - title: this.$t('message.success') as string, - }); - this.form.pddNo = ''; - this.form.barcode = ''; - this.wl = {}; - this.Some = {}; - this.codeList = []; - this.total = ''; - this.areaCode = ''; - this.model.modelList = []; - } + uni.showModal({ + content: this.$t('message.Confirm') as string, + cancelText: this.$t('message.product_Cancel') as string, + confirmText: this.$t('message.workArea_Confirm') as string, + success: async (res: any) => { + if (res.confirm) { + const params = { + factoryCode: session.factoryCode, + user: session.loginName, + pddno: this.form.pddNo, + regionCode: this.Some.regionCode, + areaCode: this.Some.areaCode, + whCode: this.Some.whCode, + snFlag: '1', + pdMode: '10', + }; + await this.model.onTakeoutConfirm(params); + if (this.model.status == 'S') { + uni.showToast({ + icon: 'success', + title: this.$t('message.success') as string, + }); + this.form.pddNo = ''; + this.form.barcode = ''; + this.wl = {}; + this.Some = {}; + this.codeList = []; + this.total = ''; + this.areaCode = ''; + this.model.modelList = []; + } + } else if (res.cancel) { + return; + } + }, + }); } } diff --git a/src/pages/product/warehouse/LocationInventory/model.ts b/src/pages/product/warehouse/LocationInventory/model.ts index 33465ef..7a3813e 100644 --- a/src/pages/product/warehouse/LocationInventory/model.ts +++ b/src/pages/product/warehouse/LocationInventory/model.ts @@ -20,7 +20,7 @@ class OrderInInfo { namespaced: true, dynamic: true, store, - name: 'product.warehouse.wholeCollect', + name: 'product.warehouse.LocationInventory', }) export class wholeCollect extends VuexModule { WlList = []; diff --git a/src/pages/product/warehouse/MaterialInventory/model.ts b/src/pages/product/warehouse/MaterialInventory/model.ts index a4d8d08..b409918 100644 --- a/src/pages/product/warehouse/MaterialInventory/model.ts +++ b/src/pages/product/warehouse/MaterialInventory/model.ts @@ -20,7 +20,7 @@ class OrderInInfo { namespaced: true, dynamic: true, store, - name: 'product.warehouse.wholeCollect', + name: 'product.warehouse.MaterialInventory', }) export class wholeCollect extends VuexModule { WlList = []; diff --git a/src/pages/raw/handover/aggregating/model.ts b/src/pages/raw/handover/aggregating/model.ts index 0326e90..6dbaef9 100644 --- a/src/pages/raw/handover/aggregating/model.ts +++ b/src/pages/raw/handover/aggregating/model.ts @@ -79,12 +79,6 @@ export class AggregatingModule extends VuexModule { clearProOrderList() { this.proOrderList = []; } - /** - * 汇总列表是否全选 - */ - get isAggregateCheckedAll() { - return !this.aggregateList.filter((_: any) => !_.checked).length; - } /** * 全选/取消全选汇总列表 @@ -92,6 +86,7 @@ export class AggregatingModule extends VuexModule { */ @Mutation checkAllAggregateList(checked: boolean) { + console.log('this.nodel.aggregateList222', this.aggregateList); this.aggregateList = this.aggregateList.map((item: any) => { item.checked = checked; if (item.checked) { @@ -102,7 +97,23 @@ export class AggregatingModule extends VuexModule { return item; }); } - + /** + * 全选/取消按单列表 + * @param checked + */ + @Mutation + checkAllOrderList(checked: boolean) { + console.log('this.nodel.orderList222', this.orderList); + this.orderList = this.orderList.map((item: any) => { + item.checked = checked; + if (item.checked) { + item.hvAmount = item.totalMoAmount - item.totalHvAmount; + } else { + item.hvAmount = 0; + } + return item; + }); + } /** * 列表提交-汇总交接 * @param params @@ -161,7 +172,12 @@ export class AggregatingModule extends VuexModule { const newItem = { ...original, hvAmount }; this.accessoryList.splice(index, 1, newItem); } - + /** + * 汇总列表是否全选 + */ + get isAggregateCheckedAll() { + return !this.aggregateList.filter((_: any) => !_.checked).length; + } /** * 按单列表是否全选 */ @@ -179,22 +195,6 @@ export class AggregatingModule extends VuexModule { checked, })); } - /** - * 全选/取消按单列表 - * @param checked - */ - @Mutation - checkAllOrderList(checked: boolean) { - this.orderList = this.orderList.map((item: any) => { - item.checked = checked; - if (item.checked) { - item.hvAmount = item.totalMoAmount - item.totalHvAmount; - } else { - item.hvAmount = 0; - } - return item; - }); - } /** * 查询看单号 @@ -242,6 +242,7 @@ export class AggregatingModule extends VuexModule { vm.customToast(vm.$t('message.Pi_NoDataFound') as any); return { aggregateList }; } + console.log('aggregateList', aggregateList); return { aggregateList }; } @@ -254,10 +255,13 @@ export class AggregatingModule extends VuexModule { const { queryParams, proOrderResultList } = params; await http.post(url.sumscan.lock.list, queryParams); const orderList = cloneDeep(proOrderResultList); - console.log('orderList', orderList); + orderList.map((item: any) => { + item.checked = false; + }); if (orderList.length == 0) { return { orderList }; } + console.log('orderList', orderList); return { orderList }; } /** diff --git a/src/pages/raw/handover/aggregating/order.vue b/src/pages/raw/handover/aggregating/order.vue index 90211d8..c1527e8 100644 --- a/src/pages/raw/handover/aggregating/order.vue +++ b/src/pages/raw/handover/aggregating/order.vue @@ -152,6 +152,7 @@ export default class AggregatingOrder extends BasePage { * 全选 */ onSelectAll() { + console.log('this.nodel.orderList111',this.model.orderList) model.checkAllOrderList(!model.isOrderCheckedAll); } clickIndex(e: any) { diff --git a/src/pages/raw/handover/aggregating/summary.vue b/src/pages/raw/handover/aggregating/summary.vue index 6269ab2..c6405b6 100644 --- a/src/pages/raw/handover/aggregating/summary.vue +++ b/src/pages/raw/handover/aggregating/summary.vue @@ -175,6 +175,7 @@ export default class AggregatingSummary extends BasePage { * 全选 */ onSelectAll() { + console.log('this.nodel.aggregateList111',this.model.aggregateList) model.checkAllAggregateList(!model.isAggregateCheckedAll); } diff --git a/src/pages/raw/handover/picking/ByOrder.vue b/src/pages/raw/handover/picking/ByOrder.vue index 1f2450b..10d2017 100644 --- a/src/pages/raw/handover/picking/ByOrder.vue +++ b/src/pages/raw/handover/picking/ByOrder.vue @@ -30,12 +30,15 @@ {{ $t('message.CommissionedThisNumber') }}: + + {{ $t('message.product_add') }} + - + @@ -171,16 +174,16 @@ export default class RawReceiptDetail extends BasePage { this.LocationList = []; this.qty = ''; await this.model.queryItemLoc({ - workArea:session.workareaCode, - loginName:session.loginName, - sendSpot:null, - materialCode:this.some.materialCode, - factoryCode:session.factoryCode - }) + workArea: session.workareaCode, + loginName: session.loginName, + sendSpot: null, + materialCode: this.some.materialCode, + factoryCode: session.factoryCode, + }); this.Location = []; - this.Location = this.model.LocList - console.log('this.Location',this.Location) - this.wlCode = this.Location[0] + this.Location = this.model.LocList; + console.log('this.Location', this.Location); + this.wlCode = this.Location[0]; } Add() { if (this.qty == '' || this.wlCode == '') { @@ -423,44 +426,46 @@ export default class RawReceiptDetail extends BasePage { } .library { width: 100%; - height: 100rpx; - display: flex; + height: 200rpx; + // display: flex; + display: block; .library-left { - width: 50%; - height: 100%; - display: flex; - view { - width: 230rpx; - line-height: 100rpx; - text-align: center; - } + width: 100%; + height: 100rpx; + padding-left: 56rpx; + // display: flex; + // view { + // width: 230rpx; + // line-height: 100rpx; + // text-align: center; + // } } .library-right { - width: 50%; - height: 100%; + width: 100%; + height: 100rpx; + padding-left: 56rpx; display: flex; .library-right-title { width: 120rpx; height: 100%; line-height: 100rpx; - text-align: center; } .input { width: 200rpx; height: 70rpx; margin-top: 15rpx; - margin-left: 15rpx; + margin-left: 0rpx; + } + .add { + width: 200rpx; + height: 100rpx; + position: relative; + button { + position: absolute; + top: 10rpx; + right: 20rpx; + } } - } - } - .add { - width: 100%; - height: 100rpx; - position: relative; - button { - position: absolute; - top: 10rpx; - right: 20rpx; } } .bottom-bar { diff --git a/src/pages/raw/handover/picking/BySummary.vue b/src/pages/raw/handover/picking/BySummary.vue index e37af4c..d57f800 100644 --- a/src/pages/raw/handover/picking/BySummary.vue +++ b/src/pages/raw/handover/picking/BySummary.vue @@ -26,17 +26,20 @@ {{ $t('message.CommissionedLocation') }}: - + {{ $t('message.CommissionedThisNumber') }}: + + {{ $t('message.product_add') }} + - + @@ -160,16 +163,16 @@ export default class RawReceiptDetail extends BasePage { this.LocationList = []; this.qty = ''; await this.model.queryItemLoc({ - workArea:session.workareaCode, - loginName:session.loginName, - sendSpot:null, - materialCode:this.some.materialCode, - factoryCode:session.factoryCode - }) + workArea: session.workareaCode, + loginName: session.loginName, + sendSpot: null, + materialCode: this.some.materialCode, + factoryCode: session.factoryCode, + }); this.Location = []; - this.Location = this.model.LocList - console.log('this.Location',this.Location) - this.wlCode = this.Location[0] + this.Location = this.model.LocList; + console.log('this.Location', this.Location); + this.wlCode = this.Location[0]; } //添加库位和数量到数据和表格中 Add() { @@ -415,44 +418,46 @@ export default class RawReceiptDetail extends BasePage { } .library { width: 100%; - height: 100rpx; - display: flex; + height: 200rpx; + // display: flex; + display: block; .library-left { - width: 50%; - height: 100%; - display: flex; - view { - width: 230rpx; - line-height: 100rpx; - text-align: center; - } + width: 100%; + height: 100rpx; + padding-left: 56rpx; + // display: flex; + // view { + // width: 230rpx; + // line-height: 100rpx; + // text-align: center; + // } } .library-right { - width: 50%; - height: 100%; + width: 100%; + height: 100rpx; + padding-left: 56rpx; display: flex; .library-right-title { width: 120rpx; height: 100%; line-height: 100rpx; - text-align: center; } .input { width: 200rpx; height: 70rpx; margin-top: 15rpx; - margin-left: 15rpx; + margin-left: 0rpx; + } + .add { + width: 200rpx; + height: 100rpx; + position: relative; + button { + position: absolute; + top: 10rpx; + right: 20rpx; + } } - } - } - .add { - width: 100%; - height: 100rpx; - position: relative; - button { - position: absolute; - top: 10rpx; - right: 20rpx; } } .bottom-bar { diff --git a/src/pages/raw/warehouse/rowInventory/index.vue b/src/pages/raw/warehouse/rowInventory/index.vue index 33e17c3..3b4a186 100644 --- a/src/pages/raw/warehouse/rowInventory/index.vue +++ b/src/pages/raw/warehouse/rowInventory/index.vue @@ -8,15 +8,19 @@ + + + +