diff --git a/apps/hand-factory/api/wms/actualWarehouse.js b/apps/hand-factory/api/wms/actualWarehouse.js
index fa2e625..53f2e2d 100644
--- a/apps/hand-factory/api/wms/actualWarehouse.js
+++ b/apps/hand-factory/api/wms/actualWarehouse.js
@@ -52,3 +52,16 @@ export function treeActualWarehouseTwoLevel(query) {
})
}
+/**
+ * 强制释放库位
+ */
+export function forceReleaseLocation(actualWarehouseId) {
+ if (!actualWarehouseId) {
+ throw new Error('actualWarehouseId is required');
+ }
+ return request({
+ url: '/wms/actualWarehouse/release/' + actualWarehouseId,
+ method: 'put',
+ })
+}
+
diff --git a/apps/hand-factory/config.js b/apps/hand-factory/config.js
index 02faf91..1c955a7 100644
--- a/apps/hand-factory/config.js
+++ b/apps/hand-factory/config.js
@@ -8,7 +8,7 @@ module.exports = {
// 应用名称
name: "ruoyi-app",
// 应用版本
- version: "1.3.23",
+ version: "1.3.24",
// 应用logo
logo: "/static/logo.jpg",
// 官方网站
diff --git a/apps/hand-factory/manifest.json b/apps/hand-factory/manifest.json
index eba8d98..447fcd7 100644
--- a/apps/hand-factory/manifest.json
+++ b/apps/hand-factory/manifest.json
@@ -2,7 +2,7 @@
"name" : "科伦普",
"appid" : "__UNI__E781B49",
"description" : "",
- "versionName" : "1.3.23",
+ "versionName" : "1.3.24",
"versionCode" : 1,
"transformPx" : false,
"app-plus" : {
diff --git a/apps/hand-factory/pages/easycode/easycode.vue b/apps/hand-factory/pages/easycode/easycode.vue
index 258246e..d6ae79d 100644
--- a/apps/hand-factory/pages/easycode/easycode.vue
+++ b/apps/hand-factory/pages/easycode/easycode.vue
@@ -40,6 +40,7 @@
+
@@ -122,25 +123,33 @@
当前钢卷号
{{ coilDetail.currentCoilNo || '-' }}
+
+ 逻辑库区
+ {{ coilDetail.warehouseName || '-' }}
+
+
+ 实际库区
+ {{ coilDetail.actualWarehouseName || '-' }}
+
重量
{{ coilDetail.netWeight || '-' }}
厂家
- {{ coilDetail.product && coilDetail.product.manufacturer || '-' }}
+ {{ (coilDetail.product && coilDetail.product.manufacturer) || (coilDetail.rawMaterial && coilDetail.rawMaterial.manufacturer) || '-' }}
材质
- {{ coilDetail.product && coilDetail.product.material || '-' }}
+ {{ (coilDetail.product && coilDetail.product.material) || (coilDetail.rawMaterial && coilDetail.rawMaterial.material) || '-' }}
规格
- {{ coilDetail.product && coilDetail.product.specification || '-' }}
+ {{ (coilDetail.product && coilDetail.product.specification) || (coilDetail.rawMaterial && coilDetail.rawMaterial.specification) || '-' }}
品名
- {{ coilDetail.product && coilDetail.product.productName || '-' }}
+ {{ (coilDetail.product && coilDetail.product.productName) || (coilDetail.rawMaterial && coilDetail.rawMaterial.productName) || '-' }}
@@ -159,6 +168,13 @@
@click="handleShipSubmit">
发货
+
@@ -183,7 +199,8 @@
addPendingAction
} from '@/api/wms/pendingAction.js'
import {
- getActualWarehouse
+ getActualWarehouse,
+ forceReleaseLocation
} from '@/api/wms/actualWarehouse.js'
export default {
@@ -196,7 +213,7 @@
targetWarehouse: null, // 存储选中的目标库区信息
bomDialogShow: false, // BOM参数弹窗控制(原有功能补充),
mode: 'pda', // pda或camera
- currentAction: '',
+ currentAction: '', // ship,withdrawShip,release
buttonLoading: false,
}
},
@@ -338,6 +355,55 @@
})
}
},
+
+ async handleRelease() {
+ const actualWarehouseId = await this.scan();
+ // 查询真实库区在此处的钢卷
+ const res = await listMaterialCoil({
+ actualWarehouseId,
+ dataType: 1
+ })
+ if (res.total == 0) {
+ uni.showToast({
+ title: '该库区未发现钢卷',
+ icon: 'none'
+ });
+ return;
+ };
+ if (res.rows.length == 1) {
+ this.coilDetail = res.rows[0]
+ this.currentAction = 'release';
+ this.$refs.shipPopup.open('bottom');
+ } else {
+ uni.showToast({
+ title: '数据异常',
+ icon: 'none'
+ })
+ }
+ },
+
+ async handleReleaseSubmit() {
+ this.buttonLoading = true;
+ try {
+ const res = await forceReleaseLocation(this.coilDetail.actualWarehouseId);
+ if (res.code == 200) {
+ uni.showToast({
+ title: '释放成功',
+ icon: 'none'
+ })
+ this.$refs.shipPopup.close()
+ } else {
+ throw new Error()
+ }
+ } catch {
+ uni.showToast({
+ title: '库区释放失败',
+ icon: 'none'
+ })
+ } finally {
+ this.buttonLoading = false;
+ }
+ },
// 扫码并创建待操作(原有方法不变)
async handleScan(actionType) {
diff --git a/apps/hand-factory/utils/update.js b/apps/hand-factory/utils/update.js
index d8f96ee..cc6fbf5 100644
--- a/apps/hand-factory/utils/update.js
+++ b/apps/hand-factory/utils/update.js
@@ -73,13 +73,12 @@ function checkStorageSpace() {
function checkUpdate(forceCheck = false) {
// 1. 准备本地版本信息
const localVersion = plus.runtime.version; // 基座版本
- const staticVersion = '1.3.23'; // 静态默认版本
+ const staticVersion = '1.3.24'; // 静态默认版本
const localWgtVersion = uni.getStorageSync('wgtVersion') || staticVersion; // 本地wgt版本(从存储获取或用默认)
const currentVersion = compareVersion(localWgtVersion, localVersion) > 0
? localWgtVersion
: localVersion; // 当前有效版本(取两者较高者)
-
// 2. 请求远程版本信息
uni.request({
url: `${baseURL}/version.json?t=${Date.now()}`, // 加时间戳防缓存
diff --git a/apps/hand-factory/version.json b/apps/hand-factory/version.json
index abbe023..486aefd 100644
--- a/apps/hand-factory/version.json
+++ b/apps/hand-factory/version.json
@@ -1,5 +1,5 @@
{
- "version": "klp 1.3.23",
+ "version": "klp 1.3.24",
"wgtUrl": "http://49.232.154.205:10900/fadapp-update/klp/klp.wgt",
"apkUrl": "http://49.232.154.205:10900/fadapp-update/klp/klp.apk"
}
\ No newline at end of file