diff --git a/src/locales/en-US.ts b/src/locales/en-US.ts index fc6ef45c2..e28458942 100644 --- a/src/locales/en-US.ts +++ b/src/locales/en-US.ts @@ -760,6 +760,7 @@ export default { 变更记录:'Change Record', 添加明细:'Add Detail', 上传质量报告:'Upload quality report', + 上传履历表:'Upload your resume', 上传质检报告:'Upload the quality inspection report', 个:'piece', 张:'sheet', diff --git a/src/locales/zh-CN.ts b/src/locales/zh-CN.ts index c414dad7f..d49e9eef2 100644 --- a/src/locales/zh-CN.ts +++ b/src/locales/zh-CN.ts @@ -760,6 +760,7 @@ export default { 变更记录:'变更记录', 添加明细:'添加明细', 上传质量报告:'上传质量报告', + 上传履历表:'上传履历表', 上传质检报告:'上传质检报告', 个:'个', 张:'张', diff --git a/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverInspectionDetail/supplierdeliverInspectionDetail.data.ts b/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverInspectionDetail/supplierdeliverInspectionDetail.data.ts index de8ce0f18..ab2006ea6 100644 --- a/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverInspectionDetail/supplierdeliverInspectionDetail.data.ts +++ b/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverInspectionDetail/supplierdeliverInspectionDetail.data.ts @@ -159,3 +159,32 @@ export const SupplierdeliverInspectionDetailRules = reactive({ { required: true, message: '请输入发货数量', trigger: 'blur' } ], }) + + +export const CurriculumVitae = useCrudSchemas(reactive([ + { + label: '上传履历表', + field: 'uploadFile', + sort: 'custom', + isTable:false, + isTableForm:false, + form: { + component: 'UploadFile', + componentProps: { + upData:{ + tableId: '', + tableName: 'SupplierdeliverInspectionDetail', + }, + fileType:['pdf'], + fileSize:100, + limit:20000 + } + }, + } +])) +//表单校验 +export const CurriculumVitaeRules = reactive({ + uploadFile: [ + { required: true, message: '请上传文件', trigger: 'blur' } + ] +}) diff --git a/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue b/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue index 0abaf2495..a6a42a6e1 100644 --- a/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue +++ b/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue @@ -152,6 +152,14 @@ @footButtonClick="footButtonClick" @formSelectChange="formSelectChangeLabel" /> + + { hide: isShowMainButton(row, ['1', '2', '3']), hasPermi: 'wms:supplierdeliver-request-main:uploadCheck' }), // 上传质量报告 + { + label: t('ts.上传履历表'), + name: 'mainPlanCurriculumVitae', + hide: row.status!=5, + type: 'primary', + icon: '', + color: '', + hasPermi: '', + link: true // 文本展现按钮 + }, // 上传履历表 defaultButtons.mainListPlanSubBtn({ hide: isShowMainButton(row, ['1']), hasPermi: 'wms:supplierdeliver-request-main:sub' @@ -606,6 +626,9 @@ const buttonTableClick = async (val, row) => { } else if (val == 'mainPlanUploadQualityReport') { // 上传质量报告 handleUploadQualityReport(row) + }else if (val == 'mainPlanCurriculumVitae') { + // 上传履历表 + handleUploadCurriculumVitae(row) } else if (val == 'mainPlanSub') { // 提交审批 handleSub(row.masterId) @@ -948,6 +971,28 @@ const handleUploadQualityReport = async (row) => { //uploadQualityReportTableData.value = [tableFormKeys] } +const curriculumVitaeRef = ref() +const submitCurriculumVitae = async (formType, data) => { + console.log('上传履历表',data) + +} +/** 上传质量报告 */ +const handleUploadCurriculumVitae = async (row) => { + const uploadFile = SupplierdeliverInspectionDetail.allSchemas.formSchema.find( + (item) => item.field == 'uploadFile' + ) + if (uploadFile) { + uploadFile['componentProps']['upData']['tableId'] = row.masterId + } + curriculumVitaeRef.value.open( + 'create', + null, + { masterId: row.masterId }, + t('ts.上传履历表'), + t('ts.上传履历表') + ) +} + const submitFormUploadQualityReport = async (formType, data) => { delete data.number data.subList = uploadQualityReportTableData.value // 拼接子表数据参数