From 60f01ac6d47de6858064bcf082e193249a0f2c86 Mon Sep 17 00:00:00 2001 From: zc Date: Thu, 9 Apr 2026 11:06:37 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/apis/weightManage/weightManage.ts | 4 ++-- src/views/material/MaterialInfoAddModal.vue | 17 ++++++++++++++--- src/views/material/index.vue | 3 ++- src/views/weightManage/index.vue | 8 ++++---- 4 files changed, 22 insertions(+), 10 deletions(-) diff --git a/src/apis/weightManage/weightManage.ts b/src/apis/weightManage/weightManage.ts index 2529925..98eb56f 100644 --- a/src/apis/weightManage/weightManage.ts +++ b/src/apis/weightManage/weightManage.ts @@ -30,8 +30,8 @@ export function validateWeighing(data: any) { } /** @desc 校验物料是否一致 */ -export function vmSend(materialProcess: string) { - return http.post(`/vm/send`, { materialProcess }) +export function vmSend(materialCode: string) { + return http.post(`/vm/send`, { materialCode }) } /** @desc vm定时任务保存图片 */ diff --git a/src/views/material/MaterialInfoAddModal.vue b/src/views/material/MaterialInfoAddModal.vue index bcadf34..e646a32 100644 --- a/src/views/material/MaterialInfoAddModal.vue +++ b/src/views/material/MaterialInfoAddModal.vue @@ -60,7 +60,7 @@ const columns: ColumnItem[] = reactive([ required: true, }, { - label: '物料单位重量,单位(g)', + label: '物料单位重量(g)', field: 'unitWeight', type: 'input-number', span: 24, @@ -96,8 +96,19 @@ const columns: ColumnItem[] = reactive([ required: true, }, { - label: '物料规格', + label: '物料直径', field: 'materialSpec', + type: 'input-number', + props: { + min: 0, + mode: 'button', + step: 0.001, + }, + span: 24, + }, + { + label: '物料颜色', + field: 'color', type: 'input', span: 24, }, @@ -107,7 +118,7 @@ const columns: ColumnItem[] = reactive([ type: 'image', savePath: 'material/', span: 24, - required: true, + // required: true, }, ]) diff --git a/src/views/material/index.vue b/src/views/material/index.vue index 72afef8..4c07ec0 100644 --- a/src/views/material/index.vue +++ b/src/views/material/index.vue @@ -122,7 +122,8 @@ const columns = ref([ { title: '物料编码', dataIndex: 'encoding', slotName: 'encoding' }, { title: '物料单位重量(g)', dataIndex: 'unitWeight', slotName: 'unitWeight' }, { title: '物料品类', dataIndex: 'typeName' }, - { title: '物料规格', dataIndex: 'materialSpec', slotName: 'materialSpec' }, + { title: '物料直径', dataIndex: 'materialSpec', slotName: 'materialSpec' }, + { title: '物料颜色', dataIndex: 'color', slotName: 'color' }, { title: '物料流程', dataIndex: 'materialProcess', slotName: 'materialProcess' }, { title: '灯光等级', dataIndex: 'lightLevel', slotName: 'lightLevel' }, { title: '物料照片', dataIndex: 'photoUrl', slotName: 'photoUrl', width: 120, align: 'center' }, diff --git a/src/views/weightManage/index.vue b/src/views/weightManage/index.vue index beaba6f..8bb5693 100644 --- a/src/views/weightManage/index.vue +++ b/src/views/weightManage/index.vue @@ -37,8 +37,8 @@
- - + +
@@ -291,7 +291,7 @@ const formData = reactive({ id: '', // 物料ID encoding: '', // 物料编码 materialName: '', // 物料名称 - materialSpec: '', // 物料规格 + materialSpec: '', // 物料直径 materialProcess: '', // 物料流程 unitWeight: 0, // 重量 photoUrl: '', // 样图URL @@ -729,7 +729,7 @@ const handleNext = async () => { } // 调用后端接口获取比对结果 // todo - const res = await vmSend(formData.materialProcess); + const res = await vmSend(materialCode); if (res.data && res.data === materialCode) { compareMatchResult.value = 'success' Message.success('比对成功')