From e6048259b17cfdb1bc684f413053dab6a34a8479 Mon Sep 17 00:00:00 2001 From: bb_pan Date: Wed, 2 Jul 2025 16:46:33 +0800 Subject: [PATCH] =?UTF-8?q?=E6=A0=87=E5=87=86=E7=AE=B1=E7=9B=98=E7=82=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages.json | 12 + src/pages/inventoryBinding/index.vue | 4 +- src/pages/standardBox/boxList.vue | 677 +++++++++++++++++++++++++ src/pages/standardBox/codeEntering.vue | 369 ++++++++++++++ src/pages/standardBox/codeList.vue | 42 +- src/pages/standardBox/index.vue | 6 +- src/pages/work/index.vue | 7 +- src/services/standard.js | 20 +- 8 files changed, 1112 insertions(+), 25 deletions(-) create mode 100644 src/pages/standardBox/boxList.vue create mode 100644 src/pages/standardBox/codeEntering.vue diff --git a/src/pages.json b/src/pages.json index 1ada3cb..3e02bdd 100644 --- a/src/pages.json +++ b/src/pages.json @@ -542,6 +542,18 @@ "navigationStyle": "custom" } }, + { + "path": "pages/standardBox/boxList", + "style": { + "navigationStyle": "custom" + } + }, + { + "path": "pages/standardBox/codeEntering", + "style": { + "navigationBarTitleText": "标准箱录入" + } + }, //库存查询 { "path": "pages/stquery/deviceStatusRecord/index", diff --git a/src/pages/inventoryBinding/index.vue b/src/pages/inventoryBinding/index.vue index 336fd83..a8b6402 100644 --- a/src/pages/inventoryBinding/index.vue +++ b/src/pages/inventoryBinding/index.vue @@ -2,8 +2,8 @@
diff --git a/src/pages/standardBox/boxList.vue b/src/pages/standardBox/boxList.vue new file mode 100644 index 0000000..58c8590 --- /dev/null +++ b/src/pages/standardBox/boxList.vue @@ -0,0 +1,677 @@ + + + + + diff --git a/src/pages/standardBox/codeEntering.vue b/src/pages/standardBox/codeEntering.vue new file mode 100644 index 0000000..1cff8a1 --- /dev/null +++ b/src/pages/standardBox/codeEntering.vue @@ -0,0 +1,369 @@ + + + + + diff --git a/src/pages/standardBox/codeList.vue b/src/pages/standardBox/codeList.vue index 12432ba..e648547 100644 --- a/src/pages/standardBox/codeList.vue +++ b/src/pages/standardBox/codeList.vue @@ -216,23 +216,33 @@ const bindMa = (qrCode) => { } //解绑 const delRow = (item) => { - console.log(item) - let param = { - "id":item.id,"boxId":boxInfo.value.boxId, - } - console.log(param) - appUnbindMaCodeApi(param).then(res => { - console.log(res) - if(res.code==200){ - uni.showToast({ title: '解绑成功', icon: 'none' }) - - getCodeList() - }else{ - uni.showToast({ title: '解绑失败', icon: 'none' }) + console.log(item) + // 弹框确认 + uni.showModal({ + title: '提示', + content: '确定要解绑吗?', + success: function (res) { + if (res.confirm) { + let param = { + id: item.id, + boxId: boxInfo.value.boxId, + } + console.log(param) + appUnbindMaCodeApi(param).then(res => { + console.log(res) + if(res.code==200){ + uni.showToast({ title: '解绑成功', icon: 'none' }) + + getCodeList() + }else{ + uni.showToast({ title: '解绑失败', icon: 'none' }) + } + }).catch(error => { + console.log(error) + }) + } } - }).catch(error => { - console.log(error) - }) + }) } diff --git a/src/pages/standardBox/index.vue b/src/pages/standardBox/index.vue index 31a6eec..93480eb 100644 --- a/src/pages/standardBox/index.vue +++ b/src/pages/standardBox/index.vue @@ -6,7 +6,7 @@ - 标准箱管理 + 标准箱创建 @@ -17,11 +17,11 @@ - 未录入 + 待录入
- 已完成 + 待移交
diff --git a/src/pages/work/index.vue b/src/pages/work/index.vue index a95e278..d3ab006 100644 --- a/src/pages/work/index.vue +++ b/src/pages/work/index.vue @@ -161,6 +161,11 @@ const newInfoList = ref([ url: '/pages/nameplateUpdate/index', iconSrc: '../../static/workbench/minPai.png', }, + { + title: '标准箱盘点', + url: '/pages/standardBox/boxList', + iconSrc: '../../static/workbench/minPai.png', + }, ]) // 使用计算属性筛选 newInfoList 中的数据 @@ -304,7 +309,7 @@ const repairListTwo = computed(() => { // 标准箱 const boxList = ref([ { - title: '标准箱管理', + title: '标准箱创建', url: '/pages/standardBox/index', iconSrc: '../../static/workbench/boxManage.png', }, diff --git a/src/services/standard.js b/src/services/standard.js index 5ce38bb..3e94004 100644 --- a/src/services/standard.js +++ b/src/services/standard.js @@ -146,9 +146,23 @@ export const getBoxDetailsApi = (data) => { }) } - - - +// 获取设备编码 +export const getMaCodeListApi = (data) => { + return http({ + method: 'GET', + url: '/material/bm_qrcode_box/getMaCodeList', + data:data, + }) +} + +// 编码录入 +export const appCodeBindApi = (data) => { + return http({ + method: 'POST', + url: '/material/bm_qrcode_box/app_code_bind', + data, + }) +}