diff --git a/src/components/Form/src/jeecg/components/JInput.vue b/src/components/Form/src/jeecg/components/JInput.vue
index ba2ef41..c5910ed 100644
--- a/src/components/Form/src/jeecg/components/JInput.vue
+++ b/src/components/Form/src/jeecg/components/JInput.vue
@@ -85,10 +85,19 @@
* 返回值
*/
function backValue(e) {
+ console.log('backValue', e);
let text = e?.target?.value ?? '';
if (text && !!props.trim) {
text = text.trim();
}
+
+ // 添加空值判断,空值直接返回,不进行特殊字符拼接
+ if (!text) {
+ emit('change', text);
+ emit('update:value', text);
+ return;
+ }
+
switch (props.type) {
case JInputTypeEnum.JINPUT_QUERY_LIKE:
text = '*' + text + '*';
@@ -110,6 +119,7 @@
break;
default:
}
+ console.log('backValue2', text);
emit('change', text);
emit('update:value', text);
}
diff --git a/src/views/base/point/Point.data.ts b/src/views/base/point/Point.data.ts
index 71037ca..2bdf889 100644
--- a/src/views/base/point/Point.data.ts
+++ b/src/views/base/point/Point.data.ts
@@ -8,29 +8,15 @@ export const columns: BasicColumn[] = [
align: 'center',
dataIndex: 'areaId_dictText',
},
- {
- title: '库位编码',
- align: 'center',
- dataIndex: 'pointCode',
- },
- {
- title: '状态',
- align: 'center',
- dataIndex: 'status_dictText',
- customRender: ({ text }) => {
- const color = text == '占用' ? 'red' : text == '空闲' ? 'green' : 'gray';
- return render.renderTag(text, color);
- },
- },
{
title: '巷道编码',
align: 'center',
dataIndex: 'colNum',
},
{
- title: '储位编码',
+ title: '库位编码',
align: 'center',
- dataIndex: 'nodeCode',
+ dataIndex: 'pointCode',
},
{
title: '层',
@@ -42,6 +28,16 @@ export const columns: BasicColumn[] = [
align: 'center',
dataIndex: 'rowNum',
},
+ {
+ title: '状态',
+ align: 'center',
+ dataIndex: 'status_dictText',
+ customRender: ({ text }) => {
+ const color = text == '占用' ? 'red' : text == '空闲' ? 'green' : 'gray';
+ return render.renderTag(text, color);
+ },
+ },
+
{
title: '是否启用',
align: 'center',
@@ -56,6 +52,6 @@ export const columns: BasicColumn[] = [
title: '创建日期',
align: 'center',
dataIndex: 'createTime',
- sorter: true
+ sorter: true,
},
];
diff --git a/src/views/base/point/PointList.vue b/src/views/base/point/PointList.vue
index 702d2cd..4c149f1 100644
--- a/src/views/base/point/PointList.vue
+++ b/src/views/base/point/PointList.vue
@@ -16,25 +16,18 @@
-
- 库位编码
-
+
+ 巷道编码
+
-
- 状态
-
+
+ 库位编码
+
-
-
-
- 是否启用
-
-
-
-
+
@@ -48,6 +41,24 @@
+
+
+
+
+ 状态
+
+
+
+
+
+
+
+ 是否启用
+
+
+
+
+
diff --git a/src/views/base/point/components/PointForm.vue b/src/views/base/point/components/PointForm.vue
index a3dde81..9f81f12 100644
--- a/src/views/base/point/components/PointForm.vue
+++ b/src/views/base/point/components/PointForm.vue
@@ -17,7 +17,7 @@
-
+
@@ -35,7 +35,7 @@
-
+
@@ -47,7 +47,6 @@
:max="2"
placeholder="请输入层"
allow-clear
- @change="generatePointCode"
style="width: 220px"
>
@@ -61,7 +60,6 @@
:min="1"
:max="7"
allow-clear
- @change="generatePointCode"
style="width: 220px"
>
@@ -78,11 +76,6 @@
-
-
-
-
-
(false); // 是否自动生成编码
const showSpecialFields = ref(false); // 是否显示巷道相关字段
const showCoordinateFields = ref(false); // 是否显示坐标字段
// 定义库区ID常量,提高可读性和可维护性
const CP_MJ_AREA_IDS = new Set(['1988794761598668802', '1988795017837088770']);
//成品存储区、模具存储区、入库工作站、出库工作站
- const CP_MJ_RK_CK_AREA_IDS = new Set([
- '1988794761598668802',
- '1988795017837088770',
- '1986328561044119554',
- '1986337742572707841'
- ]);
+ const CP_MJ_RK_CK_AREA_IDS = new Set(['1988794761598668802', '1988795017837088770', '1986328561044119554', '1986337742572707841']);
/**
* 库区选择变化事件
@@ -227,7 +212,6 @@
const isCoordinateArea = CP_MJ_RK_CK_AREA_IDS.has(option);
// 更新响应式状态
- isAutoGenerateCode.value = isSpecialArea;
showSpecialFields.value = isSpecialArea;
showCoordinateFields.value = isCoordinateArea;
@@ -238,7 +222,6 @@
validatorRules.layerNum.splice(0);
validatorRules.positionX.splice(0);
validatorRules.positionY.splice(0);
- validatorRules.nodeCode.splice(0);
// 根据类型设置新的验证规则
if (isSpecialArea) {
@@ -246,7 +229,6 @@
validatorRules.colNum.push({ required: true, message: '请输入巷道编码!' });
validatorRules.rowNum.push({ required: true, message: '请输入深度!' });
validatorRules.layerNum.push({ required: true, message: '请输入层!' });
- validatorRules.nodeCode.push({ required: true, message: '请输入储位编码!' });
} else {
// 手动编码需要 pointCode 必填
validatorRules.pointCode.push({ required: true, message: '请输入编码!' });
@@ -256,29 +238,6 @@
validatorRules.positionX.push({ required: true, message: '请输入坐标X!' });
validatorRules.positionY.push({ required: true, message: '请输入坐标Y!' });
}
-
- // 仅在必要时重新生成编码
- if (isSpecialArea || isCoordinateArea) {
- generatePointCode();
- }
- }
-
- /**
- * 自动生成库位编码
- */
- function generatePointCode() {
- if (isAutoGenerateCode.value) {
- // 格式: 巷道编码-层-深度
- const colNum = formData.colNum || '';
- const layerNum = formData.layerNum || '';
- const rowNum = formData.rowNum || '';
-
- if (colNum && layerNum && rowNum) {
- formData.pointCode = `${colNum}-${layerNum}-${rowNum}`;
- } else {
- formData.pointCode = '';
- }
- }
}
/**