From 9661cdbb2b924d4462836903a53017c2d422e809 Mon Sep 17 00:00:00 2001 From: odjbin <1042039504@qq.com> Date: Mon, 20 May 2024 00:29:31 +0800 Subject: [PATCH] =?UTF-8?q?fix=20:=20=E4=BF=AE=E5=A4=8D=E9=A1=B5=E9=9D=A2?= =?UTF-8?q?=E7=BB=86=E8=8A=82=E5=8A=9F=E8=83=BD=E5=8F=8A=E9=99=84=E4=BB=B6?= =?UTF-8?q?=E4=B8=8A=E4=BC=A0=E7=BB=84=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/AttachmentUpload.vue | 35 +++- src/components/steps/index.vue | 23 +-- src/views/project-demand/summary/add.vue | 169 ++++++++++++------ src/views/project-demand/summary/api/index.js | 12 +- src/views/project-demand/summary/detail.vue | 41 ++--- src/views/project-demand/summary/index.vue | 36 ++-- .../project-management/filing/conclusion.vue | 31 ++-- .../implementation/check.vue | 31 ++-- .../project-management/initiation/apply.vue | 46 +++-- .../project-management/initiation/index.vue | 1 + 10 files changed, 268 insertions(+), 157 deletions(-) diff --git a/src/components/AttachmentUpload.vue b/src/components/AttachmentUpload.vue index 77c66a6..2c707d1 100644 --- a/src/components/AttachmentUpload.vue +++ b/src/components/AttachmentUpload.vue @@ -3,15 +3,20 @@ - + + - + + :data="allFileList" :isSettingCol="false" :pagination="false"> @@ -75,6 +80,8 @@ const rules = reactive({ attachment: [{required: true, message: '请上传附件', trigger: ['blur','change']}], }) const applyForm=ref() +const singleFile=ref() +const allFileList=ref([]) const props = defineProps({ showFileList: { type: Boolean, @@ -85,16 +92,32 @@ const props = defineProps({ }, showTable: { type: Boolean, default: true + }, preview: { + type: Boolean, + default: false },otherFileList: { type: Array, default: [] + },formData: { + type: Array, + default: [] } }) watch(() => props.showTable, (newVal) => { props.showTable = newVal }, {deep: true}) watch(() => props.otherFileList, (newVal) => { - props.otherFileList = newVal + newVal.forEach(item=>{ + allFileList.value.push(item) + }) +}, {deep: true}) +watch(() => props.formData.fileList, (newVal) => { + newVal.forEach(item=>{ + allFileList.value.push(item) + }) +}, {deep: true}) +watch(() => props.formData.singleFile, (newVal) => { + singleFile.value = newVal }, {deep: true}) const getAttachment = (val) => { emit('getAttachment', val) @@ -140,7 +163,9 @@ defineExpose({ }, clearValidate(){ return applyForm.value.clearValidate() - } + }, + allFileList, + singleFile }) diff --git a/src/components/steps/index.vue b/src/components/steps/index.vue index 246a254..df22e3b 100644 --- a/src/components/steps/index.vue +++ b/src/components/steps/index.vue @@ -4,13 +4,13 @@
-
@@ -91,7 +91,7 @@ const schema = computed(()=>{ colProps: { span: 12 } - // component: + // component: }, { label: '征集类型', @@ -99,7 +99,7 @@ const schema = computed(()=>{ colProps: { span: 12 } - // component: + // component: }, { label: '截止时间', @@ -107,7 +107,7 @@ const schema = computed(()=>{ colProps: { span: 12 } - // component: + // component: }, { label: '需求名称', @@ -115,7 +115,7 @@ const schema = computed(()=>{ colProps: { span: 12 } - // component: + // component: }, ] }) @@ -236,6 +236,7 @@ getBaseInfo() watchEffect(() => { console.log(props.active, 'props.active'); localActive.value = props.active + getBaseInfo() }) @@ -251,4 +252,4 @@ watchEffect(() => { .step-error { cursor: not-allowed; } - \ No newline at end of file + diff --git a/src/views/project-demand/summary/add.vue b/src/views/project-demand/summary/add.vue index 145cfda..b6c87a7 100644 --- a/src/views/project-demand/summary/add.vue +++ b/src/views/project-demand/summary/add.vue @@ -202,7 +202,7 @@
- + @@ -221,24 +221,27 @@ + @getOtherFile="getOtherFile" :showFileList="true" :formData="formData" :preview="router.currentRoute.value.name === 'Summary/edit'"/>
存为草稿 发布 + 重新发布
diff --git a/src/views/project-demand/summary/api/index.js b/src/views/project-demand/summary/api/index.js index 98ea624..26d0dba 100644 --- a/src/views/project-demand/summary/api/index.js +++ b/src/views/project-demand/summary/api/index.js @@ -24,9 +24,17 @@ export const getProcessInfo = () => { method: "post" }); }; -export const getDetail = (requirementId) => { +export const getDetail = (projectId) => { return request({ - url: `/workflow/mosr/requirement/collect/info/${requirementId}`, + url: `/workflow/mosr/requirement/collect/info/${projectId}`, method: "get" }); }; + +export const resubmitReported = (data) => { + return request({ + url: '/workflow/mosr/requirement/collect/resubmit', + method: "post", + data: data + }); +}; diff --git a/src/views/project-demand/summary/detail.vue b/src/views/project-demand/summary/detail.vue index 7ffc6a0..a8f7c9a 100644 --- a/src/views/project-demand/summary/detail.vue +++ b/src/views/project-demand/summary/detail.vue @@ -1,47 +1,32 @@