From 69353772268751597596949fdebe4e188369e07a Mon Sep 17 00:00:00 2001 From: bjang03 Date: Sun, 7 Apr 2024 13:03:57 +0800 Subject: [PATCH 1/2] =?UTF-8?q?1=E3=80=81=E8=AE=A2=E5=8D=95=E6=9C=88?= =?UTF-8?q?=E8=AE=A1=E5=88=92=EF=BC=8C=E8=AE=A1=E5=88=92=E7=B1=BB=E5=9E=8B?= =?UTF-8?q?=E4=BD=BF=E7=94=A8=E5=AD=97=E5=85=B8=E5=B1=95=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/utils/dict.ts | 2 +- src/views/mes/ordermonthplan/mesOrderMonthMain.data.ts | 7 ++++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/utils/dict.ts b/src/utils/dict.ts index c90f1b236..0d403d742 100644 --- a/src/utils/dict.ts +++ b/src/utils/dict.ts @@ -285,7 +285,7 @@ export enum DICT_TYPE { MES_WORKBILL_MODEL='mes_workbill_model',// 工单模式 单工单(根据产品数量生成多个工单)、批量工单(一个产品一个工单) MES_TASK_MODE='mes_task_mode', //生产模式 派工方式、领工方式 MES_PLANDO_STATUS='mes_plando_status', //计划执行状 - + PLAN_TYPE_MES='plan_type_mes', //========== QMS ========== SAMPLING_TYPE = "sampling_type", // 取样类型 diff --git a/src/views/mes/ordermonthplan/mesOrderMonthMain.data.ts b/src/views/mes/ordermonthplan/mesOrderMonthMain.data.ts index 66be46d39..62cdd8d45 100644 --- a/src/views/mes/ordermonthplan/mesOrderMonthMain.data.ts +++ b/src/views/mes/ordermonthplan/mesOrderMonthMain.data.ts @@ -38,7 +38,12 @@ export const MesOrderMonthMain = useCrudSchemas(reactive([ label: '计划类型', field: 'planType', sort: 'custom', - isSearch: true + dictType: DICT_TYPE.PLAN_TYPE_MES, + dictClass: 'string', // 默认都是字符串类型其他暂不考虑 + isSearch: true, + form: { + component: 'SelectV2' + } }, { label: '备注', From 080a8023c4cee319c54d4054e8f7ee3d44dea7cf Mon Sep 17 00:00:00 2001 From: zhang_li <2235006734@qqq.com> Date: Sun, 7 Apr 2024 13:21:59 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E6=A3=80=E9=AA=8C=E4=BB=BB=E5=8A=A1?= =?UTF-8?q?=EF=BC=8C=E6=A8=A1=E6=9D=BF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../inspectionJobDetail/index.ts | 20 +- .../inspectionJob/inspectionJobMain/index.ts | 16 +- .../inspectionPlan/addForm.vue | 3 +- .../basicDataManage/inspectionPlan/index.vue | 1 - .../inspectionTemplate/addForm.vue | 16 +- .../qms/inspection/inspectionJob/addForm.vue | 1010 +++++++++++++++++ .../qms/inspection/inspectionJob/index.vue | 39 +- .../inspectionJob/inspectionJobMain.data.ts | 12 +- 8 files changed, 1077 insertions(+), 40 deletions(-) create mode 100644 src/views/qms/inspection/inspectionJob/addForm.vue diff --git a/src/api/qms/inspectionJob/inspectionJobDetail/index.ts b/src/api/qms/inspectionJob/inspectionJobDetail/index.ts index 742627e2b..12679e310 100644 --- a/src/api/qms/inspectionJob/inspectionJobDetail/index.ts +++ b/src/api/qms/inspectionJob/inspectionJobDetail/index.ts @@ -28,38 +28,42 @@ export const getInspectionJobDetailPage = async (params) => { if (params.isSearch) { delete params.isSearch const data = {...params} - return await request.post({ url: '/inspection/inspection-job-detail/senior', data }) + return await request.post({ url: '/qms/inspection-job-detail/senior', data }) } else { - return await request.get({ url: `/inspection/inspection-job-detail/page`, params }) + return await request.get({ url: `/qms/inspection-job-detail/page`, params }) } } +//查询检验申请列表 +export const getInspectionJobDetailList = async (id: number) => { + return await request.get({ url: `/qms/inspection-job-detail/list?masterId=` + id }) +} // 查询检验申请详情 export const getInspectionJobDetail = async (id: number) => { - return await request.get({ url: `/inspection/inspection-job-detail/get?id=` + id }) + return await request.get({ url: `/qms/inspection-job-detail/get?id=` + id }) } // 新增检验申请 export const createInspectionJobDetail = async (data: InspectionJobDetailVO) => { - return await request.post({ url: `/inspection/inspection-job-detail/create`, data }) + return await request.post({ url: `/qms/inspection-job-detail/create`, data }) } // 修改检验申请 export const updateInspectionJobDetail = async (data: InspectionJobDetailVO) => { - return await request.put({ url: `/inspection/inspection-job-detail/update`, data }) + return await request.put({ url: `/qms/inspection-job-detail/update`, data }) } // 删除检验申请 export const deleteInspectionJobDetail = async (id: number) => { - return await request.delete({ url: `/inspection/inspection-job-detail/delete?id=` + id }) + return await request.delete({ url: `/qms/inspection-job-detail/delete?id=` + id }) } // 导出检验申请 Excel export const exportInspectionJobDetail = async (params) => { - return await request.download({ url: `/inspection/inspection-job-detail/export-excel`, params }) + return await request.download({ url: `/qms/inspection-job-detail/export-excel`, params }) } // 下载用户导入模板 export const importTemplate = () => { - return request.download({ url: '/inspection/inspection-job-detail/get-import-template' }) + return request.download({ url: '/qms/inspection-job-detail/get-import-template' }) } diff --git a/src/api/qms/inspectionJob/inspectionJobMain/index.ts b/src/api/qms/inspectionJob/inspectionJobMain/index.ts index 7bb8b4411..96170650a 100644 --- a/src/api/qms/inspectionJob/inspectionJobMain/index.ts +++ b/src/api/qms/inspectionJob/inspectionJobMain/index.ts @@ -28,38 +28,38 @@ export const getInspectionJobMainPage = async (params) => { if (params.isSearch) { delete params.isSearch const data = {...params} - return await request.post({ url: '/inspection/inspection-job-main/senior', data }) + return await request.post({ url: '/qms/inspection-job-main/senior', data }) } else { - return await request.get({ url: `/inspection/inspection-job-main/page`, params }) + return await request.get({ url: `/qms/inspection-job-main/page`, params }) } } // 查询检验申请详情 export const getInspectionJobMain = async (id: number) => { - return await request.get({ url: `/inspection/inspection-job-main/get?id=` + id }) + return await request.get({ url: `/qms/inspection-job-main/get?id=` + id }) } // 新增检验申请 export const createInspectionJobMain = async (data: InspectionJobMainVO) => { - return await request.post({ url: `/inspection/inspection-job-main/create`, data }) + return await request.post({ url: `/qms/inspection-job-main/create`, data }) } // 修改检验申请 export const updateInspectionJobMain = async (data: InspectionJobMainVO) => { - return await request.put({ url: `/inspection/inspection-job-main/update`, data }) + return await request.put({ url: `/qms/inspection-job-main/update`, data }) } // 删除检验申请 export const deleteInspectionJobMain = async (id: number) => { - return await request.delete({ url: `/inspection/inspection-job-main/delete?id=` + id }) + return await request.delete({ url: `/qms/inspection-job-main/delete?id=` + id }) } // 导出检验申请 Excel export const exportInspectionJobMain = async (params) => { - return await request.download({ url: `/inspection/inspection-job-main/export-excel`, params }) + return await request.download({ url: `/qms/inspection-job-main/export-excel`, params }) } // 下载用户导入模板 export const importTemplate = () => { - return request.download({ url: '/inspection/inspection-job-main/get-import-template' }) + return request.download({ url: '/qms/inspection-job-main/get-import-template' }) } diff --git a/src/views/qms/basicDataManage/inspectionPlan/addForm.vue b/src/views/qms/basicDataManage/inspectionPlan/addForm.vue index 591a4a6cb..f427dbd65 100644 --- a/src/views/qms/basicDataManage/inspectionPlan/addForm.vue +++ b/src/views/qms/basicDataManage/inspectionPlan/addForm.vue @@ -7,7 +7,7 @@ :close-on-click-modal="false" :vLoading="formLoading" > -
+
@@ -879,6 +879,7 @@ const submitForm = async () => { try { const validateForm1 = await validateForm(formProcessRef.value) console.log(validateForm1) + console.log(data.value) await formMainRef.value.validate() if (!data.value.process || data.value.process.length == 0) { message.error(`请添加工序`) diff --git a/src/views/qms/basicDataManage/inspectionPlan/index.vue b/src/views/qms/basicDataManage/inspectionPlan/index.vue index a77b24eb8..787063cb2 100644 --- a/src/views/qms/basicDataManage/inspectionPlan/index.vue +++ b/src/views/qms/basicDataManage/inspectionPlan/index.vue @@ -60,7 +60,6 @@ import TableHead from '@/components/TableHead/src/TableHead.vue' import Detail from '@/components/Detail/src/Detail.vue' import AddForm from './addForm.vue' import * as InspectionPlanApi from '@/api/qms/inspectionPlan' -import { json } from 'stream/consumers' defineOptions({ name: 'AgvLocationrelation' }) diff --git a/src/views/qms/basicDataManage/inspectionTemplate/addForm.vue b/src/views/qms/basicDataManage/inspectionTemplate/addForm.vue index 28d00ba06..2d701589d 100644 --- a/src/views/qms/basicDataManage/inspectionTemplate/addForm.vue +++ b/src/views/qms/basicDataManage/inspectionTemplate/addForm.vue @@ -6,7 +6,7 @@ :close-on-click-modal="false" :vLoading="formLoading" > -
+
@@ -571,6 +571,9 @@ const open = async (type: string, row?: any, masterParmas?: any, titleName?: any version: '', process: [] } + rules.value['inspectionCharacteristicsBaseVO.quantifyCapping'][0].required = false + rules.value['inspectionCharacteristicsBaseVO.quantifyLowlimit'][0].required = false + rules.value['inspectionCharacteristicsBaseVO.quantifyTarget'][0].required = false } tabIndex = data.value.process.length + 1 @@ -625,9 +628,9 @@ const buttonBaseClick1 = (val) => { isDestructionInspection: '', resultEntryMethod: '', featureType: '', - quantifyIsCapping: '', - quantifyIsLowlimit: '', - quantifyIsTarget: '', + quantifyIsCapping: false, + quantifyIsLowlimit: false, + quantifyIsTarget: false, quantifyTarget: '', quantifyCapping: '', quantifyLowlimit: '', @@ -636,8 +639,9 @@ const buttonBaseClick1 = (val) => { quantifyQuantifyCode: '' } }) - console.log(data.value.process) - + rules.value['inspectionCharacteristicsBaseVO.quantifyCapping'][0].required = false + rules.value['inspectionCharacteristicsBaseVO.quantifyLowlimit'][0].required = false + rules.value['inspectionCharacteristicsBaseVO.quantifyTarget'][0].required = false editableTabsValue.value = newTabName dialogVisibleName.value = false } else { diff --git a/src/views/qms/inspection/inspectionJob/addForm.vue b/src/views/qms/inspection/inspectionJob/addForm.vue new file mode 100644 index 000000000..3f8177d67 --- /dev/null +++ b/src/views/qms/inspection/inspectionJob/addForm.vue @@ -0,0 +1,1010 @@ + + + + + diff --git a/src/views/qms/inspection/inspectionJob/index.vue b/src/views/qms/inspection/inspectionJob/index.vue index 48b31afaa..6b393c63d 100644 --- a/src/views/qms/inspection/inspectionJob/index.vue +++ b/src/views/qms/inspection/inspectionJob/index.vue @@ -27,13 +27,22 @@ - - + @searchTableSuccess="searchTableSuccess" @submitForm="submitForm" /> --> + import download from '@/utils/download' import { InspectionJobMain, InspectionJobMainRules, InspectionJobDetail, InspectionJobDetailRules } from './inspectionJobMain.data' + import { InspectionTemplateMain,InspectionTemplateProcess,InspectionTemplateFeatures,InspectionTemplateRules } from '../../basicDataManage/inspectionTemplate/inspectionTemplate.data' + import * as InspectionJobMainApi from '@/api/qms/inspectionJob/inspectionJobMain' import * as InspectionJobDetailApi from '@/api/qms/inspectionJob/inspectionJobDetail' import * as defaultButtons from '@/utils/disposition/defaultButtons' import TableHead from '@/components/TableHead/src/TableHead.vue' import ImportForm from '@/components/ImportForm/src/ImportForm.vue' + import AddForm from './addForm.vue' + import * as InspectionPlanApi from '@/api/qms/inspectionPlan' // 采购订单 defineOptions({ name: 'InspectionJobMain' }) @@ -160,18 +173,19 @@ // 列表-操作按钮 const butttondata = (row) => { return [ - // defaultButtons.mainListOrderCOMPLETEBtn({ hide: isShowMainButton(row, ['INCOMPLETE']) }), // 完成 - // defaultButtons.mainListEditBtn(null), // 编辑 - // defaultButtons.mainListDeleteBtn(null), // 删除 + // defaultButtons.mainListJobAccBtn({hide:isShowMainButton(row,['1'])}), // 承接 + defaultButtons.mainListJobCloBtn({hide:isShowMainButton(row,['1']),hasPermi:'wms:purchasereceipt-job-main:close'}), // 关闭 + // defaultButtons.mainListJobAbaBtn({hide:isShowMainButton(row,['2'])}), // 放弃 + defaultButtons.mainListJobExeBtn({hide:isShowMainButton(row,['2'])}), // 执行 ] } // 列表-操作按钮事件 const buttonTableClick = async (val, row) => { - if (val == 'edit') { // 编辑 - openForm('update', row) + if (val == 'mainJobExe') { // 执行 + execute('update', row) } - else if (val == 'delete') { // 删除 + else if (val == 'mainJobClo') { // 关闭 handleDelete(row.id) } } @@ -188,7 +202,12 @@ const openDetail = (row : any, titleName : any, titleValue : any) => { detailRef.value.openDetail(row, titleName, titleValue, 'basicInspectionJobMain') } - + //执行 + + const basicFormRef = ref() + const execute = async (type : string, row ?: number) => { + basicFormRef.value.open(type, row) + } /** 删除按钮操作 */ const handleDelete = async (id : number) => { try { diff --git a/src/views/qms/inspection/inspectionJob/inspectionJobMain.data.ts b/src/views/qms/inspection/inspectionJob/inspectionJobMain.data.ts index 42da7a50d..91d5ab456 100644 --- a/src/views/qms/inspection/inspectionJob/inspectionJobMain.data.ts +++ b/src/views/qms/inspection/inspectionJob/inspectionJobMain.data.ts @@ -76,12 +76,12 @@ export const InspectionJobMain = useCrudSchemas(reactive([ sort: 'custom', isSearch: false, }, - { - label: '检验方案Json', - field: 'inspectionSchemeJson', - sort: 'custom', - isSearch: false, - }, + // { + // label: '检验方案Json', + // field: 'inspectionSchemeJson', + // sort: 'custom', + // isSearch: false, + // }, { label: '检验批次', field: 'inspectionBatch',