From 2e506509a365cacee1c794a954793370ef1f045d Mon Sep 17 00:00:00 2001 From: "zangch@mesnac.com" Date: Mon, 4 Aug 2025 15:47:09 +0800 Subject: [PATCH] =?UTF-8?q?feat(wms):=20=E5=AE=8C=E5=96=84=E4=BB=93?= =?UTF-8?q?=E5=BA=93=E2=86=92=E5=8C=BA=E5=9F=9F=E2=86=92=E5=BA=93=E4=BD=8D?= =?UTF-8?q?=E5=85=B3=E7=B3=BB=EF=BC=8C=E5=B0=86=E5=BA=93=E4=BD=8D=E7=AE=A1?= =?UTF-8?q?=E7=90=86=E6=8C=89=E4=BB=93=E5=BA=93=E5=8C=BA=E5=9F=9F=E5=88=92?= =?UTF-8?q?=E5=88=86=EF=BC=8C=E4=BB=8E=E5=85=B3=E8=81=94=E4=BB=93=E5=BA=93?= =?UTF-8?q?=E6=94=B9=E4=B8=BA=E5=85=B3=E8=81=94=E5=8C=BA=E5=9F=9F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 将所属仓库字段改为所属仓库区域 - 更新相关 API 调用和数据结构 - 调整表头显示内容,从仓库名称改为区域名称 - 修改对话框中相关字段的显示方式 --- src/api/wms/baseLocation/types.ts | 36 ++++++++++--- src/views/wms/baseLocation/index.vue | 76 +++++++++++++++++----------- 2 files changed, 76 insertions(+), 36 deletions(-) diff --git a/src/api/wms/baseLocation/types.ts b/src/api/wms/baseLocation/types.ts index 42c86e2..19c6a32 100644 --- a/src/api/wms/baseLocation/types.ts +++ b/src/api/wms/baseLocation/types.ts @@ -4,10 +4,14 @@ export interface BaseLocationVO { */ locationId: string | number; + // /** + // * 所属仓库区域 + // */ + // areaId: string | number; /** - * 所属仓库 + * 所属仓库区域 */ - warehouseId: string | number; + areaId: string | number; /** * 库位编码 @@ -39,6 +43,16 @@ export interface BaseLocationVO { */ updateTime: string; + /** + * 区域编码 + */ + areaCode: string; + + /** + * 区域名称 + */ + areaName: string; + } export interface BaseLocationForm extends BaseEntity { @@ -46,10 +60,15 @@ export interface BaseLocationForm extends BaseEntity { * 表主键 */ locationId?: string | number; + + // /** + // * 所属仓库 + // */ + // warehouseId?: string | number; /** - * 所属仓库 + * 所属仓库区域 */ - warehouseId?: string | number; + areaId?: string | number; /** * 库位编码 @@ -75,10 +94,14 @@ export interface BaseLocationForm extends BaseEntity { export interface BaseLocationQuery extends PageQuery { + // /** + // * 所属仓库 + // */ + // warehouseId?: string | number; /** - * 所属仓库 + * 所属仓库区域 */ - warehouseId?: string | number; + areaId?: string | number; /** * 库位编码 @@ -99,6 +122,7 @@ export interface BaseLocationQuery extends PageQuery { * 日期范围参数 */ params?: any; + } diff --git a/src/views/wms/baseLocation/index.vue b/src/views/wms/baseLocation/index.vue index b11e209..e1bc119 100644 --- a/src/views/wms/baseLocation/index.vue +++ b/src/views/wms/baseLocation/index.vue @@ -4,25 +4,25 @@
- - + + - + 搜索 重置 @@ -54,8 +54,8 @@ - - + + @@ -84,32 +84,33 @@ + - - + + - + - + - + - + @@ -128,6 +129,7 @@ import { listBaseLocation, getBaseLocation, delBaseLocation, addBaseLocation, up import { BaseLocationVO, BaseLocationQuery, BaseLocationForm } from '@/api/wms/baseLocation/types'; import {getWorkshopList} from "@/api/mes/baseWorkshopInfo"; import {getBaseWarehouseList} from "@/api/wms/baseWarehouse"; +import { getWmsBaseAreaList } from '@/api/wms/wmsBaseArea'; const { proxy } = getCurrentInstance() as ComponentInternalInstance; @@ -147,16 +149,12 @@ const dialog = reactive({ visible: false, title: '' }); -let baseStoreList = ref([]); -/** 查询车间下拉树结构 */ -const getBaseWarehouseListsss = async () => { - let res = await getBaseWarehouseList(null); - baseStoreList.value = res.data; -}; + + // 列显隐信息 const columns = ref([ { key: 0, label: `表主键`, visible: false }, - { key: 1, label: `所属仓库`, visible: true }, + { key: 1, label: `所属仓库区域`, visible: true }, { key: 2, label: `库位编码`, visible: true }, { key: 3, label: `排`, visible: true }, { key: 4, label: `层`, visible: true }, @@ -171,18 +169,20 @@ const columns = ref([ const initFormData: BaseLocationForm = { locationId: undefined, - warehouseId: undefined, + areaId: undefined, locationCode: undefined, lineNum: undefined, layerNum: undefined, locationNum: undefined, + areaName: undefined, + areaCode: undefined, } const data = reactive>({ form: {...initFormData}, queryParams: { pageNum: 1, pageSize: 10, - warehouseId: undefined, + areaId: undefined, locationCode: undefined, lineNum: undefined, layerNum: undefined, @@ -285,8 +285,24 @@ const handleExport = () => { }, `baseLocation_${new Date().getTime()}.xlsx`) } +// let baseStoreList = ref([]); +// /** 查询车间下拉树结构 */ +// const getBaseWarehouseListsss = async () => { +// let res = await getBaseWarehouseList(null); +// baseStoreList.value = res.data; +// }; + +/** 获取区域下拉列表 */ +let areaList = ref([]); +const getAreaList = async () => { + let res = await getWmsBaseAreaList(null); + areaList.value = res.data; +}; + + onMounted(() => { - getBaseWarehouseListsss(); + // getBaseWarehouseListsss(); + getAreaList(); getList(); });