From 6702628fc3ea1c924c350fe60d685324dafcc8f4 Mon Sep 17 00:00:00 2001
From: niexiting <85552560@qq.com>
Date: Fri, 19 Jul 2024 19:59:14 +0800
Subject: [PATCH 1/3] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E7=9B=98=E7=82=B9?=
=?UTF-8?q?=E7=9B=B8=E5=85=B3=E7=BB=84=E4=BB=B6?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/common/directory.js | 32 +-
src/mycomponents/detail/comDetailCard.vue | 14 +-
.../package/PackageAndItemCard.vue | 53 +++
src/mycomponents/qty/recommendQty.vue | 8 +-
src/pages.json | 37 ++
src/pages/count/coms/comFuzzyCountJobCard.vue | 49 ++
src/pages/count/job/fuzzyCountDetail.vue | 436 +++++++++++++++++
src/pages/count/job/fuzzyCountJob.vue | 448 ++++++++++++++++++
src/pages/index/index.vue | 2 +-
src/pages/putaway/record/putawayRecord.vue | 1 -
10 files changed, 1064 insertions(+), 16 deletions(-)
create mode 100644 src/mycomponents/package/PackageAndItemCard.vue
create mode 100644 src/pages/count/coms/comFuzzyCountJobCard.vue
create mode 100644 src/pages/count/job/fuzzyCountDetail.vue
create mode 100644 src/pages/count/job/fuzzyCountJob.vue
diff --git a/src/common/directory.js b/src/common/directory.js
index fcdfc188..e922c360 100644
--- a/src/common/directory.js
+++ b/src/common/directory.js
@@ -1,6 +1,6 @@
let jobStatusList = [];
let itemStatusList = [];
-let itemTypeList =[];
+let itemTypeList = [];
let locationTypeList = [];
let uomList = [];
let inventoryStatusList = [];
@@ -20,7 +20,8 @@ let sampleMethodList = [];
let transferModeList = [];
let countStageList = [];
let locationAreaTypeList = [];
-let businessList=[]
+let businessList = [];
+let countScopeTypeList = [];
@@ -41,7 +42,7 @@ export function getBusinessTypeDesc(type) {
export function clearCacheData() {
jobStatusList = [];
itemStatusList = [];
- itemTypeList =[];
+ itemTypeList = [];
locationTypeList = [];
uomList = [];
inventoryStatusList = [];
@@ -60,8 +61,9 @@ export function clearCacheData() {
sampleMethodList = [];
transferModeList = [];
countStageList = [];
- locationAreaTypeList=[]
- businessList=[]
+ locationAreaTypeList = []
+ businessList = []
+ countScopeTypeList = []
}
//获取字典信息
@@ -233,7 +235,7 @@ export function getBusinessTypeName(code) {
if (businessList.length == 0) {
businessList = uni.getStorageSync("businessType")
}
-
+
for (let item of businessList) {
if (item.code == code) {
resultInfo = item
@@ -319,6 +321,24 @@ export function getUomInfo(value) {
return resultInfo
}
+//获取盘点范围类型
+export function getCountScopeType(value) {
+ var resultInfo = "";
+ if (countStageList.length == 0) {
+ countStageList = getDirectoryInfo("count_scope_type")
+ }
+ if (countStageList.length > 0) {
+ for (let item of countStageList) {
+ if (item.value == value) {
+ resultInfo = item
+ break;
+ }
+ }
+ }
+ return resultInfo
+}
+
+
//获取包装单位
export function getPackUnitInfo(value) {
var resultInfo = "";
diff --git a/src/mycomponents/detail/comDetailCard.vue b/src/mycomponents/detail/comDetailCard.vue
index 5a5c1777..b15bb0fa 100644
--- a/src/mycomponents/detail/comDetailCard.vue
+++ b/src/mycomponents/detail/comDetailCard.vue
@@ -107,12 +107,14 @@
},
mounted() {
- if (this.detailOptions.length == 0) {
- this.detailOptions = getDetailOption();
- }
- if (this.scanOptions.length == 0) {
- this.scanOptions = getPurchaseReceiptOption(this.settingParam.allowModifyQty, false)
- }
+ // if (this.detailOptions.length == 0) {
+ // this.detailOptions = getDetailOption();
+ // }
+ // if (this.scanOptions.length == 0) {
+ // this.scanOptions = getPurchaseReceiptOption(this.settingParam.allowModifyQty, false)
+ // }
+
+ this.showLocation();
},
methods: {
diff --git a/src/mycomponents/package/PackageAndItemCard.vue b/src/mycomponents/package/PackageAndItemCard.vue
new file mode 100644
index 00000000..6351ba08
--- /dev/null
+++ b/src/mycomponents/package/PackageAndItemCard.vue
@@ -0,0 +1,53 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/src/mycomponents/qty/recommendQty.vue b/src/mycomponents/qty/recommendQty.vue
index 394a3799..925108d0 100644
--- a/src/mycomponents/qty/recommendQty.vue
+++ b/src/mycomponents/qty/recommendQty.vue
@@ -9,8 +9,8 @@
-
- /
+
+ /
{{ calc(dataContent.qty,dataContent.packQty)}}
@@ -73,6 +73,10 @@
objTextStyle: {
type: Object,
default: null
+ },
+ isShowPackCount: {
+ type: Boolean,
+ default: true
}
},
watch: {
diff --git a/src/pages.json b/src/pages.json
index 8637d870..3f08e9c1 100644
--- a/src/pages.json
+++ b/src/pages.json
@@ -1887,6 +1887,43 @@
}
},
+
+ {
+ "path": "pages/count/job/fuzzyCountJob",
+ "style": {
+ "navigationBarTitleText": "盲盘任务",
+ "enablePullDownRefresh": true,
+ "titleNView": {
+ // "autoBackButton": "true",
+ "buttons": [
+ // 右边按钮
+ {
+
+ "float": "right",
+ "fontSize": "58rpx", //按钮上文字的大小
+ "text": "\ue696",
+ "fontSrc": "/static/ali_icon/iconfont.ttf"
+
+ },
+ {
+
+ "float": "right",
+ "fontSize": "52rpx", //按钮上文字的大小
+ "text": "\ue6e2",
+ "fontSrc": "/static/ali_icon/iconfont.ttf"
+ }
+ ]
+ }
+ }
+ },
+ {
+ "path": "pages/count/job/fuzzyCountDetail",
+ "style": {
+ "navigationBarTitleText": "盲盘明细",
+ "enablePullDownRefresh": false
+
+ }
+ },
{
"path": "pages/count/record/countRecord",
"style": {
diff --git a/src/pages/count/coms/comFuzzyCountJobCard.vue b/src/pages/count/coms/comFuzzyCountJobCard.vue
new file mode 100644
index 00000000..29723e74
--- /dev/null
+++ b/src/pages/count/coms/comFuzzyCountJobCard.vue
@@ -0,0 +1,49 @@
+
+
+
+
+
+ {{getCountScopeName(range.type)}}
+ {{range.value}}
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/src/pages/count/job/fuzzyCountDetail.vue b/src/pages/count/job/fuzzyCountDetail.vue
new file mode 100644
index 00000000..c9f847c6
--- /dev/null
+++ b/src/pages/count/job/fuzzyCountDetail.vue
@@ -0,0 +1,436 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/src/pages/count/job/fuzzyCountJob.vue b/src/pages/count/job/fuzzyCountJob.vue
new file mode 100644
index 00000000..1115de97
--- /dev/null
+++ b/src/pages/count/job/fuzzyCountJob.vue
@@ -0,0 +1,448 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/src/pages/index/index.vue b/src/pages/index/index.vue
index 9396f0d2..31ee48d0 100644
--- a/src/pages/index/index.vue
+++ b/src/pages/index/index.vue
@@ -362,7 +362,7 @@
"inventory_status", "container_type", "pack_unit", "unplanned_receipt_reason",
"unplanned_issue_reason", "scrap_reason", "inspect_failed_reason",
"request_status", "inspect_type", "next_action", "sample_method", "transfer_mode",
- "count_stage", "inspect_result", "area_type"
+ "count_stage", "inspect_result", "area_type","count_scope_type"
]
}
getDictionaryItem(params).then(res => {
diff --git a/src/pages/putaway/record/putawayRecord.vue b/src/pages/putaway/record/putawayRecord.vue
index 75e09df1..a40d2002 100644
--- a/src/pages/putaway/record/putawayRecord.vue
+++ b/src/pages/putaway/record/putawayRecord.vue
@@ -1,6 +1,5 @@
-
From 03d58da87b2bff725a0d961c6f9811bab0e92960 Mon Sep 17 00:00:00 2001
From: niexiting <85552560@qq.com>
Date: Fri, 19 Jul 2024 20:11:25 +0800
Subject: [PATCH 2/3] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=98=8E=E7=BB=86?=
=?UTF-8?q?=E7=BB=84=E4=BB=B6?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/pages/count/job/fuzzyCountDetail.vue | 59 +++++++++++++++---------
1 file changed, 38 insertions(+), 21 deletions(-)
diff --git a/src/pages/count/job/fuzzyCountDetail.vue b/src/pages/count/job/fuzzyCountDetail.vue
index c9f847c6..9550cbd8 100644
--- a/src/pages/count/job/fuzzyCountDetail.vue
+++ b/src/pages/count/job/fuzzyCountDetail.vue
@@ -12,30 +12,17 @@
-
+
+ {{editRemoveOption}}
-
-
-
-
-
-
-
@@ -77,6 +64,10 @@
Decimal
} from 'decimal.js'; //引入
+ import {
+ getEditRemoveOption
+ } from '@/common/array.js';
+
import {
goHome,
navigateBack,
@@ -125,7 +116,7 @@
jobStatus: "",
fromLocation: {},
fromLocationCode: '',
-
+ editRemoveOption: []
};
},
onLoad(option) {
@@ -141,6 +132,7 @@
}
}
this.showFromLocationPopup();
+ this.editRemoveOption=getEditRemoveOption();
},
//返回首页
onNavigationBarButtonTap(e) {
@@ -233,8 +225,6 @@
}
},
-
-
closeScanPopup() {
if (this.$refs.scanPopup != undefined) {
this.$refs.scanPopup.closeScanPopup();
@@ -275,6 +265,7 @@
itemDesc2: packInfo.itemDesc2,
projectCode: "",
qty: packInfo.qty,
+ countQty: packInfo.qty,
uom: packInfo.uom,
remark: "",
locationCode: this.fromLocationCode,
@@ -286,8 +277,6 @@
return detail;
},
-
-
//编辑盘点结果
editCountResult(item, subItem) {
let that = this;
@@ -311,7 +300,35 @@
this.scanPopupGetFocus();
},
+ swipeClick(e, item) {
+ if (e.content.text == "详情") {
+ this.detail(item)
+ } else if (e.content.text == "编辑") {
+ this.edit(item)
+ } else if (e.content.text == "移除") {
+ this.remove(item)
+ }
+ },
+
+ edit(detail) {
+ this.$emit("editItem", detail)
+ },
+ detail(item) {
+ this.showItem = item;
+ this.$refs.detailInfoPopup.openPopup(item);
+ },
+ remove(item, index) {
+ this.$refs.comMessage.showQuestionMessage("确定移除扫描信息?",
+ res => {
+ if (res) {
+ // this.dataContent.subList.splice(index, 1)
+ item.scaned = false;
+ item.handleQty = 0;
+ this.$emit('removePack')
+ }
+ });
+ },
commit() {
// if(this.detailSource.length==0)
From 577165bb0eebe6dcba02e7fc39dacae9d443a996 Mon Sep 17 00:00:00 2001
From: Niext <85552560@qq.com>
Date: Fri, 19 Jul 2024 22:30:25 +0800
Subject: [PATCH 3/3] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E7=9B=B2=E7=9B=98?=
=?UTF-8?q?=E6=97=B6=E7=9A=84=E6=A0=A1=E9=AA=8C?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/pages/count/coms/comFuzzyCountJobCard.vue | 4 +
src/pages/count/job/fuzzyCountDetail.vue | 168 +++++++++++-------
2 files changed, 109 insertions(+), 63 deletions(-)
diff --git a/src/pages/count/coms/comFuzzyCountJobCard.vue b/src/pages/count/coms/comFuzzyCountJobCard.vue
index 29723e74..bbb0adf1 100644
--- a/src/pages/count/coms/comFuzzyCountJobCard.vue
+++ b/src/pages/count/coms/comFuzzyCountJobCard.vue
@@ -1,5 +1,9 @@
+
+ 盘点计划
+ {{dataContent.planNumber}}
+
diff --git a/src/pages/count/job/fuzzyCountDetail.vue b/src/pages/count/job/fuzzyCountDetail.vue
index 9550cbd8..fe787179 100644
--- a/src/pages/count/job/fuzzyCountDetail.vue
+++ b/src/pages/count/job/fuzzyCountDetail.vue
@@ -3,18 +3,27 @@
-
+
-
- {{editRemoveOption}}
+
+
@@ -56,13 +65,10 @@
cancleTakeCountJob,
countJobSubmit
} from '@/api/request2.js';
- import {
- calc
- } from '@/common/calc.js';
import {
- Decimal
- } from 'decimal.js'; //引入
+ getCountScopeType
+ } from '@/common/directory.js';
import {
getEditRemoveOption
@@ -73,9 +79,6 @@
navigateBack,
getPackingNumberAndBatch
} from '@/common/basic.js';
- import {
- getCountStageName
- } from '@/common/directory.js';
import winScanButton from '@/mycomponents/scan/winScanButton.vue'
@@ -132,7 +135,7 @@
}
}
this.showFromLocationPopup();
- this.editRemoveOption=getEditRemoveOption();
+ this.editRemoveOption = getEditRemoveOption();
},
//返回首页
onNavigationBarButtonTap(e) {
@@ -202,6 +205,41 @@
},
getLocation(location, code) {
+ let countRange = this.jobContent.countRange;
+
+ let range = countRange.find(r => r.type == "LOCATION_CODE");
+ if (range != undefined) {
+ if (!rang.value.includes(location.code)) {
+ this.showErrorMessage("库位代码【" + location.code + "】,不在盘点库位范围【" + rangeValue + "】内")
+ return;
+ }
+ } else {
+ range = countRange.find(r => r.type == "LOCATIONGROUP_CODE");
+ if (range != undefined) {
+ if (!rang.value.includes(location.locationGroupCode)) {
+ this.showErrorMessage("库位组代码【" + location.locationGroupCode + "】,不在盘点库位组范围【" + rangeValue +
+ "】内")
+ return;
+ }
+ } else {
+ range = countRange.find(r => r.type == "AREA_CODE");
+ if (range != undefined) {
+ if (!rang.value.includes(location.areaCode)) {
+ this.showErrorMessage("库区代码【" + location.areaCode + "】,不在盘点库区范围【" + rangeValue + "】内")
+ return;
+ }
+ } else {
+ range = countRange.find(r => r.type == "WAREHOUSE_CODE");
+ if (range != undefined) {
+ if (!rang.value.includes(location.warehouseCode)) {
+ this.showErrorMessage("仓库代码【" + location.warehouseCode + "】,不在盘点仓库范围【" + rangeValue +
+ "】内")
+ return;
+ }
+ }
+ }
+ }
+ }
this.getFromLocationCode(location, code)
},
@@ -246,8 +284,22 @@
//明盘
getScanResult(result) {
let that = this;
- let item = this.createDetailInfo(result.package);
- this.detailSource.push(item)
+ let package = result.package;
+ let detail = this.detailSource.find(r => r.itemCode == package.itemCode && r.packingNumber == package
+ .packingNumber && r.batch == package.batch && r.inventoryStatus == "OK");
+ if (detail == undefined) {
+ detail = this.createDetailInfo(package);
+ this.detailSource.push(detail)
+ } else {
+ let index = detail.index;
+ list.unshift(list.splice(index, 1)[0]); //置顶
+ //提交
+ this.showQuestionMessage('该箱码已经扫描,是否要编辑盘点明细?', res => {
+ if (res) {
+ this.edit(detail);
+ }
+ });
+ }
},
//创建盘盈的明细
@@ -277,57 +329,43 @@
return detail;
},
+ swipeClick(e, item) {
+ if (e.content.text == "编辑") {
+ this.edit(item)
+ } else if (e.content.text == "移除") {
+ this.remove(item)
+ }
+ },
+
//编辑盘点结果
- editCountResult(item, subItem) {
+ edit(item) {
let that = this;
- this.$refs.comMessage.showQuestionMessage("箱码【" + that.label.packingNumber +
- "】已经完成盘点,是否要编辑盘点结果?",
- res => {
- if (res) {
- this.currentEditItem = subItem;
- this.$refs.countQtyEdit.openEditPopup(subItem,
- item.subList);
- // this.$refs.countQtyEdit.openEditPopupShowSeconds(subItem,
- // item.subList);
- } else {
- this.scanPopupGetFocus();
- }
- })
+ this.currentEditItem = item;
+ this.$refs.countQtyEdit.openEditPopup(item);
},
-
- editClose() {
+ editConfirm(qty, inventoryStatus, mode) {
+ let that = this;
+ //编辑
+ if (mode == 'edit') {
+ this.currentEditItem.countQty = qty;
+ this.currentEditItem.qty = qty;
+ this.currentEditItem.inventoryStatus = inventoryStatus;
+ }
this.scanPopupGetFocus();
- },
- swipeClick(e, item) {
- if (e.content.text == "详情") {
- this.detail(item)
- } else if (e.content.text == "编辑") {
- this.edit(item)
- } else if (e.content.text == "移除") {
- this.remove(item)
- }
},
- edit(detail) {
- this.$emit("editItem", detail)
+ editClose() {
+ this.scanPopupGetFocus();
},
- detail(item) {
- this.showItem = item;
- this.$refs.detailInfoPopup.openPopup(item);
- },
remove(item, index) {
- this.$refs.comMessage.showQuestionMessage("确定移除扫描信息?",
- res => {
- if (res) {
- // this.dataContent.subList.splice(index, 1)
- item.scaned = false;
- item.handleQty = 0;
- this.$emit('removePack')
- }
- });
+ this.showQuestionMessage("是否要移除扫描信息?", res => {
+ if (res) {
+ this.dataContent.subList.splice(index, 1)
+ }
+ });
},
commit() {
@@ -363,7 +401,6 @@
return this.jobContent;
},
-
showMessage(message) {
this.$refs.comMessage.showMessage(message, res => {
if (res) {
@@ -371,6 +408,7 @@
}
});
},
+
showErrorMessage(message) {
this.$refs.comMessage.showErrorMessage(message, res => {
if (res) {
@@ -383,6 +421,12 @@
this.$refs.comMessage.showScanMessage(message);
},
+ showQuestionMessage(message, callback) {
+ this.$refs.comMessage.showQuestionMessage(message, res => {
+ callback(res);
+ });
+ },
+
afterCloseMessage() {
this.scanPopupGetFocus();
},
@@ -403,13 +447,11 @@
navigateBack(1);
})
},
- getCountStageName(value) {
- return getCountStageName(value)
- },
- isOpenCount(value) {
- return value == "TRUE" ? "明盘" : "盲盘"
- }
+ getCountScopeName(value) {
+ let item = getCountScopeType(value);
+ return item.label;
+ },
}
}
@@ -450,4 +492,4 @@
background: #e0e0e0;
}
-
\ No newline at end of file
+