fix : 修复提交/重新提交按钮显示
This commit is contained in:
@@ -50,8 +50,8 @@
|
||||
<!-- </div>-->
|
||||
</div>
|
||||
<div class="oper-page-btn">
|
||||
<el-button color="#DED0B2" @click="handleSubmit(demandForm)">提交</el-button>
|
||||
<el-button color="#DED0B2" @click="handleResubmit">重新提交</el-button>
|
||||
<el-button color="#DED0B2" v-if="routerName==='Requirement/add'" @click="handleSubmit(demandForm)">提交</el-button>
|
||||
<el-button color="#DED0B2" v-else @click="handleResubmit">重新提交</el-button>
|
||||
<el-button @click="handleBack">返回</el-button>
|
||||
</div>
|
||||
</div>
|
||||
@@ -90,6 +90,7 @@ const formData = ref({
|
||||
fileList: []
|
||||
})
|
||||
const showTinymce = ref(true)
|
||||
const routerName = ref(router.currentRoute.value.name)
|
||||
const processDiagramViewer = ref(false)
|
||||
const typeOption = ref([
|
||||
{
|
||||
@@ -174,11 +175,10 @@ const handleDownload = (row) => {
|
||||
})
|
||||
}
|
||||
const compositeParam = (item) => {
|
||||
let name=router.currentRoute.value.name
|
||||
let tag = ''
|
||||
if (!formData.value.collectType && name === 'Requirement/add') {
|
||||
if (!formData.value.collectType && routerName.value === 'Requirement/add') {
|
||||
tag = '需求征集'
|
||||
}else if(name === 'Requirement/edit'){
|
||||
}else if(routerName.value === 'Requirement/edit'){
|
||||
tag = '需求征集'
|
||||
}
|
||||
return {
|
||||
|
||||
@@ -4,8 +4,8 @@
|
||||
<el-form :model="formData" ref="summaryForm" :rules="rules">
|
||||
<el-row gutter="50">
|
||||
<el-col :span="12">
|
||||
<el-form-item label="名称" prop="projectName">
|
||||
<el-input v-model="formData.projectName" placeholder="请输入名称" clearable></el-input>
|
||||
<el-form-item label="项目名称" prop="projectName">
|
||||
<el-input v-model="formData.projectName" placeholder="请输入项目名称" clearable></el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
@@ -227,9 +227,9 @@
|
||||
<!-- </div>-->
|
||||
</div>
|
||||
<div class="oper-page-btn">
|
||||
<el-button type="primary" @click="staging">存为草稿</el-button>
|
||||
<el-button type="primary" @click="handleSubmit(summaryForm)">发布</el-button>
|
||||
<el-button color="#DED0B2" @click="handleResubmit">重新发布</el-button>
|
||||
<el-button type="info" @click="staging">存为草稿</el-button>
|
||||
<el-button color="#DED0B2" v-if="name==='Summary/add'" @click="handleSubmit(summaryForm)">发布</el-button>
|
||||
<el-button color="#DED0B2" v-else @click="handleResubmit">重新发布</el-button>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -11,8 +11,8 @@
|
||||
</div>
|
||||
</el-form>
|
||||
<div class="oper-page-btn">
|
||||
<el-button color="#DED0B2" @click="handleSubmit(applyForm)">提交</el-button>
|
||||
<el-button color="#DED0B2" @click="handleResubmit">重新提交</el-button>
|
||||
<el-button color="#DED0B2" v-if="name==='Filing/conclusion'" @click="handleSubmit(applyForm)">提交</el-button>
|
||||
<el-button color="#DED0B2" v-else @click="handleResubmit">重新提交</el-button>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -18,8 +18,8 @@
|
||||
<process-diagram-viewer mode="view" v-if="processDiagramViewer"/>
|
||||
</div>
|
||||
<div class="oper-page-btn">
|
||||
<el-button color="#DED0B2" @click="handleSubmit(applyForm)">提交</el-button>
|
||||
<el-button color="#DED0B2" @click="handleResubmit(applyForm)">重新提交</el-button>
|
||||
<el-button color="#DED0B2" v-if="name==='Implementation/check'" @click="handleSubmit(applyForm)">提交</el-button>
|
||||
<el-button color="#DED0B2" v-else @click="handleResubmit(applyForm)">重新提交</el-button>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -1,13 +1,16 @@
|
||||
<template>
|
||||
<baseTitle title="上传费用"></baseTitle>
|
||||
<el-table :data="tableData" style="width: 100%">
|
||||
<el-form :model="tableForm" :rules="rules">
|
||||
<el-table :data="tableForm.tableData" style="width: 100%">
|
||||
<el-table-column prop="projectName" label="项目名称">
|
||||
<template #default="scope">
|
||||
<el-form-item prop="projectName">
|
||||
<el-input v-model="scope.row.projectName" placeholder="请输入项目名称" clearable>
|
||||
</el-input>
|
||||
</el-form-item>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="time" label="时间" width="250">
|
||||
<el-table-column prop="time" label="时间">
|
||||
<template #default="scope">
|
||||
<el-date-picker
|
||||
v-model="scope.row.time"
|
||||
@@ -49,6 +52,7 @@
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-form>
|
||||
<div style="width:100%;text-align: center;padding: 10px">
|
||||
<el-button type="primary" @click="handleAdd" link style="font-size: 18px">添加一行</el-button>
|
||||
</div>
|
||||
@@ -67,7 +71,11 @@ import {useRoute} from "vue-router";
|
||||
const route = useRoute()
|
||||
const tagsViewStore = useTagsView()
|
||||
const formData = ref({})
|
||||
const tableData = ref([
|
||||
const rules = reactive({
|
||||
auditOpinion: [{required: true, message: '请输入审核意见', trigger: 'blur'}],
|
||||
})
|
||||
const tableForm = reactive({
|
||||
tableData: [
|
||||
{
|
||||
projectId: route.query.id,
|
||||
projectName: '',
|
||||
@@ -77,7 +85,8 @@ const tableData = ref([
|
||||
digest: '',
|
||||
afterTax: ''
|
||||
}
|
||||
])
|
||||
]
|
||||
})
|
||||
const handleAdd = () => {
|
||||
let row = {
|
||||
projectId: route.query.id,
|
||||
@@ -88,18 +97,18 @@ const handleAdd = () => {
|
||||
digest: '',
|
||||
afterTax: ''
|
||||
}
|
||||
tableData.value.push(row)
|
||||
tableForm.tableData.push(row)
|
||||
}
|
||||
const handleDelete = (index) => {
|
||||
tableData.value.splice(index, 1)
|
||||
tableForm.tableData.splice(index, 1)
|
||||
}
|
||||
const handleSubmit = (instance) => {
|
||||
// if (!instance) return
|
||||
// instance.validate(async (valid) => {
|
||||
// if (!valid) return
|
||||
let params = {}
|
||||
console.log('params', tableData.value)
|
||||
const res = addLedger(tableData.value)
|
||||
console.log('params', tableForm.tableData)
|
||||
const res = addLedger(tableForm.tableData)
|
||||
ElNotification({
|
||||
title: '提示',
|
||||
message: res.msg,
|
||||
|
||||
@@ -12,14 +12,15 @@
|
||||
</el-form>
|
||||
<AttachmentUpload ref="attachment" label="需求申请书附件" :showTable="showTable" :otherFileList="otherFileList"
|
||||
@getAttachment="getAttachment"
|
||||
@getOtherFile="getOtherFile" :showFileList="true" :formData="formData" :preview="name === 'Initiation/edit'"/>
|
||||
@getOtherFile="getOtherFile" :showFileList="true" :formData="formData"
|
||||
:preview="name === 'Initiation/edit'"/>
|
||||
<div class="approval-record">
|
||||
<baseTitle title="流程"></baseTitle>
|
||||
<process-diagram-viewer mode="view" v-if="processDiagramViewer"/>
|
||||
</div>
|
||||
<div class="oper-page-btn">
|
||||
<el-button color="#DED0B2" @click="handleSubmit(applyForm)">提交</el-button>
|
||||
<el-button color="#DED0B2" @click="handleResubmit">重新提交</el-button>
|
||||
<el-button color="#DED0B2" v-if="name==='Initiation/apply'" @click="handleSubmit(applyForm)">提交</el-button>
|
||||
<el-button color="#DED0B2" v-else @click="handleResubmit">重新提交</el-button>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
Reference in New Issue
Block a user