From ba86f54369c3ac9f3bce3379a17e705e37a2da7d Mon Sep 17 00:00:00 2001
From: odjbin <1042039504@qq.com>
Date: Tue, 28 May 2024 16:36:03 +0800
Subject: [PATCH] =?UTF-8?q?fix=20:=20=E4=BF=AE=E5=A4=8D=E4=B8=93=E9=A1=B9?=
=?UTF-8?q?=E8=B5=84=E9=87=91=E9=A1=B5=E9=9D=A2=E5=8A=9F=E8=83=BD=E7=BB=86?=
=?UTF-8?q?=E8=8A=82?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/api/special-fund/index.js | 22 ++
.../DetailComponent/CollectionDetail.vue | 4 +-
.../DetailComponent/SpecialFundDetail.vue | 204 +++++++++++++++
src/views/project-demand/requirement/add.vue | 34 +--
.../project-demand/requirement/index.vue | 16 +-
src/views/project-demand/summary/index.vue | 1 -
.../implementation/attachment.vue | 1 -
src/views/special-fund/add.vue | 241 ++++++++++++++++++
src/views/special-fund/detail.vue | 48 ++++
src/views/special-fund/index.vue | 140 ++++++++++
10 files changed, 682 insertions(+), 29 deletions(-)
create mode 100644 src/api/special-fund/index.js
create mode 100644 src/components/DetailComponent/SpecialFundDetail.vue
create mode 100644 src/views/special-fund/add.vue
create mode 100644 src/views/special-fund/detail.vue
create mode 100644 src/views/special-fund/index.vue
diff --git a/src/api/special-fund/index.js b/src/api/special-fund/index.js
new file mode 100644
index 0000000..2b82339
--- /dev/null
+++ b/src/api/special-fund/index.js
@@ -0,0 +1,22 @@
+import request from '@/utils/request.js'
+
+export const getFundDetail = (specialFundId) => {
+ return request({
+ url: `/workflow/mosr/special/fund/info/${specialFundId}`,
+ method: "get"
+ });
+};
+export const addFund= (data) => {
+ return request({
+ url: '/workflow/mosr/special/fund',
+ method: "post",
+ data
+ });
+};
+export const resubmitFund= (data) => {
+ return request({
+ url: '/workflow/mosr/special/fund/resubmit',
+ method: "post",
+ data
+ });
+};
diff --git a/src/components/DetailComponent/CollectionDetail.vue b/src/components/DetailComponent/CollectionDetail.vue
index f1fdfd4..ffed32d 100644
--- a/src/components/DetailComponent/CollectionDetail.vue
+++ b/src/components/DetailComponent/CollectionDetail.vue
@@ -146,7 +146,7 @@ const handleDownload = (row) => {
a.click()
})
}
-const getDataSourceOptionItem = (val) => {
+const getCompanyOptionItem = (val) => {
if (val instanceof Array) {
val.forEach(item => {
matterTree(companyNameArray.value, props.companyOption, item)
@@ -165,7 +165,7 @@ watch(() => props.companyOption, (newVal) => {
}, {deep: true})
watch(() => props.formData, (newVal) => {
if(newVal!=null){
- props.formData.companyIds = getDataSourceOptionItem(newVal.companyIds)
+ props.formData.companyIds = getCompanyOptionItem(newVal.companyIds)
}
}, {deep: true})
watch(() => props.processViewer, (newVal) => {
diff --git a/src/components/DetailComponent/SpecialFundDetail.vue b/src/components/DetailComponent/SpecialFundDetail.vue
new file mode 100644
index 0000000..5434aec
--- /dev/null
+++ b/src/components/DetailComponent/SpecialFundDetail.vue
@@ -0,0 +1,204 @@
+
+
+
+
+
+
+
+ {{ formData.name }}
+
+
+
+
+ {{ formData.fundAmount }}
+
+
+
+
+ {{ formData.residualAmount }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/project-demand/requirement/add.vue b/src/views/project-demand/requirement/add.vue
index 68c2bfc..0d2df9c 100644
--- a/src/views/project-demand/requirement/add.vue
+++ b/src/views/project-demand/requirement/add.vue
@@ -2,7 +2,6 @@
-
@@ -30,7 +29,6 @@
/>
-
handleDownload(row)}>下载
- handleDelete(row)}>删除
)
}
+ // handleDelete(row)}>删除
}
]
})
@@ -176,11 +174,13 @@ const handleDownload = (row) => {
})
}
const compositeParam = (item) => {
- console.log('router.currentRoute.value.path',router.currentRoute.value.path)
+ let name=router.currentRoute.value.name
let tag = ''
- // if (!formData.value.collectType && router.currentRoute.value.path === 'Requirement/add') {
- // tag = '需求征集'
- // }
+ if (!formData.value.collectType && name === 'Requirement/add') {
+ tag = '需求征集'
+ }else if(name === 'Requirement/edit'){
+ tag = '需求征集'
+ }
return {
fileId: item.id,
size: item.size,
@@ -254,28 +254,32 @@ const handleSubmit = async (instance) => {
if (!instance) return
instance.validate(async (valid) => {
if (!valid) return
- let res = await addRequirement(submitParam(formData.value))
- if (res.code === 1000) {
- ElMessage.success(res.msg)
+ const {msg,code} = await addRequirement(submitParam(formData.value))
+ ElNotification({
+ title: '提示',
+ message: msg,
+ type: code === 1000 ? 'success' : 'error'
+ })
+ if (code === 1000) {
tagsViewStore.delVisitedViews(router.currentRoute.value.path)
await router.push({
name: 'Requirement'
})
- } else {
- ElMessage.error(res.msg)
}
})
}
const handleResubmit = () => {
resubmit(submitParam(formData.value)).then(res => {
+ ElNotification({
+ title: '提示',
+ message: res.msg,
+ type: res.code === 1000 ? 'success' : 'error'
+ })
if (res.code === 1000) {
- ElMessage.success(res.msg)
tagsViewStore.delVisitedViews(router.currentRoute.value.path)
router.push({
name: 'Requirement'
})
- } else {
- ElMessage.error(res.msg)
}
})
}
diff --git a/src/views/project-demand/requirement/index.vue b/src/views/project-demand/requirement/index.vue
index 8bb7a27..3199e05 100644
--- a/src/views/project-demand/requirement/index.vue
+++ b/src/views/project-demand/requirement/index.vue
@@ -148,19 +148,15 @@ const handleAdd = () => {
try{
router.push({
name:'Requirement/add',
- query: {
- isAdd: 1
- }
+ query:{}
})
}catch (err){
- ElNotification({
- title: '提示',
- message: '该用户无新增权限',
- type: 'warning'
- })
+ // ElNotification({
+ // title: '提示',
+ // message: '该用户无新增权限',
+ // type: 'warning'
+ // })
}
- //新增
-
}
const handleEdit = (row) => {
router.push({
diff --git a/src/views/project-demand/summary/index.vue b/src/views/project-demand/summary/index.vue
index f0a9542..fad2ccc 100644
--- a/src/views/project-demand/summary/index.vue
+++ b/src/views/project-demand/summary/index.vue
@@ -123,7 +123,6 @@ const tableConfig = reactive({
currentRender: ({row, index}) => {
let btn = []
let buttons = new Set(Array.from(row.buttons))
- console.log('buttons',buttons.has("details"))
if (buttons.has("details")) {
btn.push({label: '详情', prem: ['mosr:collect:info'], func: () => handleDetail(row), type: 'primary'})
}
diff --git a/src/views/project-management/implementation/attachment.vue b/src/views/project-management/implementation/attachment.vue
index 85dde95..369ce80 100644
--- a/src/views/project-management/implementation/attachment.vue
+++ b/src/views/project-management/implementation/attachment.vue
@@ -71,7 +71,6 @@ const tableConfig = reactive({
return (
handleDownload(row)}>下载
- beforeRemove(row)}>删除
)
}
diff --git a/src/views/special-fund/add.vue b/src/views/special-fund/add.vue
new file mode 100644
index 0000000..a0b3c08
--- /dev/null
+++ b/src/views/special-fund/add.vue
@@ -0,0 +1,241 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 提交
+ 重新提交
+ 返回
+
+
+
+
+
+
+
diff --git a/src/views/special-fund/detail.vue b/src/views/special-fund/detail.vue
new file mode 100644
index 0000000..ddd0651
--- /dev/null
+++ b/src/views/special-fund/detail.vue
@@ -0,0 +1,48 @@
+
+
+
+
+
+
diff --git a/src/views/special-fund/index.vue b/src/views/special-fund/index.vue
new file mode 100644
index 0000000..f0892ce
--- /dev/null
+++ b/src/views/special-fund/index.vue
@@ -0,0 +1,140 @@
+
+
+
+
+
+
+
+
+