From e54db551a68c08e6d4076554b5fd15613f5a8a7a Mon Sep 17 00:00:00 2001 From: dj <1042039504@qq.com> Date: Wed, 2 Apr 2025 23:01:17 +0800 Subject: [PATCH 1/8] =?UTF-8?q?feat(project-demand):=20=E6=B7=BB=E5=8A=A0?= =?UTF-8?q?=E9=9C=80=E6=B1=82=E5=BE=81=E9=9B=86=E5=8F=98=E6=9B=B4=E9=80=BB?= =?UTF-8?q?=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../DetailComponent/ProjectApply.vue | 70 ++++++++++++++++--- src/views/project-demand/summary/add.vue | 16 ++++- 2 files changed, 75 insertions(+), 11 deletions(-) diff --git a/src/components/DetailComponent/ProjectApply.vue b/src/components/DetailComponent/ProjectApply.vue index 12e2991..a1ef965 100644 --- a/src/components/DetailComponent/ProjectApply.vue +++ b/src/components/DetailComponent/ProjectApply.vue @@ -514,6 +514,65 @@ const getFileParam = (item) => { } } const handleSubmit = async (instance) => { + if(props.step==50){ + let files = [] + if (props.mode === 'resubmit') { + attachment.value.allFileList.forEach(item => { + files.push(getFileParam(item)) + }) + } else { + otherFileList.value.forEach(item => { + files.push(getFileParam(item)) + }) + } + // console.info("🚀 ~method:handleSubmit -----", files,attachment.value.isHaveOneFile) + if (!attachment.value.isHaveOneFile) { + attachment.value.validate() + ElNotification({ + title: '提示', + message: '请上传附件', + type: 'error' + }) + return; + } else { + attachment.value.clearValidate() + } + let projectPersonIds = [] + for (const item of projectPersonUserList.value) { + projectPersonIds.push(parseInt(item.id)) + } + let params = { + deploymentId: deploymentId.value, + requirementId: route.query.id, + fileList: files, + // singleFile: attachment.value.singleFile, + projectId: projectId.value, + actualEconomicEstimate: parseFloat(localFormData.value.actualEconomicEstimate), + specialFundAmount: parseFloat(localFormData.value.specialFundAmount), + preProcess: JSON.stringify(localFormData.value.preProcess) + } + if (sessionParams.value.preProcess && !localFormData.value.preProcess) { + params.preProcess = JSON.stringify(sessionParams.value.preProcess) + } + console.log('params',params) + let res + if (props.mode === 'resubmit') { + res = await resubmitConclusion(params) + } else { + res = await projectConclusion(params) + } + ElNotification({ + title: '提示', + message: res.msg, + type: res.code === 1000 ? 'success' : 'error' + }) + if (res.code === 1000) { + tagsViewStore.delVisitedViews(router.currentRoute.value.path) + await router.push({ + name: 'Filing' + }) + } + }else{ if (!instance) return instance.validate(async (valid) => { if (!valid) { @@ -597,12 +656,6 @@ const handleSubmit = async (instance) => { } else { res = await projectCheck(params) } - } else if (props.step === '50') { - if (props.mode === 'resubmit') { - res = await resubmitConclusion(params) - } else { - res = await projectConclusion(params) - } } ElNotification({ title: '提示', @@ -619,13 +672,10 @@ const handleSubmit = async (instance) => { await router.push({ name: 'Implementation' }) - } else if (props.step === '50') { - await router.push({ - name: 'Filing' - }) } } }) + } } const init = async () => { let id = projectId.value diff --git a/src/views/project-demand/summary/add.vue b/src/views/project-demand/summary/add.vue index bfaff07..0915da5 100644 --- a/src/views/project-demand/summary/add.vue +++ b/src/views/project-demand/summary/add.vue @@ -235,7 +235,7 @@ + @change="changeCollectData();changeRequirement()"> { + console.log('formData.requirementId',formData.requirementId) + // await getFormInfo(route.query.id).then(res => { + // if (res.code === 1000) { + // formData.value.requirementDefaultName = res.data.requirementName + // // loading.value = false + // formData.value.isSpecialFund = res.data.isSpecialFund + // if (res.data.isSpecialFund) { + // formData.value.specialFundId = res.data.specialFundId + // formData.value.specialFund = res.data.specialFund + // } + // } + // }) +} const changeCollectData = () => { if (name.value === 'Summary/edit') { // params.fileList= attachment.value.allFileList From 69aa6aa0fb562af7b8f5b46b039ce3653e7e7d38 Mon Sep 17 00:00:00 2001 From: dj <1042039504@qq.com> Date: Wed, 2 Apr 2025 23:26:01 +0800 Subject: [PATCH 2/8] =?UTF-8?q?refactor(project-demand):=20=E4=BC=98?= =?UTF-8?q?=E5=8C=96=E9=9C=80=E6=B1=82=E5=8F=98=E6=9B=B4=E6=97=B6=E7=89=B9?= =?UTF-8?q?=E6=AE=8A=E5=9F=BA=E9=87=91=E9=80=BB=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/project-demand/summary/add.vue | 25 ++++++++++++------------ 1 file changed, 12 insertions(+), 13 deletions(-) diff --git a/src/views/project-demand/summary/add.vue b/src/views/project-demand/summary/add.vue index 0915da5..d3734c6 100644 --- a/src/views/project-demand/summary/add.vue +++ b/src/views/project-demand/summary/add.vue @@ -388,7 +388,7 @@ import {useCacheStore} from '@/stores/cache.js' import {useProcessStore} from '@/stores/processStore.js'; import {getSubCompOpt} from "@/api/user/user"; import ProcessDiagramViewer from '@/views/workflow/common/ProcessDiagramViewer.vue'; -import {getFormInfo} from "@/api/project-demand"; +import {getFormInfo, getInfo} from "@/api/project-demand"; import {getFundOption} from "@/api/special-fund"; import UserPicker from "@/views/workflow/process/common/UserPicker.vue"; @@ -474,18 +474,17 @@ if (name.value === 'Summary/edit') { } } const changeRequirement=async ()=>{ - console.log('formData.requirementId',formData.requirementId) - // await getFormInfo(route.query.id).then(res => { - // if (res.code === 1000) { - // formData.value.requirementDefaultName = res.data.requirementName - // // loading.value = false - // formData.value.isSpecialFund = res.data.isSpecialFund - // if (res.data.isSpecialFund) { - // formData.value.specialFundId = res.data.specialFundId - // formData.value.specialFund = res.data.specialFund - // } - // } - // }) + await getInfo(formData.value.requirementId).then(res => { + if (res.code === 1000) { + + console.log('formData.requirementId',formData.value.requirementId,res) + formData.value.isSpecialFund = res.data.formData.isSpecialFund + if ( res.data.formData.isSpecialFund) { + formData.value.specialFundId = res.data.formData.specialFundId + formData.value.specialFund = res.data.formData.specialFund + } + } + }) } const changeCollectData = () => { if (name.value === 'Summary/edit') { From bf34d8aa0c71202336d20b9587beaf1b93832bca Mon Sep 17 00:00:00 2001 From: dj <1042039504@qq.com> Date: Wed, 2 Apr 2025 23:34:45 +0800 Subject: [PATCH 3/8] =?UTF-8?q?feat(ProjectAttachment):=20=E6=B7=BB?= =?UTF-8?q?=E5=8A=A0=E6=96=87=E4=BB=B6=E4=B8=8B=E8=BD=BD=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/DetailComponent/ProjectAttachment.vue | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/components/DetailComponent/ProjectAttachment.vue b/src/components/DetailComponent/ProjectAttachment.vue index 221b4ec..e3e0e93 100644 --- a/src/components/DetailComponent/ProjectAttachment.vue +++ b/src/components/DetailComponent/ProjectAttachment.vue @@ -61,7 +61,7 @@ import {addTag, delTag, getTagList, getTags, updateTag} from "@/api/project-manage"; import {ElLoading, ElMessageBox, ElNotification} from "element-plus"; import {searchImplementationFileList, uploadFileList} from "@/api/project-manage/attachment"; -import {deleteFile} from "@/api/project-demand"; +import {deleteFile, downloadFile} from "@/api/project-demand"; const router = useRouter() const route = useRoute() @@ -151,6 +151,15 @@ const isCloseByList = (index) => { // otherAttachmentList.length>0?false:true return otherAttachmentList.value.length == 0; } +const handleDownload = (row) => { + downloadFile(row.fileId).then(res => { + const blob = new Blob([res]) + let a = document.createElement('a') + a.href = URL.createObjectURL(blob) + a.download = row.originalFileName + a.click() + }) +} const deleteSingleFile = (row) => { deleteFile(row.fileId).then(res => { ElNotification({ From 119e3d83332269a900612b494f91682aa0dc905d Mon Sep 17 00:00:00 2001 From: dj <1042039504@qq.com> Date: Thu, 3 Apr 2025 00:09:41 +0800 Subject: [PATCH 4/8] =?UTF-8?q?feat(ProjectAttachment):=20=E4=BC=98?= =?UTF-8?q?=E5=8C=96=E6=96=87=E4=BB=B6=E4=B8=8A=E4=BC=A0=E6=A0=87=E7=AD=BE?= =?UTF-8?q?=E9=80=BB=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/DetailComponent/ProjectAttachment.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/DetailComponent/ProjectAttachment.vue b/src/components/DetailComponent/ProjectAttachment.vue index e3e0e93..3192b5a 100644 --- a/src/components/DetailComponent/ProjectAttachment.vue +++ b/src/components/DetailComponent/ProjectAttachment.vue @@ -261,7 +261,7 @@ const compositeParam = (item) => { fileType: item.fileType, url: item.url, newFile: true, - tag: getTagName(activeName.value), + tag: getTagName(activeName.value) || '项目实施', } } const getFile = (val) => { From ed22942ab29261df04267a8dabb21493f31d86e8 Mon Sep 17 00:00:00 2001 From: dj <1042039504@qq.com> Date: Thu, 3 Apr 2025 00:11:21 +0800 Subject: [PATCH 5/8] =?UTF-8?q?fix(project-management):=20=E4=BC=98?= =?UTF-8?q?=E5=8C=96=E9=99=84=E4=BB=B6=E5=90=AF=E7=94=A8=E7=A6=81=E7=94=A8?= =?UTF-8?q?=E6=93=8D=E4=BD=9C=E5=8F=8D=E9=A6=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/project-management/filing/index.vue | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/src/views/project-management/filing/index.vue b/src/views/project-management/filing/index.vue index 78f2ab5..561dcc9 100644 --- a/src/views/project-management/filing/index.vue +++ b/src/views/project-management/filing/index.vue @@ -11,7 +11,7 @@ import fvSelect from '@/fvcomponents/fvSelect/index.vue' import {toThousands} from '@/utils/changePrice.js' import {switchAttachmentState} from "@/api/project-manage/attachment"; -import {ElMessageBox} from "element-plus"; +import {ElMessageBox, ElNotification} from "element-plus"; import { getSubCompOpt } from '@/api/user/user.js'; import {filterProjectName} from "@/api/project-manage"; import {filterRequirementName} from "@/api/project-demand"; @@ -436,7 +436,15 @@ const handleOpenUpload=(row,flag)=>{ projectId: row.projectId } switchAttachmentState(params).then(res=>{ - tableIns.value.refresh() + if(res.code==1000){ + tableIns.value.refresh() + }else{ + ElNotification({ + title: '提示', + message: res.msg, + type: 'error' + }) + } }) }) } From 348027f3554fb82191d17374be0d402a91e99838 Mon Sep 17 00:00:00 2001 From: dj <1042039504@qq.com> Date: Thu, 3 Apr 2025 00:34:04 +0800 Subject: [PATCH 6/8] =?UTF-8?q?feat(project-management):=20=E4=BC=98?= =?UTF-8?q?=E5=8C=96=E6=96=87=E4=BB=B6=E5=BD=92=E6=A1=A3=E8=A1=A8=E6=A0=BC?= =?UTF-8?q?=E7=8A=B6=E6=80=81=E5=B1=95=E7=A4=BA=E5=92=8C=E6=9D=83=E9=99=90?= =?UTF-8?q?=E6=8E=A7=E5=88=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/project-management/filing/index.vue | 21 +++++++++++++------ 1 file changed, 15 insertions(+), 6 deletions(-) diff --git a/src/views/project-management/filing/index.vue b/src/views/project-management/filing/index.vue index 561dcc9..a16caa3 100644 --- a/src/views/project-management/filing/index.vue +++ b/src/views/project-management/filing/index.vue @@ -318,10 +318,18 @@ const tableConfig = reactive({ width: 100, showOverflowTooltip: false, currentRender: ({row, index}) => { - if (row.state !== null) { - return () - } else { - return '--' + let buttons = new Set(Array.from(row.buttons)) + if (!buttons.has("openFileSwitch")&&row.state!=1) { + console.log('row',row) + return () + }else if (buttons.has("openFileSwitch")) { + return () + }else{ + if (row.state !== null) { + return () + } else { + return '--' + } } } }, @@ -348,10 +356,10 @@ const tableConfig = reactive({ btn.push({label: '编辑', prem: ['project:management:filing:conclusion'], func: () => handleEdit(row), type: 'primary'}) } if (buttons.has("openFileSwitch")) { - btn.push({label: '开启上传', prem: ['project:management:filing:conclusion'], func: () => handleOpenUpload(row,true), type: 'primary'}) + btn.push({label: '开启上传', prem: ['filing:attachment:switch'], func: () => handleOpenUpload(row,true), type: 'primary'}) } if (buttons.has("closeFileSwitch")) { - btn.push({label: '关闭上传', prem: ['project:management:filing:conclusion'], func: () => handleOpenUpload(row,false), type: 'primary'}) + btn.push({label: '关闭上传', prem: ['filing:attachment:switch'], func: () => handleOpenUpload(row,false), type: 'primary'}) } return (
@@ -426,6 +434,7 @@ const handleEdit = (row) => { }) } const handleOpenUpload=(row,flag)=>{ + console.log('tableIns',tableIns.value) ElMessageBox.confirm(`是否确认${flag?'开启':'关闭'}上传文件?`, '提示', { confirmButtonText: '确定', cancelButtonText: '取消', From eabf9cb3d6788a9e3ee4e3554bcb680501655478 Mon Sep 17 00:00:00 2001 From: dj <1042039504@qq.com> Date: Sun, 6 Apr 2025 16:47:23 +0800 Subject: [PATCH 7/8] =?UTF-8?q?refactor(project):=20=E4=BC=98=E5=8C=96?= =?UTF-8?q?=E9=A1=B9=E7=9B=AE=E7=9B=B8=E5=85=B3=E9=A1=B5=E9=9D=A2=E6=98=BE?= =?UTF-8?q?=E7=A4=BA=E5=86=85=E5=AE=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 修改项目需求、总结、立项、实施、归档页面中的编号标签 - 更新项目申请组件,根据项目类型动态显示实际专项资金输入框 -调整 API 代理配置 --- src/components/DetailComponent/ProjectApply.vue | 17 +++++++++-------- src/views/project-demand/requirement/index.vue | 2 +- src/views/project-demand/summary/index.vue | 2 +- src/views/project-management/filing/index.vue | 2 +- .../project-management/implementation/index.vue | 2 +- .../project-management/initiation/index.vue | 2 +- vite.config.js | 4 ++-- 7 files changed, 16 insertions(+), 15 deletions(-) diff --git a/src/components/DetailComponent/ProjectApply.vue b/src/components/DetailComponent/ProjectApply.vue index a1ef965..070dfb5 100644 --- a/src/components/DetailComponent/ProjectApply.vue +++ b/src/components/DetailComponent/ProjectApply.vue @@ -10,20 +10,13 @@ - + - - - - - - - @@ -180,6 +173,7 @@ import {useProcessStore} from '@/stores/processStore.js'; import {useTagsView} from '@/stores/tagsview.js' import Paging from "@/components/pagination/index.vue"; import UserPicker from "@/views/workflow/process/common/UserPicker.vue"; +import {getBaseInfoApi} from "@/components/steps/api"; const router = useRouter() const route = useRoute() @@ -267,6 +261,7 @@ const selectRows = ref([]) const projectId = ref(route.query.projectId) const sessionParams = ref({}) const optionalChargeLeadershipPickerRef = ref() +const detail = ref(false) const optionalChargeLeadershipList = ref([]) const filePreviewParam = ref({ fileUrl: '', @@ -274,7 +269,13 @@ const filePreviewParam = ref({ fileType: 'pdf' }) const filePreviewShow = ref(false) +const getInfo=async ()=>{ + const {code, data} = await getBaseInfoApi(route.query.projectId) + console.log('data',code,data) + detail.value=data.isSpecialFund +} +getInfo() const getTemplateName=(type)=>{ switch (type) { case 'apply': diff --git a/src/views/project-demand/requirement/index.vue b/src/views/project-demand/requirement/index.vue index 7f10059..eb3561e 100644 --- a/src/views/project-demand/requirement/index.vue +++ b/src/views/project-demand/requirement/index.vue @@ -48,7 +48,7 @@ const tableConfig = reactive({ }, { prop: 'processNumber', - label: '编号', + label: '征集编号', align: 'center', }, { diff --git a/src/views/project-demand/summary/index.vue b/src/views/project-demand/summary/index.vue index 240a2ae..0f61432 100644 --- a/src/views/project-demand/summary/index.vue +++ b/src/views/project-demand/summary/index.vue @@ -220,7 +220,7 @@ const tableConfig = reactive({ }, { prop: 'processNumber', - label: '编号', + label: '项目编号', align: 'center', }, { diff --git a/src/views/project-management/filing/index.vue b/src/views/project-management/filing/index.vue index a16caa3..40815cf 100644 --- a/src/views/project-management/filing/index.vue +++ b/src/views/project-management/filing/index.vue @@ -219,7 +219,7 @@ const tableConfig = reactive({ { prop: 'processNumber', - label: '编号', + label: '项目编号', align: 'center', }, { diff --git a/src/views/project-management/implementation/index.vue b/src/views/project-management/implementation/index.vue index cb440d3..e0d86b7 100644 --- a/src/views/project-management/implementation/index.vue +++ b/src/views/project-management/implementation/index.vue @@ -222,7 +222,7 @@ const tableConfig = reactive({ { prop: 'processNumber', - label: '编号', + label: '项目编号', align: 'center', }, { diff --git a/src/views/project-management/initiation/index.vue b/src/views/project-management/initiation/index.vue index 8089ba1..4cd83d2 100644 --- a/src/views/project-management/initiation/index.vue +++ b/src/views/project-management/initiation/index.vue @@ -216,7 +216,7 @@ const tableConfig = reactive({ }, { prop: 'processNumber', - label: '编号', + label: '项目编号', align: 'center', }, { diff --git a/vite.config.js b/vite.config.js index 0bb55cf..fcfcb8f 100644 --- a/vite.config.js +++ b/vite.config.js @@ -76,8 +76,8 @@ export default defineConfig({ // rewrite: (path) => path.replace(/^\/api/, '') // }, // '/api/admin': { - // // target: 'http://frp.feashow.cn:31800/', - // target: 'http://clay.frp.feashow.cn/', + // target: 'http://frp.feashow.cn:31800/', + // // target: 'http://clay.frp.feashow.cn/', // // target: 'http://192.168.31.175:8000', // changeOrigin: true, // rewrite: (path) => path.replace(/^\/api/, '') From d3c0b36657f47e10070cb70910196b3c005a2141 Mon Sep 17 00:00:00 2001 From: dj <1042039504@qq.com> Date: Sun, 6 Apr 2025 17:10:08 +0800 Subject: [PATCH 8/8] =?UTF-8?q?refactor(views/components):=20=E4=BC=98?= =?UTF-8?q?=E5=8C=96=E9=A6=96=E9=A1=B5=E9=80=9A=E7=9F=A5=E5=85=AC=E5=91=8A?= =?UTF-8?q?=E5=B1=95=E7=A4=BA=E5=92=8C=E9=A1=B9=E7=9B=AE=E9=99=84=E4=BB=B6?= =?UTF-8?q?=E6=90=9C=E7=B4=A2=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 首页通知公告:调整公告列表的序号显示逻辑 - 项目附件:改进附件搜索功能,支持按全部文件搜索 - 搜索组件:更新搜索界面文本,根据搜索范围动态显示标签或项目阶段 --- .../DetailComponent/ProjectAttachment.vue | 25 ++++++++++++++----- src/components/SearchFilesByTag.vue | 6 ++--- src/views/home/index.vue | 3 ++- 3 files changed, 24 insertions(+), 10 deletions(-) diff --git a/src/components/DetailComponent/ProjectAttachment.vue b/src/components/DetailComponent/ProjectAttachment.vue index 3192b5a..e2ad801 100644 --- a/src/components/DetailComponent/ProjectAttachment.vue +++ b/src/components/DetailComponent/ProjectAttachment.vue @@ -241,7 +241,11 @@ const handleTabClick = (item) => { isEdit.value = false } if (item.props.name != 'plus') { - changeFileList(getTagName(item.props.name)) + if(item.props.name == 'all'){ + changeFileList('all') + }else{ + changeFileList(getTagName(item.props.name)) + } // if (item.props.name == 'all') { // otherAttachmentList.value = allFiles.value // } else { @@ -300,12 +304,21 @@ const clickToPreview = (row) => { }) } const changeFileList=(tag)=>{ - showAttachmentTable.value = false - let params = { - targetId: route.query.projectId, - targetState: "30", - tag:tag + let params = {} + if(tag=='all'){ + params = { + targetId: route.query.projectId, + targetState: "30", + } + }else{ + params = { + targetId: route.query.projectId, + targetState: "30", + tag:tag + } } + showAttachmentTable.value = false + searchImplementationFileList(params).then(res => { if (res.code === 1000) { otherAttachmentList.value = res.data.fileList diff --git a/src/components/SearchFilesByTag.vue b/src/components/SearchFilesByTag.vue index 44200da..6b85097 100644 --- a/src/components/SearchFilesByTag.vue +++ b/src/components/SearchFilesByTag.vue @@ -4,8 +4,8 @@ - - + +
- {{ index > 8 ? '' : 0 }}{{ index + 1 }}{{ item.articleTitle }} + {{ index > 8 ? '' : 0 }}{{ index + 1 }} + {{ item.articleTitle }}