fix : 修复项目实施-归档列表页附件项目实施/验收展示及上传附件功能,修复需求上报资金名称传参

This commit is contained in:
2024-08-28 22:55:40 +08:00
parent 060f6e0fd8
commit d4d7601bae
8 changed files with 24 additions and 16 deletions

View File

@@ -105,7 +105,7 @@ const handleSearch = () => {
const loading = ElLoading.service({fullscreen: true}) const loading = ElLoading.service({fullscreen: true})
let params = { let params = {
targetId: route.query.projectId, targetId: route.query.projectId,
targetState: "40" targetState: "30"
} }
if (attachmentParam.tag) { if (attachmentParam.tag) {
tagsOption.value.forEach(item => { tagsOption.value.forEach(item => {

View File

@@ -4,8 +4,8 @@
<el-form-item label="名称" prop="fileName"> <el-form-item label="名称" prop="fileName">
<el-input v-model="attachment.fileName" placeholder="请输入文件名查询" clearable filterable style="width: 300px"/> <el-input v-model="attachment.fileName" placeholder="请输入文件名查询" clearable filterable style="width: 300px"/>
</el-form-item> </el-form-item>
<el-form-item label="标签" prop="tag" v-if="type==='40'"> <el-form-item label="标签" prop="tag" v-if="type==='30'">
<el-select v-model="attachment.tag" placeholder="请选择标签" clearable remote filterable style="width: 300px"> <el-select v-model="attachment.tag" placeholder="请选择标签" clearable filterable style="width: 300px">
<el-option <el-option
v-for="item in tagsOption" v-for="item in tagsOption"
:key="item.value" :key="item.value"
@@ -179,12 +179,12 @@ watch(() => props.fileList, (val) => {
}) })
props.fileList = val props.fileList = val
}) })
if (props.type === '40') { if (props.type === '30') {
getTagsOption() getTagsOption()
} }
onActivated(()=>{ onActivated(()=>{
if (props.type === '40') { if (props.type === '30') {
getTagsOption() getTagsOption()
} }
handleSearch() handleSearch()

View File

@@ -489,6 +489,9 @@ const handleSubmit = debounce(async (instance) => {
if (formData.value.singleFile !== undefined) { if (formData.value.singleFile !== undefined) {
formData.value.singleFile = getFileParam(formData.value.singleFile) formData.value.singleFile = getFileParam(formData.value.singleFile)
} }
if (formData.value.isSpecialFund && !formData.value.specialFund) {
formData.value.specialFund = getFundName(formData.value.specialFundId)
}
if (!attachment.value.isHaveOneFile) { if (!attachment.value.isHaveOneFile) {
attachment.value.validate() attachment.value.validate()
ElNotification({ ElNotification({
@@ -539,7 +542,7 @@ const handleResubmit = debounce((instance) => {
}) })
} }
formData.value.optionalChargeLeadership = optionalChargeLeadershipList.value formData.value.optionalChargeLeadership = optionalChargeLeadershipList.value
if (formData.value.isSpecialFund && formData.value.specialFund === null) { if (formData.value.isSpecialFund && !formData.value.specialFund) {
formData.value.specialFund = getFundName(formData.value.specialFundId) formData.value.specialFund = getFundName(formData.value.specialFundId)
} }
if (!attachment.value.isHaveOneFile) { if (!attachment.value.isHaveOneFile) {

View File

@@ -4,7 +4,7 @@
<fvForm :schema="schema" @getInstance="(e)=>baseForm = e" label-position="left" label-width="left" style="margin-left: 15px"></fvForm> <fvForm :schema="schema" @getInstance="(e)=>baseForm = e" label-position="left" label-width="left" style="margin-left: 15px"></fvForm>
<el-tabs v-model="activeName" class="demo-tabs" @tab-click="handleClick"> <el-tabs v-model="activeName" class="demo-tabs" @tab-click="handleClick">
<el-tab-pane v-for="item in paneList" :label="item.label" :name="item.name"> <el-tab-pane v-for="item in paneList" :label="item.label" :name="item.name">
<search-files-by-tag @search="search" @upload="upload" :type="item.name==='40'?'40':''" <search-files-by-tag @search="search" @upload="upload" :type="item.name==='30'?'30':''"
:fileList="fileList" :uploadState="uploadState" v-model:loading="loading"/> :fileList="fileList" :uploadState="uploadState" v-model:loading="loading"/>
</el-tab-pane> </el-tab-pane>
</el-tabs> </el-tabs>
@@ -247,6 +247,10 @@ const paneList = ref([
}, },
{ {
label: '项目实施', label: '项目实施',
name: '30'
},
{
label: '项目验收',
name: '40' name: '40'
}, },
{ {
@@ -318,13 +322,13 @@ const changeFileList = (res) => {
} }
const upload = () => { const upload = () => {
if (activeName.value === '40') { if (activeName.value === '30') {
router.push({ router.push({
name: 'Implementation/upload', name: 'Implementation/upload',
query: { query: {
projectId: route.query.id, projectId: route.query.id,
requirementId: requirementId.value, requirementId: requirementId.value,
type: '40' type: '30'
} }
}) })
} else { } else {

View File

@@ -371,7 +371,7 @@ const getName = () => {
case '20': case '20':
return '项目立项' return '项目立项'
case '40': case '40':
return '项目实施' return '项目验收'
case '50': case '50':
return '项目归档' return '项目归档'
} }

View File

@@ -79,7 +79,7 @@ const singleList = ref([])
const name = ref(router.currentRoute.value.name) const name = ref(router.currentRoute.value.name)
const loading = ref(false) const loading = ref(false)
const formData = ref({ const formData = ref({
changeState:'1' changeState:'0'
}) })
const file = ref({}) const file = ref({})
const deploymentId = ref() const deploymentId = ref()

View File

@@ -449,7 +449,7 @@ const handleSubmit = async (instance) => {
let params = { let params = {
fileList: fileList.value, fileList: fileList.value,
projectId: route.query.projectId, projectId: route.query.projectId,
targetState: "40" targetState: "30"
} }
let res = await uploadFileList(params) let res = await uploadFileList(params)
ElNotification({ ElNotification({
@@ -459,12 +459,13 @@ const handleSubmit = async (instance) => {
}) })
if (res.code === 1000) { if (res.code === 1000) {
tagsViewStore.delVisitedViews(router.currentRoute.value.path) tagsViewStore.delVisitedViews(router.currentRoute.value.path)
if (route.query.type === '40') { if (route.query.type === '30') {
console.log('归档实施') console.log('归档实施')
await router.push({ await router.push({
name: 'Filing/attachment', name: 'Filing/attachment',
query: { query: {
id: route.query.projectId, id: route.query.projectId,
name:route.query.type,
requirementId: route.query.requirementId requirementId: route.query.requirementId
} }
}) })

View File

@@ -76,14 +76,14 @@ export default defineConfig({
// rewrite: (path) => path.replace(/^\/api/, '') // rewrite: (path) => path.replace(/^\/api/, '')
// }, // },
// '/api/admin': { // '/api/admin': {
// target: 'http://frp.feashow.cn:31800/', // // target: 'http://frp.feashow.cn:31800/',
// // target: 'http://clay.frp.feashow.cn/', // target: 'http://clay.frp.feashow.cn/',
// // target: 'http://192.168.31.175:8000', // // target: 'http://192.168.31.175:8000',
// changeOrigin: true, // changeOrigin: true,
// rewrite: (path) => path.replace(/^\/api/, '') // rewrite: (path) => path.replace(/^\/api/, '')
// }, // },
'/api': { '/api': {
// target: 'http://kyglweb.scgzjy.com:8080/', // // target: 'http://kyglweb.scgzjy.com:8080/',
target: 'http://mosr.feashow.cn', target: 'http://mosr.feashow.cn',
changeOrigin: true, changeOrigin: true,
// target: 'http://clay.frp.feashow.cn', // target: 'http://clay.frp.feashow.cn',