From f20ba8e27ff25b61547453d594f52cbd8f8bf2a4 Mon Sep 17 00:00:00 2001 From: zhaoxuebing <1291173720@qq.com> Date: Wed, 13 Mar 2024 14:55:15 +0800 Subject: [PATCH 01/22] =?UTF-8?q?=E9=87=87=E8=B4=AD=E6=94=B6=E8=B4=A7?= =?UTF-8?q?=E4=BB=BB=E5=8A=A1=E6=89=A7=E8=A1=8C=E6=8E=A5=E5=8F=A3=E8=B0=83?= =?UTF-8?q?=E8=AF=95=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../wms/purchasereceiptRecordDetail/index.ts | 9 +- .../purchasereceiptRecordMain/index.vue | 54 ++- .../purchasereceiptRecordMain.data.ts | 351 +++++++++++++++--- 3 files changed, 360 insertions(+), 54 deletions(-) diff --git a/src/api/wms/purchasereceiptRecordDetail/index.ts b/src/api/wms/purchasereceiptRecordDetail/index.ts index cfba67183..2afacb3e1 100644 --- a/src/api/wms/purchasereceiptRecordDetail/index.ts +++ b/src/api/wms/purchasereceiptRecordDetail/index.ts @@ -45,7 +45,9 @@ export interface PurchasereceiptRecordDetailVO { interfaceType: string fromOwnerCode: string toOwnerCode: string - toBatch: string + toBatch: string, + parentPackingNumber:string + packingNumber:string } // 查询采购收货记录子列表 @@ -117,4 +119,9 @@ export const getScarceGoodsDetailPage = async (params) => { // 查询采购收货记录子包装数据 export const queryPurchaseceiptChildPackingNumber = async (params) => { return await request.get({ url: `/wms/purchasereceipt-record-detail/pageChildPackingNumber`, params }) +} + +// 查询采购收货缺货记录子包装数据 +export const queryPurchaseshortageChildPackingNumber = async (params) => { + return await request.get({ url: `/wms/purchaseshortage-detail/pageChildPackingNumber`, params }) } \ No newline at end of file diff --git a/src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRecordMain/index.vue b/src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRecordMain/index.vue index dc55a4063..dfd32837e 100644 --- a/src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRecordMain/index.vue +++ b/src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRecordMain/index.vue @@ -63,7 +63,7 @@ @tableFormButton="tableFormButton" /> - + + + + diff --git a/src/views/wms/basicDataManage/itemManage/itemarea/itemarea.data.ts b/src/views/wms/basicDataManage/itemManage/itemarea/itemarea.data.ts index c693b29fe..61b173455 100644 --- a/src/views/wms/basicDataManage/itemManage/itemarea/itemarea.data.ts +++ b/src/views/wms/basicDataManage/itemManage/itemarea/itemarea.data.ts @@ -322,13 +322,31 @@ export const Itemarea = useCrudSchemas(reactive([ label: '出库后剩余库存自动转换为出库包装规格', field: 'surplusToOutpackunit', sort: 'custom', - isSearch: false, + dictType: DICT_TYPE.TRUE_FALSE, + dictClass: 'string', + form: { + component: 'Switch', + value: 'FALSE', + componentProps: { + inactiveValue: 'FALSE', + activeValue: 'TRUE' + } + }, }, { label: '超过高储是否允许叫料', field: 'allowIssueRequest', sort: 'custom', - isSearch: false, + dictType: DICT_TYPE.TRUE_FALSE, + dictClass: 'string', + form: { + component: 'Switch', + value: 'FALSE', + componentProps: { + inactiveValue: 'FALSE', + activeValue: 'TRUE' + } + }, }, { label: '优先空库位', @@ -618,19 +636,14 @@ export const ItemareaRules = reactive({ */ export const ItemareaDetail = useCrudSchemas(reactive([ { - label: 'id', - field: 'id', + label: '库位组', + field: 'locationGroup', sort: 'custom', - isForm: false, }, { - label: '主表ID', - field: 'masterId', + label: '库位代码', + field: 'locationCode', sort: 'custom', - form: { - component: 'InputNumber', - value: 0 - }, }, { label: '备注', @@ -663,16 +676,6 @@ export const ItemareaDetail = useCrudSchemas(reactive([ sort: 'custom', isForm: false, }, - { - label: '库位组', - field: 'locationGroup', - sort: 'custom', - }, - { - label: '库位代码', - field: 'locationCode', - sort: 'custom', - }, { label: '操作', field: 'action', @@ -683,3 +686,8 @@ export const ItemareaDetail = useCrudSchemas(reactive([ } } ])) + +// 表单校验 +export const ItemareaDetailRules = reactive({ + +}) \ No newline at end of file From 45aaef03719b96f77d8bd419382d75022eb1412e Mon Sep 17 00:00:00 2001 From: chenfang Date: Thu, 14 Mar 2024 15:42:11 +0800 Subject: [PATCH 12/22] =?UTF-8?q?=E8=AF=B7=E6=B1=82=E8=B7=AF=E5=BE=84local?= =?UTF-8?q?host=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .env.development | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.env.development b/.env.development index 3b38b8cc0..78976cddd 100644 --- a/.env.development +++ b/.env.development @@ -4,7 +4,7 @@ NODE_ENV=development VITE_DEV=false # 请求路径 -VITE_BASE_URL='http://192.168.0.113:12080' +VITE_BASE_URL='http://localhost:12080' # 上传路径 VITE_UPLOAD_URL='http://localhost:12080/admin-api/infra/file/upload' From 746a7a78abdd6f9dfaccdf4e2c2d4d3d5077b0e9 Mon Sep 17 00:00:00 2001 From: chenfang Date: Thu, 14 Mar 2024 16:55:42 +0800 Subject: [PATCH 13/22] =?UTF-8?q?=E7=89=A9=E6=96=99=E5=BA=93=E5=8C=BA?= =?UTF-8?q?=E9=85=8D=E7=BD=AE=E5=89=8D=E6=AE=B5=E6=90=9C=E7=B4=A2=E6=A1=86?= =?UTF-8?q?=E8=AE=BE=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../itemManage/itemarea/index.vue | 9 ++ .../itemManage/itemarea/itemarea.data.ts | 87 ++++++++++++++++++- 2 files changed, 94 insertions(+), 2 deletions(-) diff --git a/src/views/wms/basicDataManage/itemManage/itemarea/index.vue b/src/views/wms/basicDataManage/itemManage/itemarea/index.vue index 9be383b88..f932f89c5 100644 --- a/src/views/wms/basicDataManage/itemManage/itemarea/index.vue +++ b/src/views/wms/basicDataManage/itemManage/itemarea/index.vue @@ -113,6 +113,15 @@ const updataTableColumns = (val) => { // 查询页面返回 const searchTableSuccess = (formField, searchField, val, formRef, type, row ) => { nextTick(() => { + if (type == 'tableForm') { + if(formField == 'locationGroupCode') { + row['locationGroupCode'] = val[0]['code'] + }else if(formField == 'locationCode') { + row['locationCode'] = val[0]['code'] + }else{ + row[formField] = val[0][searchField] + } + } const setV = {} setV[formField] = val[0][searchField] formRef.setValues(setV) diff --git a/src/views/wms/basicDataManage/itemManage/itemarea/itemarea.data.ts b/src/views/wms/basicDataManage/itemManage/itemarea/itemarea.data.ts index 61b173455..928f75071 100644 --- a/src/views/wms/basicDataManage/itemManage/itemarea/itemarea.data.ts +++ b/src/views/wms/basicDataManage/itemManage/itemarea/itemarea.data.ts @@ -1,9 +1,18 @@ import type { CrudSchema } from '@/hooks/web/useCrudSchemas' import { dateFormatter } from '@/utils/formatTime' + import * as ItembasicApi from '@/api/wms/itembasic' import { Itembasic } from '../itembasic/itembasic.data' + import * as AreaApi from '@/api/wms/areabasic' import { Area } from '../../factoryModeling/areabasic/areabasic.data' + +import * as LocationgroupApi from '@/api/wms/locationgroup' +import { Locationgroup } from '../../factoryModeling/locationgroup/locationgroup.data' + +import * as LocationApi from '@/api/wms/location' +import { Location } from '../../factoryModeling/location/location.data' + import * as PackageunitApi from '@/api/wms/packageunit' import { Packageunit } from '../packageunit/packageunit.data' @@ -637,13 +646,83 @@ export const ItemareaRules = reactive({ export const ItemareaDetail = useCrudSchemas(reactive([ { label: '库位组', - field: 'locationGroup', - sort: 'custom', + field: 'locationGroupCode', + sort: 'custom', + tableForm:{ + isInpuFocusShow: true, // 开启查询弹窗 + searchListPlaceholder: '请选择库位组代码', // 输入框占位文本 + searchField: 'code', // 查询弹窗赋值字段 + searchTitle: '库位组基础信息', // 查询弹窗标题 + searchAllSchemas: Locationgroup.allSchemas, // 查询弹窗所需类 + searchPage: LocationgroupApi.getLocationgroupPage, // 查询弹窗所需分页方法 + searchCondition: [{ + key: 'available', + value: 'TRUE', + isMainValue: false + }] + }, + form: { + // labelMessage: '信息提示说明!!!', + componentProps: { + isSearchList: true, // 开启查询弹窗 + searchListPlaceholder: '请选择库位组代码', // 输入框占位文本 + searchField: 'code', // 查询弹窗赋值字段 + searchTitle: '库位组基础信息', // 查询弹窗标题 + searchAllSchemas: Locationgroup.allSchemas, // 查询弹窗所需类 + searchPage: LocationgroupApi.getLocationgroupPage, // 查询弹窗所需分页方法 + searchCondition: [{ + key: 'available', + value: 'TRUE', + action: '==', + isSearch: true, + isMainValue: false + }] + } + } }, { label: '库位代码', field: 'locationCode', sort: 'custom', + tableForm:{ + isInpuFocusShow: true, // 开启查询弹窗 + searchListPlaceholder: '请选择库位代码', // 输入框占位文本 + searchField: 'code', // 查询弹窗赋值字段 + searchTitle: '库位基础信息', // 查询弹窗标题 + searchAllSchemas: Location.allSchemas, // 查询弹窗所需类 + searchPage: LocationApi.getLocationPage, // 查询弹窗所需分页方法 + searchCondition: [{ + key: 'available', + value: 'TRUE', + isMainValue: false + },{ + key: 'locationGroupCode', + value: 'locationGroupCode', + message: '请选择库位组!', + isMainValue: true + }] + }, + form: { + // labelMessage: '信息提示说明!!!', + componentProps: { + isSearchList: true, // 开启查询弹窗 + searchListPlaceholder: '请选择库位代码', // 输入框占位文本 + searchField: 'code', // 查询弹窗赋值字段 + searchTitle: '库位基础信息', // 查询弹窗标题 + searchAllSchemas: Location.allSchemas, // 查询弹窗所需类 + searchPage: LocationApi.getLocationPage, // 查询弹窗所需分页方法 + searchCondition: [{ + key: 'available', + value: 'TRUE', + isMainValue: false + },{ + key: 'locationGroupCode', + value: 'locationGroupCode', + message: '请选择库位组!', + isMainValue: true + }] + } + } }, { label: '备注', @@ -656,12 +735,14 @@ export const ItemareaDetail = useCrudSchemas(reactive([ sort: 'custom', formatter: dateFormatter, isForm: false, + isTableForm: false, }, { label: '创建者Id', field: 'creator', sort: 'custom', isForm: false, + isTableForm: false, }, { label: '最后更新时间', @@ -669,12 +750,14 @@ export const ItemareaDetail = useCrudSchemas(reactive([ sort: 'custom', formatter: dateFormatter, isForm: false, + isTableForm: false, }, { label: '最后更新者Id', field: 'updater', sort: 'custom', isForm: false, + isTableForm: false, }, { label: '操作', From 989abd1dfd7c8f04685446852ae1b13bb6438ad9 Mon Sep 17 00:00:00 2001 From: bjang03 Date: Thu, 14 Mar 2024 17:15:44 +0800 Subject: [PATCH 14/22] =?UTF-8?q?1=E3=80=81=E5=B7=A5=E4=BD=8D=E7=AE=A1?= =?UTF-8?q?=E7=90=86=E5=A2=9E=E5=8A=A0=E7=8F=AD=E7=BB=84=E3=80=81=E4=BA=A7?= =?UTF-8?q?=E7=BA=BF=E6=90=9C=E7=B4=A2=E5=8F=8A=E7=BB=91=E5=AE=9A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../workstation/workstation.data.ts | 69 +------------------ 1 file changed, 1 insertion(+), 68 deletions(-) diff --git a/src/views/wms/basicDataManage/factoryModeling/workstation/workstation.data.ts b/src/views/wms/basicDataManage/factoryModeling/workstation/workstation.data.ts index 9154437fa..bf6753484 100644 --- a/src/views/wms/basicDataManage/factoryModeling/workstation/workstation.data.ts +++ b/src/views/wms/basicDataManage/factoryModeling/workstation/workstation.data.ts @@ -108,74 +108,7 @@ export const Workstation = useCrudSchemas(reactive([ } } }, - { - label: '班组代码', - field: 'teamCode', - sort: 'custom', - isSearch: true, - table: { - width: 150 - }, - form: { - // labelMessage: '信息提示说明!!!', - componentProps: { - isSearchList: true, // 开启查询弹窗 - searchListPlaceholder: '请选择班组代码', // 输入框占位文本 - searchField: 'code', // 查询弹窗赋值字段 - searchTitle: '班组信息', // 查询弹窗标题 - searchAllSchemas: Team.allSchemas, // 查询弹窗所需类 - searchPage: TeamApi.getTeamPage, // 查询弹窗所需分页方法 - searchCondition: [{ - key: 'available', - value: 'TRUE', - isMainValue: false - }] - } - } - }, - { - label: '设备代码', - field: 'equipmentCode', - sort: 'custom', - isSearch: true, - table: { - width: 150 - }, - form: { - // labelMessage: '信息提示说明!!!', - componentProps: { - isSearchList: true, // 开启查询弹窗 - searchListPlaceholder: '请选择设备代码', // 输入框占位文本 - searchField: 'code', // 查询弹窗赋值字段 - searchTitle: '设备信息', // 查询弹窗标题 - searchAllSchemas: Team.allSchemas, // 查询弹窗所需类 - searchPage: ProductionlineApi.getProductionlinePage, // 查询弹窗所需分页方法 - searchCondition: [{ - key: 'available', - value: 'TRUE', - isMainValue: false - }] - } - } - }, - // { - // label: '产品代码', - // field: 'productCode', - // sort: 'custom', - // table: { - // width: 150 - // }, - // isSearch: true - // }, - // { - // label: '工序代码', - // field: 'processCode', - // sort: 'custom', - // table: { - // width: 150 - // }, - // isSearch: true - // }, + { label: '原料库位', field: 'rawLocationCode', From 79035813d54d845e143b4dd845cc5fd2e9d9bcb0 Mon Sep 17 00:00:00 2001 From: zhaoxuebing <1291173720@qq.com> Date: Thu, 14 Mar 2024 17:54:07 +0800 Subject: [PATCH 15/22] =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/wms/itembasic/index.ts | 1 + .../wms/basicDataManage/itemManage/itemarea/itemarea.data.ts | 2 -- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/src/api/wms/itembasic/index.ts b/src/api/wms/itembasic/index.ts index baa9cb66b..52a8dec1b 100644 --- a/src/api/wms/itembasic/index.ts +++ b/src/api/wms/itembasic/index.ts @@ -32,6 +32,7 @@ export interface ItembasicVO { // 查询物料基本信息列表 export const getItembasicPage = async (params) => { if (params.isSearch) { + delete params.isSearch const data = {...params} return request.post({ url: '/wms/itembasic/senior', data }) } else { diff --git a/src/views/wms/basicDataManage/itemManage/itemarea/itemarea.data.ts b/src/views/wms/basicDataManage/itemManage/itemarea/itemarea.data.ts index 928f75071..20732e286 100644 --- a/src/views/wms/basicDataManage/itemManage/itemarea/itemarea.data.ts +++ b/src/views/wms/basicDataManage/itemManage/itemarea/itemarea.data.ts @@ -38,8 +38,6 @@ export const Itemarea = useCrudSchemas(reactive([ searchCondition: [{ key: 'available', value: 'TRUE', - action: '==', - isSearch: true, isMainValue: false }] } From e53a0d92775787818b6d30828e687d7d1f6d011c Mon Sep 17 00:00:00 2001 From: chenfang Date: Thu, 14 Mar 2024 18:06:17 +0800 Subject: [PATCH 16/22] =?UTF-8?q?=E7=89=A9=E6=96=99=E5=BA=93=E5=8C=BA?= =?UTF-8?q?=E9=85=8D=E7=BD=AE=E5=B1=95=E7=A4=BA=E5=AD=97=E6=AE=B5=E6=9B=B4?= =?UTF-8?q?=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../itemManage/itemarea/itemarea.data.ts | 84 ++----------------- 1 file changed, 9 insertions(+), 75 deletions(-) diff --git a/src/views/wms/basicDataManage/itemManage/itemarea/itemarea.data.ts b/src/views/wms/basicDataManage/itemManage/itemarea/itemarea.data.ts index 20732e286..ecb3e4260 100644 --- a/src/views/wms/basicDataManage/itemManage/itemarea/itemarea.data.ts +++ b/src/views/wms/basicDataManage/itemManage/itemarea/itemarea.data.ts @@ -63,8 +63,6 @@ export const Itemarea = useCrudSchemas(reactive([ searchCondition: [{ key: 'available', value: 'TRUE', - action: '==', - isSearch: true, isMainValue: false }] } @@ -90,8 +88,6 @@ export const Itemarea = useCrudSchemas(reactive([ searchCondition: [{ key: 'available', value: 'TRUE', - action: '==', - isSearch: true, isMainValue: false }] } @@ -117,8 +113,6 @@ export const Itemarea = useCrudSchemas(reactive([ searchCondition: [{ key: 'available', value: 'TRUE', - action: '==', - isSearch: true, isMainValue: false }] } @@ -209,8 +203,6 @@ export const Itemarea = useCrudSchemas(reactive([ searchCondition: [{ key: 'available', value: 'TRUE', - action: '==', - isSearch: true, isMainValue: false }] } @@ -646,38 +638,10 @@ export const ItemareaDetail = useCrudSchemas(reactive([ label: '库位组', field: 'locationGroupCode', sort: 'custom', - tableForm:{ - isInpuFocusShow: true, // 开启查询弹窗 - searchListPlaceholder: '请选择库位组代码', // 输入框占位文本 - searchField: 'code', // 查询弹窗赋值字段 - searchTitle: '库位组基础信息', // 查询弹窗标题 - searchAllSchemas: Locationgroup.allSchemas, // 查询弹窗所需类 - searchPage: LocationgroupApi.getLocationgroupPage, // 查询弹窗所需分页方法 - searchCondition: [{ - key: 'available', - value: 'TRUE', - isMainValue: false - }] - }, - form: { - // labelMessage: '信息提示说明!!!', - componentProps: { - isSearchList: true, // 开启查询弹窗 - searchListPlaceholder: '请选择库位组代码', // 输入框占位文本 - searchField: 'code', // 查询弹窗赋值字段 - searchTitle: '库位组基础信息', // 查询弹窗标题 - searchAllSchemas: Locationgroup.allSchemas, // 查询弹窗所需类 - searchPage: LocationgroupApi.getLocationgroupPage, // 查询弹窗所需分页方法 - searchCondition: [{ - key: 'available', - value: 'TRUE', - action: '==', - isSearch: true, - isMainValue: false - }] - } - } + isForm: false, + isTableForm: false, }, + { label: '库位代码', field: 'locationCode', @@ -694,9 +658,9 @@ export const ItemareaDetail = useCrudSchemas(reactive([ value: 'TRUE', isMainValue: false },{ - key: 'locationGroupCode', - value: 'locationGroupCode', - message: '请选择库位组!', + key: 'areaCode', + value: 'areaCode', + message: '请选择区域代码!', isMainValue: true }] }, @@ -714,9 +678,9 @@ export const ItemareaDetail = useCrudSchemas(reactive([ value: 'TRUE', isMainValue: false },{ - key: 'locationGroupCode', - value: 'locationGroupCode', - message: '请选择库位组!', + key: 'areaCode', + value: 'areaCode', + message: '请选择区域代码!', isMainValue: true }] } @@ -727,36 +691,6 @@ export const ItemareaDetail = useCrudSchemas(reactive([ field: 'remark', sort: 'custom', }, - { - label: '创建时间', - field: 'createTime', - sort: 'custom', - formatter: dateFormatter, - isForm: false, - isTableForm: false, - }, - { - label: '创建者Id', - field: 'creator', - sort: 'custom', - isForm: false, - isTableForm: false, - }, - { - label: '最后更新时间', - field: 'updateTime', - sort: 'custom', - formatter: dateFormatter, - isForm: false, - isTableForm: false, - }, - { - label: '最后更新者Id', - field: 'updater', - sort: 'custom', - isForm: false, - isTableForm: false, - }, { label: '操作', field: 'action', From d660fb9e6cd6feecb0b2a3db780875daf9e8e768 Mon Sep 17 00:00:00 2001 From: zhaoxuebing <1291173720@qq.com> Date: Thu, 14 Mar 2024 19:49:16 +0800 Subject: [PATCH 17/22] =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/wms/putawayRecordDetail/index.ts | 5 + .../putaway/putawayRecordMain/index.vue | 57 +++- .../putawayRecordMain.data.ts | 276 +++++++++++++++++- 3 files changed, 336 insertions(+), 2 deletions(-) diff --git a/src/api/wms/putawayRecordDetail/index.ts b/src/api/wms/putawayRecordDetail/index.ts index af8a43321..2d98839a1 100644 --- a/src/api/wms/putawayRecordDetail/index.ts +++ b/src/api/wms/putawayRecordDetail/index.ts @@ -73,4 +73,9 @@ export const exportPutawayRecordDetail = async (params) => { // 下载用户导入模板 export const importTemplate = () => { return request.download({ url: '/wms/putaway-record-detail/get-import-template' }) +} + +// 查询上架记录子列表--子包装数据 +export const getPutawayJobDetailPageChildPackingNumber = async (params) => { + return await request.get({ url: `/wms/putaway-record-detail/pageChildPackingNumber`, params }) } \ No newline at end of file diff --git a/src/views/wms/purchasereceiptManage/putaway/putawayRecordMain/index.vue b/src/views/wms/purchasereceiptManage/putaway/putawayRecordMain/index.vue index 9c02e442d..09a9480c7 100644 --- a/src/views/wms/purchasereceiptManage/putaway/putawayRecordMain/index.vue +++ b/src/views/wms/purchasereceiptManage/putaway/putawayRecordMain/index.vue @@ -57,12 +57,35 @@ :detailAllSchemas="PutawayRecordDetail.allSchemas" :detailAllSchemasRules="PutawayRecordDetailRules" :apiPage="PutawayRecordDetailApi.getPutawayRecordDetailPage" + :detailButtonIsShowAdd="false" + :detailButtonIsShowEdit="false" + :detailButtonIsShowDelete="false" + :buttondataTable="buttondataTable" + @tableFormButton="tableFormButton" /> + + + + diff --git a/src/views/wms/deliversettlementManage/stockup/stockupMainRecord/stockupMainRecord.data.ts b/src/views/wms/deliversettlementManage/stockup/stockupMainRecord/stockupMainRecord.data.ts index a503624dc..feaa984b8 100644 --- a/src/views/wms/deliversettlementManage/stockup/stockupMainRecord/stockupMainRecord.data.ts +++ b/src/views/wms/deliversettlementManage/stockup/stockupMainRecord/stockupMainRecord.data.ts @@ -5,73 +5,81 @@ import { dateFormatter } from '@/utils/formatTime' export const StockupMainRecordRules = reactive({ }) +//主表 export const StockupMainRecord = useCrudSchemas(reactive([ { - label: 'id', - field: 'id', + label: '单据号', + field: 'number', sort: 'custom', - isForm: false, + isSearch: true, + table: { + width: 180 + }, }, { label: '申请单号', field: 'requestNumber', sort: 'custom', isSearch: true, + table: { + width: 180 + }, }, { label: '任务单号', field: 'jobNumber', sort: 'custom', isSearch: true, + table: { + width: 180 + }, }, { label: '发货计划单号', field: 'deliverPlanNumber', sort: 'custom', isSearch: true, + table: { + width: 180 + }, }, { label: '从仓库代码', field: 'fromWarehouseCode', sort: 'custom', - isSearch: true, + table: { + width: 150 + }, }, { label: '到仓库代码', field: 'toWarehouseCode', sort: 'custom', - isSearch: true, - }, - { - label: '明细', - field: 'details', - sort: 'custom', - isSearch: true, + table: { + width: 150 + }, }, { label: '出库事务类型', field: 'outTransactionType', sort: 'custom', - isSearch: true, - form: { - component: 'SelectV2' - }, + table: { + width: 150 + }, }, { label: '入库事务类型', field: 'inTransactionType', sort: 'custom', - isSearch: true, - form: { - component: 'SelectV2' - }, + table: { + width: 150 + }, }, { label: '执行时间', field: 'executeTime', sort: 'custom', formatter: dateFormatter, - isSearch: true, search: { component: 'DatePicker', componentProps: { @@ -80,6 +88,9 @@ export const StockupMainRecord = useCrudSchemas(reactive([ defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')] } }, + table: { + width: 180 + }, form: { component: 'DatePicker', componentProps: { @@ -93,46 +104,33 @@ export const StockupMainRecord = useCrudSchemas(reactive([ field: 'activeDate', sort: 'custom', formatter: dateFormatter, - isSearch: true, - search: { - component: 'DatePicker', - componentProps: { - valueFormat: 'YYYY-MM-DD HH:mm:ss', - type: 'daterange', - defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')] - } + detail: { + dateFormat: 'YYYY-MM-DD HH:mm:ss' + }, + table: { + width: 180 }, form: { component: 'DatePicker', componentProps: { type: 'datetime', + dateFormat: 'YYYY-MM-DD HH:mm:ss', valueFormat: 'x' } }, }, - { - label: '是否可用', - field: 'available', - sort: 'custom', - isSearch: true, - }, { label: '申请时间', field: 'requestTime', sort: 'custom', formatter: dateFormatter, - isSearch: true, - search: { - component: 'DatePicker', - componentProps: { - valueFormat: 'YYYY-MM-DD HH:mm:ss', - type: 'daterange', - defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')] - } + table: { + width: 180 }, form: { component: 'DatePicker', componentProps: { + dateFormat: 'YYYY-MM-DD HH:mm:ss', type: 'datetime', valueFormat: 'x' } @@ -143,7 +141,6 @@ export const StockupMainRecord = useCrudSchemas(reactive([ field: 'dueTime', sort: 'custom', formatter: dateFormatter, - isSearch: true, search: { component: 'DatePicker', componentProps: { @@ -152,6 +149,9 @@ export const StockupMainRecord = useCrudSchemas(reactive([ defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')] } }, + table: { + width: 180 + }, form: { component: 'DatePicker', componentProps: { @@ -161,46 +161,280 @@ export const StockupMainRecord = useCrudSchemas(reactive([ }, }, { - label: '部门', - field: 'departmentCode', + label: '是否可用', + field: 'available', + dictType: DICT_TYPE.TRUE_FALSE, + dictClass: 'string', + isTable: true, sort: 'custom', - isSearch: true, + table: { + width: 150 + }, + form: { + component: 'Switch', + value: 'TRUE', + componentProps: { + inactiveValue: 'FALSE', + activeValue: 'TRUE' + } + } }, { - label: '用户组', - field: 'userGroupCode', + label: '部门', + field: 'departmentCode', sort: 'custom', - isSearch: true, + table: { + width: 150 + }, }, { label: '接口类型', field: 'interfaceType', + dictType: DICT_TYPE.INTERFACE_TYPE, + dictClass: 'string', + isTable: true, + sort: 'custom', + table: { + width: 150 + }, + }, + { + label: '业务类型', + field: 'businessType', + sort: 'custom', + table: { + width: 150 + }, + }, + { + label: '备注', + field: 'remark', + sort: 'custom', + table: { + width: 100 + }, + }, + { + label: '创建时间', + field: 'createTime', + sort: 'custom', + formatter: dateFormatter, + search: { + component: 'DatePicker', + componentProps: { + valueFormat: 'YYYY-MM-DD HH:mm:ss', + type: 'daterange', + defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')] + } + }, + table: { + width: 180 + }, + isForm: false, + }, + { + label: '从库区类型范围', + field: 'fromAreaTypes', + dictType: DICT_TYPE.LOCATION_TYPE, + dictClass: 'string', + isTable: true, + sort: 'custom', + table: { + width: 180 + }, + }, + { + label: '从库区代码范围', + field: 'fromAreaCodes', sort: 'custom', isSearch: true, - form: { - component: 'SelectV2' - }, }, + { + label: '到库区类型范围', + field: 'toAreaTypes', + dictType: DICT_TYPE.LOCATION_TYPE, + dictClass: 'string', + isTable: true, + sort: 'custom', + table: { + width: 180 + }, + }, + { + label: '到库区代码范围', + field: 'toAreaCodes', + sort: 'custom', + }, + { + label: '操作', + field: 'action', + isForm: false, + table: { + width: 150, + fixed: 'right' + } + } +])) +//子表 +// 表单校验 +export const StockupDetailRecordRules = reactive({ +}) + +export const StockupDetailRecord = useCrudSchemas(reactive([ { label: '单据号', field: 'number', sort: 'custom', isSearch: true, + table: { + width: 180 + }, }, { - label: '业务类型', - field: 'businessType', + label: '包装号', + field: 'packingNumber', + sort: 'custom', + isSearch: true, + table: { + width: 150 + }, + }, + { + label: '批次', + field: 'batch', + sort: 'custom', + isSearch: true, + table: { + width: 150 + }, + }, + { + label: '库存状态', + field: 'inventoryStatus', + dictType: DICT_TYPE.INVENTORY_STATUS, + dictClass: 'string', + isTable: true, + sort: 'custom', + table: { + width: 150 + }, + }, + { + label: '从货主代码', + field: 'fromOwnerCode', + sort: 'custom', + isSearch: true, + table: { + width: 150 + }, + }, + { + label: '从器具号', + field: 'fromContainerNumber', + sort: 'custom', + isSearch: true, + table: { + width: 150 + }, + }, + { + label: '从库位代码', + field: 'fromLocationCode', + sort: 'custom', + isSearch: true, + table: { + width: 150 + }, + }, + { + label: '从库位组代码', + field: 'fromLocationGroupCode', sort: 'custom', isSearch: true, - form: { - component: 'SelectV2' - }, + table: { + width: 150 + }, + }, + { + label: '从库区代码', + field: 'fromAreaCode', + sort: 'custom', + isSearch: true, + table: { + width: 150 + }, + }, + { + label: '到货主代码', + field: 'toOwnerCode', + sort: 'custom', + isSearch: true, + table: { + width: 150 + }, + }, + { + label: '到器具号', + field: 'toContainerNumber', + sort: 'custom', + isSearch: true, + table: { + width: 150 + }, + }, + { + label: '到库位代码', + field: 'toLocationCode', + sort: 'custom', + isSearch: true, + table: { + width: 150 + }, + }, + { + label: '到库位组代码', + field: 'toLocationGroupCode', + sort: 'custom', + isSearch: true, + table: { + width: 150 + }, + }, + { + label: '到库区代码', + field: 'toAreaCode', + sort: 'custom', + isSearch: true, + table: { + width: 150 + }, + }, + { + label: '单价', + field: 'singlePrice', + sort: 'custom', + isSearch: true, + table: { + width: 150 + }, + }, + { + label: '金额', + field: 'amount', + sort: 'custom', + isSearch: true, + table: { + width: 150 + }, }, { label: '备注', field: 'remark', sort: 'custom', isSearch: true, + table: { + width: 150 + }, }, { label: '创建时间', @@ -208,6 +442,9 @@ export const StockupMainRecord = useCrudSchemas(reactive([ sort: 'custom', formatter: dateFormatter, isSearch: true, + table: { + width: 180 + }, search: { component: 'DatePicker', componentProps: { @@ -219,46 +456,100 @@ export const StockupMainRecord = useCrudSchemas(reactive([ isForm: false, }, { - label: '扩展属性', - field: 'extraProperties', + label: '物品代码', + field: 'itemCode', sort: 'custom', isSearch: true, + table: { + width: 150 + }, }, { - label: '地点ID', - field: 'siteId', + label: '物品名称', + field: 'itemName', sort: 'custom', isSearch: true, + table: { + width: 150 + }, }, { - label: '代码', - field: 'code', + label: '物品描述1', + field: 'itemDesc1', sort: 'custom', isSearch: true, + table: { + width: 150 + }, }, { - label: '从库区类型范围', - field: 'fromAreaTypes', + label: '物品描述2', + field: 'itemDesc2', sort: 'custom', isSearch: true, + table: { + width: 150 + }, }, { - label: '从库区代码范围', - field: 'fromAreaCodes', + label: '项目代码', + field: 'projectCode', sort: 'custom', isSearch: true, + table: { + width: 150 + }, }, { - label: '到库区类型范围', - field: 'toAreaTypes', + label: '数量', + field: 'qty', sort: 'custom', isSearch: true, + table: { + width: 150 + }, }, { - label: '到库区代码范围', - field: 'toAreaCodes', + label: '计量单位', + field: 'uom', + dictType: DICT_TYPE.UOM, + dictClass: 'string', + isTable: true, + sort: 'custom', + table: { + width: 150 + }, + }, + { + label: '接口类型', + field: 'interfaceType', + dictType: DICT_TYPE.INTERFACE_TYPE, + dictClass: 'string', + isTable: true, sort: 'custom', + table: { + width: 150 + }, + }, + { + label: '是否可用', + field: 'available', + dictType: DICT_TYPE.TRUE_FALSE, + dictClass: 'string', isSearch: true, + isTable: true, + sort: 'custom', + table: { + width: 150 + }, + form: { + component: 'Switch', + value: 'TRUE', + componentProps: { + inactiveValue: 'FALSE', + activeValue: 'TRUE' + } + } }, { label: '操作', From b96f23a3216e1ac21e6cd586ccd7df356c9ef3f6 Mon Sep 17 00:00:00 2001 From: bjang03 Date: Fri, 15 Mar 2024 11:34:27 +0800 Subject: [PATCH 22/22] =?UTF-8?q?1=E3=80=81=E5=B7=A5=E4=BD=8D=E7=AE=A1?= =?UTF-8?q?=E7=90=86=E5=A2=9E=E5=8A=A0=E7=8F=AD=E7=BB=84=E3=80=81=E4=BA=A7?= =?UTF-8?q?=E7=BA=BF=E6=90=9C=E7=B4=A2=E5=8F=8A=E7=BB=91=E5=AE=9A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/mes/index.ts | 0 src/api/mes/workstation/index.ts | 49 ++++ src/utils/disposition/defaultButtons.ts | 12 + src/views/mes/workstation/index.vue | 248 ++++++++++++++++++ src/views/mes/workstation/workstation.data.ts | 78 ++++++ 5 files changed, 387 insertions(+) delete mode 100644 src/api/mes/index.ts create mode 100644 src/api/mes/workstation/index.ts create mode 100644 src/views/mes/workstation/index.vue create mode 100644 src/views/mes/workstation/workstation.data.ts diff --git a/src/api/mes/index.ts b/src/api/mes/index.ts deleted file mode 100644 index e69de29bb..000000000 diff --git a/src/api/mes/workstation/index.ts b/src/api/mes/workstation/index.ts new file mode 100644 index 000000000..f12b0a5c4 --- /dev/null +++ b/src/api/mes/workstation/index.ts @@ -0,0 +1,49 @@ +import request from '@/config/axios' + +export interface WorkstationVO { + code: string + activeTime: Date + expireTime: Date + name: string +} + +// 查询工位列表 +export const getWorkstationPage = async (params) => { + if (params.isSearch) { + delete params.isSearch + const data = {...params} + return await request.post({ url: '/mes/workstation/senior', data }) + } else { + return await request.get({ url: `/mes/workstation/page`, params }) + } +} + +// 查询工位详情 +export const getWorkstation = async (id: number) => { + return await request.get({ url: `/mes/workstation/get?id=` + id }) +} + +// 新增工位 +export const createWorkstation = async (data: WorkstationVO) => { + return await request.post({ url: `/mes/workstation/create`, data }) +} + +// 修改工位 +export const updateWorkstation = async (data: WorkstationVO) => { + return await request.put({ url: `/mes/workstation/update`, data }) +} + +// 删除工位 +export const deleteWorkstation = async (id: number) => { + return await request.delete({ url: `/mes/workstation/delete?id=` + id }) +} + +// 导出工位 Excel +export const exportWorkstation = async (params) => { + return await request.download({ url: `/mes/workstation/export-excel`, params }) +} + +// 下载用户导入模板 +export const importTemplate = () => { + return request.download({ url: '/mes/workstation/get-import-template' }) +} diff --git a/src/utils/disposition/defaultButtons.ts b/src/utils/disposition/defaultButtons.ts index f25895502..b7f8ca791 100644 --- a/src/utils/disposition/defaultButtons.ts +++ b/src/utils/disposition/defaultButtons.ts @@ -735,6 +735,18 @@ export function mainThawRequesttBtn(option:any) { hasPermi: '' }) } +// 主列表-绑定 +export function mainListBindBtn(option:any) { + return __defaultBtnOption(option,{ + label: '绑定', + name: 'bind', + hide: false, + type: 'primary', + color: '', + link: true, // 文本展现按钮 + hasPermi: '' + }) +} // 默认按钮规则 function __defaultBtnOption(option:any,specific:any){ return { diff --git a/src/views/mes/workstation/index.vue b/src/views/mes/workstation/index.vue new file mode 100644 index 000000000..c72da2656 --- /dev/null +++ b/src/views/mes/workstation/index.vue @@ -0,0 +1,248 @@ + + + diff --git a/src/views/mes/workstation/workstation.data.ts b/src/views/mes/workstation/workstation.data.ts new file mode 100644 index 000000000..b74f05a6d --- /dev/null +++ b/src/views/mes/workstation/workstation.data.ts @@ -0,0 +1,78 @@ +import type { CrudSchema } from '@/hooks/web/useCrudSchemas' +import { dateFormatter } from '@/utils/formatTime' +// 表单校验 +export const WorkstationRules = reactive({ + code: [required], + name: [required] +}) + +export const Workstation = useCrudSchemas(reactive([ + { + label: '代码', + field: 'code', + sort: 'custom', + isSearch: true + }, + { + label: '名称', + field: 'name', + sort: 'custom', + isSearch: true + }, + { + label: '车间代码', + field: 'workshopCode', + sort: 'custom', + isSearch: true, + isForm: false + }, + { + label: '生产线代码', + field: 'productionLineCode', + sort: 'custom', + isSearch: true, + isForm: false + }, + { + label: '班组代码', + field: 'teamCode', + sort: 'custom', + isSearch: true, + isForm: false + }, + { + label: '生效时间', + field: 'activeTime', + sort: 'custom', + formatter: dateFormatter, + form: { + component: 'DatePicker', + componentProps: { + type: 'datetime', + valueFormat: 'x' + } + } + }, + { + label: '失效时间', + field: 'expireTime', + sort: 'custom', + formatter: dateFormatter, + form: { + component: 'DatePicker', + componentProps: { + type: 'datetime', + valueFormat: 'x' + } + } + }, + { + label: '操作', + field: 'action', + isForm: false, + table: { + width: 150, + fixed: 'right' + } + } +]))