From 2c88799d1133f5bec19c2759debfa87001632b2d Mon Sep 17 00:00:00 2001 From: chenfang Date: Mon, 19 Feb 2024 14:14:59 +0800 Subject: [PATCH 1/8] =?UTF-8?q?api=E8=A1=A5=E5=85=A8=E5=8F=8A=E9=83=A8?= =?UTF-8?q?=E5=88=86=E6=90=9C=E7=B4=A2=E6=A1=86=E4=BF=AE=E6=AD=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/wms/supplierUser/index.ts | 7 ++++++- .../basicDataManage/customerManage/project/index.vue | 2 +- .../documentsetting/documentsetting.data.ts | 11 +++++++++-- .../factoryModeling/process/index.vue | 4 ++-- .../wms/basicDataManage/itemManage/bom/bom.data.ts | 8 ++++---- .../labelManage/barcode/barcode.data.ts | 4 ++++ .../purchaseprice/purchaseprice.data.ts | 12 ++++++------ .../inventorymove/inventorymoveRequestMain/index.vue | 1 + 8 files changed, 33 insertions(+), 16 deletions(-) diff --git a/src/api/wms/supplierUser/index.ts b/src/api/wms/supplierUser/index.ts index bdb7c5b75..a7d284e80 100644 --- a/src/api/wms/supplierUser/index.ts +++ b/src/api/wms/supplierUser/index.ts @@ -45,7 +45,12 @@ export const deleteSupplierUser = async (id: number) => { // 导出供应商用户关联信息 Excel export const exportSupplierUser = async (params) => { - return await request.download({ url: `/wms/supplier-user/export-excel`, params }) + if (params.isSearch) { + const data = {...params} + return await request.downloadPost({ url: `/wms/supplier-user/export-excel-senior`, data }) + } else { + return await request.download({ url: `/wms/supplier-user/export-excel`, params }) + } } // 下载用户导入模板 diff --git a/src/views/wms/basicDataManage/customerManage/project/index.vue b/src/views/wms/basicDataManage/customerManage/project/index.vue index 196fe3fb9..e5a4303fc 100644 --- a/src/views/wms/basicDataManage/customerManage/project/index.vue +++ b/src/views/wms/basicDataManage/customerManage/project/index.vue @@ -155,7 +155,7 @@ const openForm = (type: string, row?: any) => { item.componentProps.isSearchList = false } if (item.field == 'code') { - item.componentProps.disabled = TransferissueJobMain + item.componentProps.disabled = true } }) }else { diff --git a/src/views/wms/basicDataManage/documentSetting/documentsetting/documentsetting.data.ts b/src/views/wms/basicDataManage/documentSetting/documentsetting/documentsetting.data.ts index ff8f871f3..403fd4ce6 100644 --- a/src/views/wms/basicDataManage/documentSetting/documentsetting/documentsetting.data.ts +++ b/src/views/wms/basicDataManage/documentSetting/documentsetting/documentsetting.data.ts @@ -85,6 +85,14 @@ export const Documentsetting = useCrudSchemas(reactive([ table: { width: 150 }, + form: { + component: 'InputNumber', + componentProps: { + min: 0, + max: 50, + precision: 0 + } + }, }, { label: '号码分隔符', @@ -252,8 +260,7 @@ export const DocumentsettingRules = reactive({ { max: 50, message: '不得超过50个字符', trigger: 'blur' } ], serialLength: [ - { required: true, message: '请输入号码流水长度', trigger: 'blur' }, - { max: 50, message: '不得超过50个字符', trigger: 'blur' } + { required: true, message: '请输入号码流水长度', trigger: 'blur' } ], resetPeriod: [ { required: true, message: '请选择流水重置周期', trigger: 'change' } diff --git a/src/views/wms/basicDataManage/factoryModeling/process/index.vue b/src/views/wms/basicDataManage/factoryModeling/process/index.vue index f98b88837..b3f70053f 100644 --- a/src/views/wms/basicDataManage/factoryModeling/process/index.vue +++ b/src/views/wms/basicDataManage/factoryModeling/process/index.vue @@ -173,8 +173,8 @@ const openForm = (type: string, row?: any) => { item.componentProps.isSearchList = true } if (item.field == 'productionLineCode') { - item.componentProps.disabled = true - item.componentProps.isSearchList = false + item.componentProps.disabled = false + item.componentProps.isSearchList = true } }) } diff --git a/src/views/wms/basicDataManage/itemManage/bom/bom.data.ts b/src/views/wms/basicDataManage/itemManage/bom/bom.data.ts index 6dc20de14..ed90ce54a 100644 --- a/src/views/wms/basicDataManage/itemManage/bom/bom.data.ts +++ b/src/views/wms/basicDataManage/itemManage/bom/bom.data.ts @@ -245,18 +245,18 @@ export const BomRules = reactive({ ], processCode: [ { required: true, message: '请输入工序代码', trigger: 'blur' }, - { max: 50, message: '不得超过50个字符', trigger: 'blur' }, + { max: 50, message: '不得超过50个字符', trigger: 'change' }, ], version: [ { required: true, message: '请输入版本', trigger: 'blur' }, - { max: 50, message: '不得超过50个字符', trigger: 'blur' } + { max: 50, message: '不得超过50个字符', trigger: 'change' } ], layer: [ { required: true, message: '请输入层级', trigger: 'blur' }, - { max: 50, message: '不得超过50个字符', trigger: 'blur' } + { max: 50, message: '不得超过50个字符', trigger: 'change' } ], remark: [ - { max: 50, message: '不得超过50个字符', trigger: 'blur' } + { max: 50, message: '不得超过50个字符', trigger: 'change' } ], available: [ { required: true, message: '请选择是否可用', trigger: 'change' } diff --git a/src/views/wms/basicDataManage/labelManage/barcode/barcode.data.ts b/src/views/wms/basicDataManage/labelManage/barcode/barcode.data.ts index 33eec5260..f8b2e383e 100644 --- a/src/views/wms/basicDataManage/labelManage/barcode/barcode.data.ts +++ b/src/views/wms/basicDataManage/labelManage/barcode/barcode.data.ts @@ -16,6 +16,7 @@ export const BarcodeRules = reactive({ length: [required], prefixLenght: [required], prefixChar: [ + { required: true, message: '请输入前缀字符', trigger: 'blur' }, { max: 50, message: '不得超过50个字符', trigger: 'blur' } ], entityProperties: [ @@ -29,6 +30,9 @@ export const BarcodeRules = reactive({ { required: true, message: '请输入截断尾部空格', trigger: 'blur' }, { max: 50, message: '不得超过50个字符', trigger: 'blur' } ], + labelType:[ + { required: true, message: '请选择标签类型', trigger: 'blur' } + ], isEncypt: [required], }) diff --git a/src/views/wms/basicDataManage/supplierManage/purchaseprice/purchaseprice.data.ts b/src/views/wms/basicDataManage/supplierManage/purchaseprice/purchaseprice.data.ts index 84c9f5d0d..8c4897667 100644 --- a/src/views/wms/basicDataManage/supplierManage/purchaseprice/purchaseprice.data.ts +++ b/src/views/wms/basicDataManage/supplierManage/purchaseprice/purchaseprice.data.ts @@ -121,8 +121,8 @@ export const Purchaseprice = useCrudSchemas(reactive([ field: 'activeTime', isTable: true, formatter: dateFormatter, - details: { - dateFormatter: 'YYYY-MM-DD HH:mm:ss' + detail: { + dateFormat: 'YYYY-MM-DD HH:mm:ss' }, sort: 'custom', table: { @@ -143,8 +143,8 @@ export const Purchaseprice = useCrudSchemas(reactive([ field: 'expireTime', isTable: true, formatter: dateFormatter, - details: { - dateFormatter: 'YYYY-MM-DD HH:mm:ss' + detail: { + dateFormat: 'YYYY-MM-DD HH:mm:ss' }, sort: 'custom', table: { @@ -166,8 +166,8 @@ export const Purchaseprice = useCrudSchemas(reactive([ isTable: false, isForm:false, formatter: dateFormatter, - details: { - dateFormatter: 'YYYY-MM-DD HH:mm:ss' + detail: { + dateFormat: 'YYYY-MM-DD HH:mm:ss' }, sort: 'custom', table: { diff --git a/src/views/wms/moveManage/inventorymove/inventorymoveRequestMain/index.vue b/src/views/wms/moveManage/inventorymove/inventorymoveRequestMain/index.vue index 7edd66126..d02106a9e 100644 --- a/src/views/wms/moveManage/inventorymove/inventorymoveRequestMain/index.vue +++ b/src/views/wms/moveManage/inventorymove/inventorymoveRequestMain/index.vue @@ -601,6 +601,7 @@ const submitForm = async (formType, data) => { }) if (isExist) { formRef.value.formLoading = false + isExist = false return message.warning('包装号重复') } data.subList.forEach(item => { From fecd4d4b9da09cabd07c68a521c01b960feedb2b Mon Sep 17 00:00:00 2001 From: zhaoxuebing <1291173720@qq.com> Date: Mon, 19 Feb 2024 16:49:35 +0800 Subject: [PATCH 2/8] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E8=AE=B0=E5=BD=95?= =?UTF-8?q?=E5=88=9B=E5=BB=BA=E7=94=B3=E8=AF=B7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/wms/inspectRecordMain/index.ts | 7 +++++++ .../inspect/inspectRecordMain/index.vue | 19 ++++++++++++++++++- .../inspectRecordMain.data.ts | 18 ++++++++++-------- 3 files changed, 35 insertions(+), 9 deletions(-) diff --git a/src/api/wms/inspectRecordMain/index.ts b/src/api/wms/inspectRecordMain/index.ts index 6f3788867..2e8f09b9f 100644 --- a/src/api/wms/inspectRecordMain/index.ts +++ b/src/api/wms/inspectRecordMain/index.ts @@ -38,6 +38,7 @@ export interface InspectRecordMainVO { available: string sampleQty: number fromAreaTypes: string + putawayRequestFlag: boolean } // 查询检验记录主列表 @@ -85,3 +86,9 @@ export const exportInspectRecordMain = async (params) => { export const importTemplate = () => { return request.download({ url: '/wms/inspect-record-main/get-import-template' }) } + + +// 创建上架申请 +export const createPutAwayRequest = async (number:string) => { + return await request.post({ url: `/wms/inspect-record-main/createPutAwayRequest?number=`+number }) +} \ No newline at end of file diff --git a/src/views/wms/purchasereceiptManage/inspect/inspectRecordMain/index.vue b/src/views/wms/purchasereceiptManage/inspect/inspectRecordMain/index.vue index 1c8b11411..facd5be89 100644 --- a/src/views/wms/purchasereceiptManage/inspect/inspectRecordMain/index.vue +++ b/src/views/wms/purchasereceiptManage/inspect/inspectRecordMain/index.vue @@ -131,14 +131,31 @@ const buttonBaseClick = (val, item) => { // 列表-操作按钮 const butttondata = (row) => { return [ - defaultButtons.mainPutawayRequestBtn({hasPermi:'wms:inspectRecordMain:putawayRequest'}), // 生成采购上架申请 + defaultButtons.mainPutawayRequestBtn({hasPermi:'wms:inspectRecordMain:putawayRequest',hide:!row.putawayRequestFlag}), // 生成采购上架申请 ] } // 列表-操作按钮事件 const buttonTableClick = async (val, row) => { + if (val == 'putawayRequest') { // 生成采购上架申请 + handlePutawayRequest(row.number) + } } + + /** 生成采购上架申请按钮操作 */ + const handlePutawayRequest = async (number:string) => { + try{ + await message.confirm(t('确认生成上架申请吗?')) + tableObject.loading = true + await InspectRecordMainApi.createPutAwayRequest(number) + message.success(t('上架申请生成成功')) + await getList() + }catch{}finally{ + tableObject.loading = false + } + } + /** 详情操作 */ const detailRef = ref() const openDetail = (row: any, titleName: any, titleValue: any) => { diff --git a/src/views/wms/purchasereceiptManage/inspect/inspectRecordMain/inspectRecordMain.data.ts b/src/views/wms/purchasereceiptManage/inspect/inspectRecordMain/inspectRecordMain.data.ts index 39fb07152..abe003386 100644 --- a/src/views/wms/purchasereceiptManage/inspect/inspectRecordMain/inspectRecordMain.data.ts +++ b/src/views/wms/purchasereceiptManage/inspect/inspectRecordMain/inspectRecordMain.data.ts @@ -209,14 +209,6 @@ export const InspectRecordMain = useCrudSchemas(reactive([ width: 150 }, }, - // { - // label: '代码', - // field: 'code', - // sort: 'custom', - // table: { - // width: 150 - // }, - // }, { label: '订单号', field: 'poNumber', @@ -413,6 +405,16 @@ export const InspectRecordMain = useCrudSchemas(reactive([ activeValue: 'TRUE' } } + }, + { + label: '操作', + field: 'action', + isDetail: false, + isForm: false, + table: { + width: 300, + fixed: 'right' + }, } ])) From 67cab811bdd5b11cbfd9e64c3c8f9f578f7c499e Mon Sep 17 00:00:00 2001 From: zhaoxuebing <1291173720@qq.com> Date: Mon, 19 Feb 2024 17:15:31 +0800 Subject: [PATCH 3/8] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=BA=93=E5=8C=BA?= =?UTF-8?q?=E5=AD=97=E5=85=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../putaway/putawayJobMain/putawayJobMain.data.ts | 4 ++-- .../putaway/putawayRequestMain/putawayRequestMain.data.ts | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/views/wms/purchasereceiptManage/putaway/putawayJobMain/putawayJobMain.data.ts b/src/views/wms/purchasereceiptManage/putaway/putawayJobMain/putawayJobMain.data.ts index ad5fb3059..fcc7cfafe 100644 --- a/src/views/wms/purchasereceiptManage/putaway/putawayJobMain/putawayJobMain.data.ts +++ b/src/views/wms/purchasereceiptManage/putaway/putawayJobMain/putawayJobMain.data.ts @@ -210,7 +210,7 @@ export const PutawayJobMain = useCrudSchemas(reactive([ { label: '从库区类型范围', field: 'fromAreaTypes', - dictType: DICT_TYPE.LOCATION_TYPE, + dictType: DICT_TYPE.AREA_TYPE, dictClass: 'string', isTable: true, sort: 'custom', @@ -221,7 +221,7 @@ export const PutawayJobMain = useCrudSchemas(reactive([ { label: '到库区类型范围', field: 'toAreaTypes', - dictType: DICT_TYPE.LOCATION_TYPE, + dictType: DICT_TYPE.AREA_TYPE, dictClass: 'string', isTable: true, sort: 'custom', diff --git a/src/views/wms/purchasereceiptManage/putaway/putawayRequestMain/putawayRequestMain.data.ts b/src/views/wms/purchasereceiptManage/putaway/putawayRequestMain/putawayRequestMain.data.ts index 0c0d3f478..d14a075c8 100644 --- a/src/views/wms/purchasereceiptManage/putaway/putawayRequestMain/putawayRequestMain.data.ts +++ b/src/views/wms/purchasereceiptManage/putaway/putawayRequestMain/putawayRequestMain.data.ts @@ -73,7 +73,7 @@ export const PutawayRequestMain = useCrudSchemas(reactive([ { label: '从库区类型范围', field: 'fromAreaTypes', - dictType: DICT_TYPE.LOCATION_TYPE, + dictType: DICT_TYPE.AREA_TYPE, dictClass: 'string', isTable: true, sort: 'custom', From 3c2736a71d9c2a6166a4b6cea02aa70b4f0478b7 Mon Sep 17 00:00:00 2001 From: chenfang Date: Mon, 19 Feb 2024 17:29:25 +0800 Subject: [PATCH 4/8] =?UTF-8?q?=E5=B7=A5=E4=BD=8D=E7=AE=A1=E7=90=86=20=20?= =?UTF-8?q?=E5=8E=9F=E6=96=99/=E6=88=90=E5=93=81=E5=BA=93=E4=BD=8D=20?= =?UTF-8?q?=E7=AD=9B=E9=80=89=E6=95=B0=E6=8D=AE=E6=8E=A5=E5=8F=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/wms/workstation/index.ts | 15 +++++++--- .../factoryModeling/workstation/index.vue | 25 ++++++++++++++++ .../workstation/workstation.data.ts | 30 ++++--------------- 3 files changed, 41 insertions(+), 29 deletions(-) diff --git a/src/api/wms/workstation/index.ts b/src/api/wms/workstation/index.ts index 40e5dd648..5b0d662a5 100644 --- a/src/api/wms/workstation/index.ts +++ b/src/api/wms/workstation/index.ts @@ -61,7 +61,14 @@ export const importWorkstationTemplate = () => { return request.download({ url: '/wms/workstation/get-import-template' }) } -// 下载用户导入模板 -export const importTemplate = () => { - return request.download({ url: '/wms/workstation/get-import-template' }) -} + +// 根据库区筛选出的库位分页 +export const selectAreaTypeToLocation = async (params) => { + if (params.isSearch) { + delete params.isSearch + const data = {...params} + return request.post({ url: '/wms/workstation/pageAreaToLocationSenior', data }) + } else { + return await request.get({ url: `/wms/workstation/pageAreaToLocation`, params }) + } +} \ No newline at end of file diff --git a/src/views/wms/basicDataManage/factoryModeling/workstation/index.vue b/src/views/wms/basicDataManage/factoryModeling/workstation/index.vue index 2059b78a5..c3bca9191 100644 --- a/src/views/wms/basicDataManage/factoryModeling/workstation/index.vue +++ b/src/views/wms/basicDataManage/factoryModeling/workstation/index.vue @@ -206,6 +206,31 @@ const formsSuccess = async (formType,data) => { getList() } +// 修改 tableform 属性 +Workstation.allSchemas.tableFormColumns.map(item => { + if(item.field == 'rawLocationCode') { + item.form.componentProps.searchCondition = [ + { + key: 'areaType', + value: 'RAW', + },{ + key: 'available', + value: 'TRUE', + } + ] + } + if(item.field == 'fgLocationCode') { + item.form.componentProps.searchCondition = [ + { + key: 'areaType', + value: 'FG', + },{ + key: 'available', + value: 'TRUE', + } + ] + } + }) // 查询页面返回 const searchTableSuccess = (formField, searchField, val, formRef) => { nextTick(() => { diff --git a/src/views/wms/basicDataManage/factoryModeling/workstation/workstation.data.ts b/src/views/wms/basicDataManage/factoryModeling/workstation/workstation.data.ts index 5067e369e..6ba60cf79 100644 --- a/src/views/wms/basicDataManage/factoryModeling/workstation/workstation.data.ts +++ b/src/views/wms/basicDataManage/factoryModeling/workstation/workstation.data.ts @@ -10,6 +10,9 @@ import { Productionline } from '@/views/wms/basicDataManage/factoryModeling/prod import * as WorkshopApi from '@/api/wms/workshop' import { Workshop } from '@/views/wms/basicDataManage/factoryModeling/workshop/workshop.data' + +import * as WorkstationApi from '@/api/wms/workstation' + import { validateYS } from '@/utils/validator' const { t } = useI18n() // 国际化 @@ -118,14 +121,7 @@ export const Workstation = useCrudSchemas(reactive([ searchField: 'code', // 查询弹窗赋值字段 searchTitle: '库位信息', // 查询弹窗标题 searchAllSchemas: Location.allSchemas, // 查询弹窗所需类 - searchPage: LocationApi.getLocationPage, // 查询弹窗所需分页方法 - searchCondition: [{ - key: 'available', - value: 'TRUE', - isMainValue: false - } - // TODO: 陈放修改 ; 数据过滤 查询库区对应成品类型下的所有库位 - ] + searchPage: WorkstationApi.selectAreaTypeToLocation, // 查询弹窗所需分页方法 } } }, @@ -144,23 +140,7 @@ export const Workstation = useCrudSchemas(reactive([ searchField: 'code', // 查询弹窗赋值字段 searchTitle: '库位信息', // 查询弹窗标题 searchAllSchemas: Location.allSchemas, // 查询弹窗所需类 - searchPage: LocationApi.getLocationPage, // 查询弹窗所需分页方法 - searchCondition: [{ - key: 'available', - value: 'TRUE', - action: '==', - isSearch: true, - isMainValue: false - } - // TODO: 陈放修改 ; 数据过滤 查询库区对应成品类型下的所有库位 - // ,{ - // key: 'type', - // value: 'FG', - // action: '==', - // isSearch: true, - // isMainValue: false - // } - ] + searchPage: WorkstationApi.selectAreaTypeToLocation, // 查询弹窗所需分页方法 } } }, From 614939080f0208aa6ba143b9b25ab46d9e1b0a70 Mon Sep 17 00:00:00 2001 From: zhaoxuebing <1291173720@qq.com> Date: Wed, 21 Feb 2024 17:29:49 +0800 Subject: [PATCH 5/8] =?UTF-8?q?=E4=BE=9B=E5=BA=94=E5=95=86=E5=8F=91?= =?UTF-8?q?=E8=B4=A7=E7=94=B3=E8=AF=B7=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../wms/supplierdeliverRecordMain/index.ts | 7 ++++++ .../inspect/inspectRecordMain/index.vue | 22 +++++++++---------- .../supplierdeliverRecordMain/index.vue | 18 ++++++++++++++- .../supplierdeliverRequestMain/index.vue | 10 +++++++-- 4 files changed, 43 insertions(+), 14 deletions(-) diff --git a/src/api/wms/supplierdeliverRecordMain/index.ts b/src/api/wms/supplierdeliverRecordMain/index.ts index c205031cc..e67f3b5a6 100644 --- a/src/api/wms/supplierdeliverRecordMain/index.ts +++ b/src/api/wms/supplierdeliverRecordMain/index.ts @@ -31,6 +31,8 @@ export interface SupplierdeliverRecordMainVO { creator: string serialNumber: string available: string + purchasereceiptRequestFlag: boolean + purchasereceiptRequestNumber: string } // 查询供应商发货记录主列表 @@ -77,4 +79,9 @@ export const exportSupplierdeliverRecordMain = async (params) => { // 下载用户导入模板 export const importTemplate = () => { return request.download({ url: '/wms/supplierdeliver-record-main/get-import-template' }) +} + +// 创建采购申请 +export const createPurchasereceiptRequest = async (number:string) => { + return await request.post({ url: `/wms/supplierdeliver-record-main/createPurchasereceiptRequest?number=`+number }) } \ No newline at end of file diff --git a/src/views/wms/purchasereceiptManage/inspect/inspectRecordMain/index.vue b/src/views/wms/purchasereceiptManage/inspect/inspectRecordMain/index.vue index facd5be89..5f867c3e1 100644 --- a/src/views/wms/purchasereceiptManage/inspect/inspectRecordMain/index.vue +++ b/src/views/wms/purchasereceiptManage/inspect/inspectRecordMain/index.vue @@ -143,18 +143,18 @@ const buttonTableClick = async (val, row) => { } - /** 生成采购上架申请按钮操作 */ - const handlePutawayRequest = async (number:string) => { - try{ - await message.confirm(t('确认生成上架申请吗?')) - tableObject.loading = true - await InspectRecordMainApi.createPutAwayRequest(number) - message.success(t('上架申请生成成功')) - await getList() - }catch{}finally{ - tableObject.loading = false - } +/** 生成采购上架申请按钮操作 */ +const handlePutawayRequest = async (number:string) => { + try{ + await message.confirm(t('确认生成上架申请吗?')) + tableObject.loading = true + await InspectRecordMainApi.createPutAwayRequest(number) + message.success(t('上架申请生成成功')) + await getList() + }catch{}finally{ + tableObject.loading = false } +} /** 详情操作 */ const detailRef = ref() diff --git a/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRecordMain/index.vue b/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRecordMain/index.vue index a1d4b1e7d..081ffc15d 100644 --- a/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRecordMain/index.vue +++ b/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRecordMain/index.vue @@ -127,12 +127,28 @@ const buttonBaseClick = (val, item) => { // 列表-操作按钮 const butttondata = (row) => { return [ - // defaultButtons.mainListGenerateApplicationBtn(null), // 生成采购申请 + defaultButtons.mainListGenerateApplicationBtn({hasPermi:'wms:supplierdeliver-record-main:createPurchasereceiptRequest',hide:!row.purchasereceiptRequestFlag}), // 生成采购申请 ] } // 列表-操作按钮事件 const buttonTableClick = async (val, row) => { + if(val == 'generateApplication'){ + handlerCreatePurchasereceiptRequest(row.number) + } +} + +/** 生成采购收货申请按钮操作 */ +const handlerCreatePurchasereceiptRequest = async (number:string) => { + try{ + await message.confirm(t('确认生成采购申请吗?')) + tableObject.loading = true + await SupplierdeliverRecordMainApi.createPurchasereceiptRequest(number) + message.success(t('采购申请生成成功')) + await getList() + }catch{}finally{ + tableObject.loading = false + } } /** 详情操作 */ diff --git a/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue b/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue index a39d843d3..69a89b80c 100644 --- a/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue +++ b/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue @@ -105,6 +105,7 @@ import * as SupplierdeliverRequestMainApi from '@/api/wms/supplierdeliverRequest import * as SupplierdeliverRequestDetailApi from '@/api/wms/supplierdeliverRequestDetail' import * as defaultButtons from '@/utils/disposition/defaultButtons' import point from '@/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/point.vue' +import * as SupplierdeliverRecordMainApi from '@/api/wms/supplierdeliverRecordMain' // 供应商发货申请 defineOptions({ name: 'SupplierdeliverRequestMain' }) @@ -465,8 +466,13 @@ const genRecords = async (id: number) => { await message.confirm('是否处理所选中数据?') tableObject.loading = true // 发起处理 - await SupplierdeliverRequestMainApi.genRecordsSupplierdeliverRequestMain(id) - message.success(t('处理成功!')) + await SupplierdeliverRequestMainApi.genRecordsSupplierdeliverRequestMain(id).then(res => { + message.success(t('处理成功!')) + if(!res){ + SupplierdeliverRecordMainApi.createPurchasereceiptRequest(res.number) + message.success(t('采购申请生成成功')) + } + }) // 刷新列表 await getList() } catch {}finally{ From 361d1ef664094802852b8b6d89123a6940087964 Mon Sep 17 00:00:00 2001 From: zhaoxuebing <1291173720@qq.com> Date: Thu, 22 Feb 2024 17:14:52 +0800 Subject: [PATCH 6/8] =?UTF-8?q?=E9=87=87=E8=B4=AD=E6=94=B6=E8=B4=A7?= =?UTF-8?q?=E4=BB=BB=E5=8A=A1=E8=AE=B0=E5=BD=95=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/wms/inspectRecordMain/index.ts | 2 +- .../wms/purchasereceiptRecordMain/index.ts | 14 ++++++++ .../purchasereceiptRecordMain/index.vue | 34 +++++++++++++++++-- .../purchasereceiptRecordMain.data.ts | 10 ++++++ .../supplierdeliverRequestMain/index.vue | 9 ++--- 5 files changed, 59 insertions(+), 10 deletions(-) diff --git a/src/api/wms/inspectRecordMain/index.ts b/src/api/wms/inspectRecordMain/index.ts index 2e8f09b9f..3de2e0b1f 100644 --- a/src/api/wms/inspectRecordMain/index.ts +++ b/src/api/wms/inspectRecordMain/index.ts @@ -90,5 +90,5 @@ export const importTemplate = () => { // 创建上架申请 export const createPutAwayRequest = async (number:string) => { - return await request.post({ url: `/wms/inspect-record-main/createPutAwayRequest?number=`+number }) + return await request.post({ url: `/wms/inspect-record-main/createPutAwayRequestPC?number=`+number }) } \ No newline at end of file diff --git a/src/api/wms/purchasereceiptRecordMain/index.ts b/src/api/wms/purchasereceiptRecordMain/index.ts index fb50c380b..9fab97c09 100644 --- a/src/api/wms/purchasereceiptRecordMain/index.ts +++ b/src/api/wms/purchasereceiptRecordMain/index.ts @@ -31,6 +31,10 @@ export interface PurchasereceiptRecordMainVO { fromAreaCodes: string toAreaCodes: string available: string + putawayRequestFlag: boolean + putawayRequestNumber: string + inspectRequestFlag: boolean + inspectRequestNumber: string } // 查询采购收货记录主列表 @@ -77,4 +81,14 @@ export const exportPurchasereceiptRecordMain = async (params) => { // 下载用户导入模板 export const importTemplate = () => { return request.download({ url: '/wms/purchasereceipt-record-main/get-import-template' }) +} + +// 创建上架申请 +export const createPutawayRequest = async (number:string) => { + return await request.post({ url: `/wms/purchasereceipt-record-main/createPutawayRequest?number=`+number }) +} + +// 创建检验申请 +export const createInspectRequest = async (number:string) => { + return await request.post({ url: `/wms/purchasereceipt-record-main/createInspectRequest?number=`+number }) } \ 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 dd7691443..3990e757e 100644 --- a/src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRecordMain/index.vue +++ b/src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRecordMain/index.vue @@ -125,14 +125,44 @@ const buttonBaseClick = (val, item) => { // 列表-操作按钮 const butttondata = (row) => { return [ - defaultButtons.mainInspectRequestBtn({hasPermi:'wms:purchasereceiptRecordMain:inspectRequest'}), // 生成到货检验申请 + defaultButtons.mainInspectRequestBtn({hasPermi:'wms:purchasereceipt-record-main:createInspectRequest',hide:!row.inspectRequestFlag}),// 生成到货检验申请 + defaultButtons.mainPutawayRequestBtn({hasPermi:'wms:purchasereceipt-record-main:createPutawayRequest',hide:!row.putawayRequestFlag}),// 生成采购上架申请 ] } // 列表-操作按钮事件 const buttonTableClick = async (val, row) => { if (val == 'putawayRequest') { // 生成采购上架申请 - handleExport() + handleCreatePutawayRequest(row.number) + }else if(val == 'inspectRequest'){//生成到货检验申请 + handleCreateInspectRequest(row.number) + } +} + + +/** 生成采购上架申请按钮操作 */ +const handleCreatePutawayRequest = async (number:string) => { + try{ + await message.confirm(t('确认生成上架申请吗?')) + tableObject.loading = true + await PurchasereceiptRecordMainApi.createPutawayRequest(number) + message.success(t('上架申请生成成功')) + await getList() + }catch{}finally{ + tableObject.loading = false + } +} + +/** 生成到货检验申请按钮操作 */ +const handleCreateInspectRequest = async (number:string) => { + try{ + await message.confirm(t('确认生成到货检验申请吗?')) + tableObject.loading = true + await PurchasereceiptRecordMainApi.createPutawayRequest(number) + message.success(t('到货检验申请生成成功')) + await getList() + }catch{}finally{ + tableObject.loading = false } } diff --git a/src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRecordMain/purchasereceiptRecordMain.data.ts b/src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRecordMain/purchasereceiptRecordMain.data.ts index a3d89d47f..397a6a4ed 100644 --- a/src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRecordMain/purchasereceiptRecordMain.data.ts +++ b/src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptRecordMain/purchasereceiptRecordMain.data.ts @@ -333,6 +333,16 @@ export const PurchasereceiptRecordMain = useCrudSchemas(reactive([ activeValue: 'TRUE' } } + }, + { + label: '操作', + field: 'action', + isDetail: false, + isForm: false, + table: { + width: 300, + fixed: 'right' + }, } ])) diff --git a/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue b/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue index 69a89b80c..d0c354779 100644 --- a/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue +++ b/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue @@ -466,13 +466,8 @@ const genRecords = async (id: number) => { await message.confirm('是否处理所选中数据?') tableObject.loading = true // 发起处理 - await SupplierdeliverRequestMainApi.genRecordsSupplierdeliverRequestMain(id).then(res => { - message.success(t('处理成功!')) - if(!res){ - SupplierdeliverRecordMainApi.createPurchasereceiptRequest(res.number) - message.success(t('采购申请生成成功')) - } - }) + await SupplierdeliverRequestMainApi.genRecordsSupplierdeliverRequestMain(id) + message.success(t('处理成功!')) // 刷新列表 await getList() } catch {}finally{ From 457196957fb86e8ee660c141eba7fe0ad7164dc7 Mon Sep 17 00:00:00 2001 From: chenfang Date: Fri, 23 Feb 2024 08:40:12 +0800 Subject: [PATCH 7/8] =?UTF-8?q?=E7=AD=9B=E9=80=89=E5=AF=BC=E5=87=BAapi?= =?UTF-8?q?=E8=A1=A5=E5=85=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/wms/balance/index.ts | 7 ++++++- src/api/wms/countJobMain/index.ts | 8 +++++++- src/api/wms/countPlanMain/index.ts | 8 +++++++- src/api/wms/countRecordMain/index.ts | 8 +++++++- src/api/wms/countRequestMain/index.ts | 8 +++++++- src/api/wms/countadjustRecordMain/index.ts | 8 +++++++- src/api/wms/countadjustRequestMain/index.ts | 8 +++++++- src/api/wms/demandforecastingMain/index.ts | 8 +++++++- 8 files changed, 55 insertions(+), 8 deletions(-) diff --git a/src/api/wms/balance/index.ts b/src/api/wms/balance/index.ts index 012f7c534..58dc31c42 100644 --- a/src/api/wms/balance/index.ts +++ b/src/api/wms/balance/index.ts @@ -104,7 +104,12 @@ export const deleteBalance = async (id: number) => { // 导出库存余额 Excel export const exportBalance = async (params) => { - return await request.download({ url: `/wms/balance/export-excel`, params }) + if (params.isSearch) { + const data = {...params} + return await request.downloadPost({ url: `/wms/balance/export-excel-senior`, data }) + } else { + return await request.download({ url: `/wms/balance/export-excel`, params }) + } } // 下载用户导入模板 diff --git a/src/api/wms/countJobMain/index.ts b/src/api/wms/countJobMain/index.ts index e2de4e5f8..3d9c2a5e8 100644 --- a/src/api/wms/countJobMain/index.ts +++ b/src/api/wms/countJobMain/index.ts @@ -73,7 +73,13 @@ export const deleteCountJobMain = async (id: number) => { // 导出盘点任务主 Excel export const exportCountJobMain = async (params) => { - return await request.download({ url: `/wms/count-job-main/export-excel`, params }) + if (params.isSearch) { + delete params.isSearch + const data = {...params} + return request.post({ url: '/wms/count-job-main/export-excel-senior', data }) + } else { + return await request.download({ url: `/wms/count-job-main/export-excel`, params }) + } } // 下载用户导入模板 diff --git a/src/api/wms/countPlanMain/index.ts b/src/api/wms/countPlanMain/index.ts index b62d13077..0e3bc85fb 100644 --- a/src/api/wms/countPlanMain/index.ts +++ b/src/api/wms/countPlanMain/index.ts @@ -60,7 +60,13 @@ export const deleteCountPlanMain = async (id: number) => { // 导出盘点计划主 Excel export const exportCountPlanMain = async (params) => { - return await request.download({ url: `/wms/count-plan-main/export-excel`, params }) + if (params.isSearch) { + delete params.isSearch + const data = {...params} + return request.post({ url: '/wms/count-plan-main/export-excel-senior', data }) + } else { + return await request.download({ url: `/wms/count-plan-main/export-excel`, params }) + } } // 下载用户导入模板 diff --git a/src/api/wms/countRecordMain/index.ts b/src/api/wms/countRecordMain/index.ts index e4b43a074..35d2ef3db 100644 --- a/src/api/wms/countRecordMain/index.ts +++ b/src/api/wms/countRecordMain/index.ts @@ -56,7 +56,13 @@ export const deleteCountRecordMain = async (id: number) => { // 导出盘点记录主 Excel export const exportCountRecordMain = async (params) => { - return await request.download({ url: `/wms/count-record-main/export-excel`, params }) + if (params.isSearch) { + delete params.isSearch + const data = {...params} + return request.post({ url: '/wms/count-record-main/export-excel-senior', data }) + } else { + return await request.download({ url: `/wms/count-record-main/export-excel`, params }) + } } // 下载用户导入模板 diff --git a/src/api/wms/countRequestMain/index.ts b/src/api/wms/countRequestMain/index.ts index cf6c52242..b353bf0f9 100644 --- a/src/api/wms/countRequestMain/index.ts +++ b/src/api/wms/countRequestMain/index.ts @@ -55,7 +55,13 @@ export const deleteCountRequestMain = async (id: number) => { // 导出盘点申请主 Excel export const exportCountRequestMain = async (params) => { - return await request.download({ url: `/wms/count-request-main/export-excel`, params }) + if (params.isSearch) { + delete params.isSearch + const data = {...params} + return request.post({ url: '/wms/count-request-main/export-excel-senior', data }) + } else { + return await request.download({ url: `/wms/count-request-main/export-excel`, params }) + } } // 下载用户导入模板 diff --git a/src/api/wms/countadjustRecordMain/index.ts b/src/api/wms/countadjustRecordMain/index.ts index c07af7fe8..02dc4ed60 100644 --- a/src/api/wms/countadjustRecordMain/index.ts +++ b/src/api/wms/countadjustRecordMain/index.ts @@ -54,7 +54,13 @@ export const deleteCountadjustRecordMain = async (id: number) => { // 导出盘点调整记录主 Excel export const exportCountadjustRecordMain = async (params) => { - return await request.download({ url: `/wms/countadjust-record-main/export-excel`, params }) + if (params.isSearch) { + delete params.isSearch + const data = {...params} + return request.post({ url: '/wms/countadjust-record-main/export-excel-senior', data }) + } else { + return await request.download({ url: `/wms/countadjust-record-main/export-excel`, params }) + } } // 下载用户导入模板 diff --git a/src/api/wms/countadjustRequestMain/index.ts b/src/api/wms/countadjustRequestMain/index.ts index 57ae5ee0e..4cc19ee4d 100644 --- a/src/api/wms/countadjustRequestMain/index.ts +++ b/src/api/wms/countadjustRequestMain/index.ts @@ -54,7 +54,13 @@ export const deleteCountadjustRequestMain = async (id: number) => { // 导出盘点调整申请主 Excel export const exportCountadjustRequestMain = async (params) => { - return await request.download({ url: `/wms/countadjust-request-main/export-excel`, params }) + if (params.isSearch) { + delete params.isSearch + const data = {...params} + return request.post({ url: '/wms/countadjust-request-main/export-excel-senior', data }) + } else { + return await request.download({ url: `/wms/countadjust-request-main/export-excel`, params }) + } } // 下载用户导入模板 diff --git a/src/api/wms/demandforecastingMain/index.ts b/src/api/wms/demandforecastingMain/index.ts index 16cda3e7a..38b2e1f9e 100644 --- a/src/api/wms/demandforecastingMain/index.ts +++ b/src/api/wms/demandforecastingMain/index.ts @@ -50,7 +50,13 @@ export const deleteDemandforecastingMain = async (id: number) => { // 导出要货预测主 Excel export const exportDemandforecastingMain = async (params) => { - return await request.download({ url: `/wms/demandforecasting-main/export-excel`, params }) + if (params.isSearch) { + delete params.isSearch + const data = {...params} + return request.post({ url: '/wms/demandforecasting-main/export-excel-senior', data }) + } else { + return await request.download({ url: `/wms/demandforecasting-main/export-excel`, params }) + } } // 下载用户导入模板 From 7fd5868d528390cf3084e2193d74e1724ee2cafe Mon Sep 17 00:00:00 2001 From: zhaoxuebing <1291173720@qq.com> Date: Fri, 23 Feb 2024 09:51:02 +0800 Subject: [PATCH 8/8] =?UTF-8?q?=E4=BB=8E=E4=B8=BB=E5=88=86=E6=94=AF?= =?UTF-8?q?=E6=8B=B7=E8=B4=9D=E8=BF=87=E6=9D=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/report/goview/index.vue | 10 ++++++++++ src/views/report/jmreport/index.vue | 13 +++++++++++++ 2 files changed, 23 insertions(+) create mode 100644 src/views/report/goview/index.vue create mode 100644 src/views/report/jmreport/index.vue diff --git a/src/views/report/goview/index.vue b/src/views/report/goview/index.vue new file mode 100644 index 000000000..1bac28692 --- /dev/null +++ b/src/views/report/goview/index.vue @@ -0,0 +1,10 @@ +