fix : 二级页面上加基础信息

This commit is contained in:
2024-06-10 23:28:34 +08:00
parent 050c5cf57a
commit 1009cb7345
11 changed files with 195 additions and 53 deletions

View File

@@ -2,7 +2,7 @@
<div v-loading="loading"> <div v-loading="loading">
<el-form :model="formData" label-width="auto"> <el-form :model="formData" label-width="auto">
<el-row> <el-row>
<el-col :span="12"> <el-col :span="12" v-if="type==='singleDetail'">
<el-form-item label="征集名称"> <el-form-item label="征集名称">
<span>{{ formData.requirementName }}</span> <span>{{ formData.requirementName }}</span>
</el-form-item> </el-form-item>
@@ -17,7 +17,7 @@
<span>{{ formData.companyIds }}</span> <span>{{ formData.companyIds }}</span>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="type==='singleDetail'?12:24"> <el-col :span="12">
<el-form-item label="截止时间"> <el-form-item label="截止时间">
<span>{{ formData.deadline }}</span> <span>{{ formData.deadline }}</span>
</el-form-item> </el-form-item>

View File

@@ -99,13 +99,6 @@ const schema = computed(() => {
span: 12 span: 12
} }
}, },
{
label: '征集类型',
prop: 'collectType',
colProps: {
span: 12
}
},
{ {
label: '所属公司', label: '所属公司',
prop: 'affiliatedCompany', prop: 'affiliatedCompany',
@@ -114,8 +107,8 @@ const schema = computed(() => {
} }
}, },
{ {
label: '截止时间', label: '项目名称',
prop: 'deadline', prop: 'projectName',
colProps: { colProps: {
span: 12 span: 12
} }

View File

@@ -1,4 +1,6 @@
<template> <template>
<baseTitle title="基础信息"></baseTitle>
<fvForm :schema="schema" @getInstance="(e)=>baseForm = e"></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==='40'?'40':''"
@@ -10,6 +12,8 @@
<script setup lang="jsx"> <script setup lang="jsx">
import {searchFileList} from "@/api/project-manage/attachment.js"; import {searchFileList} from "@/api/project-manage/attachment.js";
import {ElNotification} from "element-plus"; import {ElNotification} from "element-plus";
import {computed, ref} from "vue";
import {getBaseInfoApi} from "@/components/steps/api";
const route = useRoute() const route = useRoute()
const router = useRouter() const router = useRouter()
@@ -20,6 +24,25 @@ const uploadState = ref(true)
const fileList = ref([]) const fileList = ref([])
const projectId = ref(route.query.id) const projectId = ref(route.query.id)
const requirementId = ref(route.query.requirementId) const requirementId = ref(route.query.requirementId)
const schema = computed(() => {
return [
{
label: '征集名称',
prop: 'requirementName',
colProps: {
span: 12
}
},
{
label: '项目名称',
prop: 'projectName',
colProps: {
span: 12
}
}
]
})
const baseForm = ref()
const paneList=ref([ const paneList=ref([
{ {
label:'需求征集', label:'需求征集',
@@ -42,7 +65,15 @@ const paneList=ref([
name:'50' name:'50'
} }
]) ])
const getBaseInfo = async () => {
try {
const {code, data} = await getBaseInfoApi(route.query.id)
baseForm.value.setValues(data)
} catch {
}
}
getBaseInfo()
const handleClick = (tab) => { const handleClick = (tab) => {
activeName.value=tab.props.name activeName.value=tab.props.name
loading.value=true loading.value=true

View File

@@ -1,4 +1,6 @@
<template> <template>
<baseTitle title="基础信息"></baseTitle>
<fvForm :schema="schema" @getInstance="(e)=>baseForm = e"></fvForm>
<baseTitle title="上传附件"></baseTitle> <baseTitle title="上传附件"></baseTitle>
<el-card style="width: 100%;margin: 15px 0"> <el-card style="width: 100%;margin: 15px 0">
<file-upload @getFile="getFile" /> <file-upload @getFile="getFile" />
@@ -18,6 +20,8 @@
import {ElNotification} from "element-plus"; import {ElNotification} from "element-plus";
import {useTagsView} from '@/stores/tagsview.js' import {useTagsView} from '@/stores/tagsview.js'
import {uploadFileList} from "@/api/project-manage/attachment"; import {uploadFileList} from "@/api/project-manage/attachment";
import {computed, ref} from "vue";
import {getBaseInfoApi} from "@/components/steps/api";
const tagsViewStore = useTagsView() const tagsViewStore = useTagsView()
const route = useRoute() const route = useRoute()
@@ -26,6 +30,25 @@ const fileList = ref([])
const formData = ref({ const formData = ref({
tagName:'' tagName:''
}) })
const schema = computed(() => {
return [
{
label: '征集名称',
prop: 'requirementName',
colProps: {
span: 12
}
},
{
label: '项目名称',
prop: 'projectName',
colProps: {
span: 12
}
}
]
})
const baseForm = ref()
const tableConfig = reactive({ const tableConfig = reactive({
columns: [ columns: [
{ {
@@ -70,6 +93,15 @@ const name = ref(router.currentRoute.value.name)
const rules = reactive({ const rules = reactive({
tagName: [{required: true, message: '请输入标签名称', trigger: 'blur'}], tagName: [{required: true, message: '请输入标签名称', trigger: 'blur'}],
}) })
const getBaseInfo = async () => {
try {
const {code, data} = await getBaseInfoApi(route.query.id)
baseForm.value.setValues(data)
} catch {
}
}
getBaseInfo()
const compositeParam = (item) => { const compositeParam = (item) => {
let tag='' let tag=''
switch (route.query.name) { switch (route.query.name) {

View File

@@ -1,4 +1,6 @@
<template> <template>
<baseTitle title="基础信息"></baseTitle>
<fvForm :schema="schema" @getInstance="(e)=>baseForm = e"></fvForm>
<fvSearchForm :searchConfig="searchConfig" @search="search"></fvSearchForm> <fvSearchForm :searchConfig="searchConfig" @search="search"></fvSearchForm>
<fvTable ref="tableIns" :tableConfig="tableConfig" @headBtnClick="headBtnClick"> <fvTable ref="tableIns" :tableConfig="tableConfig" @headBtnClick="headBtnClick">
<template #empty> <template #empty>
@@ -10,9 +12,30 @@
<script setup lang="jsx"> <script setup lang="jsx">
import fvSelect from '@/fvcomponents/fvSelect/index.vue' import fvSelect from '@/fvcomponents/fvSelect/index.vue'
import {toThousands} from '@/utils/changePrice.js' import {toThousands} from '@/utils/changePrice.js'
import {computed, ref} from "vue";
import {getBaseInfoApi} from "@/components/steps/api";
const router = useRouter() const router = useRouter()
const route = useRoute() const route = useRoute()
const schema = computed(() => {
return [
{
label: '征集名称',
prop: 'requirementName',
colProps: {
span: 12
}
},
{
label: '项目名称',
prop: 'projectName',
colProps: {
span: 12
}
}
]
})
const baseForm = ref()
const searchConfig = reactive([ const searchConfig = reactive([
{ {
label: '项目名称', label: '项目名称',
@@ -141,6 +164,15 @@ const tableConfig = reactive({
] ]
}) })
const tableIns=ref() const tableIns=ref()
const getBaseInfo = async () => {
try {
const {code, data} = await getBaseInfoApi(route.query.id)
baseForm.value.setValues(data)
} catch {
}
}
getBaseInfo()
const headBtnClick = (key) => { const headBtnClick = (key) => {
switch (key) { switch (key) {
case 'add': case 'add':

View File

@@ -50,13 +50,6 @@ const schema = computed(() => {
span: 12 span: 12
} }
}, },
{
label: '征集类型',
prop: 'collectType',
colProps: {
span: 12
}
},
{ {
label: '项目名称', label: '项目名称',
prop: 'projectName', prop: 'projectName',
@@ -64,13 +57,6 @@ const schema = computed(() => {
span: 12 span: 12
} }
}, },
{
label: '所属公司',
prop: 'affiliatedCompany',
colProps: {
span: 12
}
}
] ]
}) })
const baseForm = ref() const baseForm = ref()

View File

@@ -1,5 +1,7 @@
<template> <template>
<div class="apply-block"> <div class="apply-block">
<baseTitle title="基础信息"></baseTitle>
<fvForm :schema="schema" @getInstance="(e)=>baseForm = e"></fvForm>
<el-form :model="formData" label-width="auto"> <el-form :model="formData" label-width="auto">
<el-form-item label="抄送人员"> <el-form-item label="抄送人员">
<Ttsup :modelValue="chooseUserInfo()" @click="chooseUser"/> <Ttsup :modelValue="chooseUserInfo()" @click="chooseUser"/>
@@ -29,6 +31,8 @@ import {getPhaseProcess, submitPhaseChange, getPhaseForm, resubmitPhaseForm} fro
import {ElNotification} from "element-plus"; import {ElNotification} from "element-plus";
import {useProcessStore} from '@/stores/processStore.js'; import {useProcessStore} from '@/stores/processStore.js';
import {useTagsView} from '@/stores/tagsview.js' import {useTagsView} from '@/stores/tagsview.js'
import {computed, ref} from "vue";
import {getBaseInfoApi} from "@/components/steps/api";
const tagsViewStore = useTagsView() const tagsViewStore = useTagsView()
const router = useRouter() const router = useRouter()
@@ -46,6 +50,34 @@ const processInstanceData = ref()
const processDiagramViewer = ref(true) const processDiagramViewer = ref(true)
const userList = ref([]) const userList = ref([])
const processStore = useProcessStore() const processStore = useProcessStore()
const schema = computed(() => {
return [
{
label: '征集名称',
prop: 'requirementName',
colProps: {
span: 12
}
},
{
label: '项目名称',
prop: 'projectName',
colProps: {
span: 12
}
}
]
})
const baseForm = ref()
const getBaseInfo = async () => {
try {
const {code, data} = await getBaseInfoApi(route.query.projectId)
baseForm.value.setValues(data)
} catch {
}
}
getBaseInfo()
const compositeParam = (item) => { const compositeParam = (item) => {
let tag = '' let tag = ''
if (name.value === 'Phase/change') { if (name.value === 'Phase/change') {

View File

@@ -1,4 +1,6 @@
<template> <template>
<baseTitle title="基础信息"></baseTitle>
<fvForm :schema="schema" @getInstance="(e)=>baseForm = e"></fvForm>
<baseTitle title="阶段变更详情"></baseTitle> <baseTitle title="阶段变更详情"></baseTitle>
<div style="color: #606266;font-size: 14px">抄送人{{copyName}}</div> <div style="color: #606266;font-size: 14px">抄送人{{copyName}}</div>
<ApprovalDetail :formData="summaryData.formData" :data="summaryData" type="phase" <ApprovalDetail :formData="summaryData.formData" :data="summaryData" type="phase"
@@ -10,6 +12,8 @@
import {ElNotification} from "element-plus"; import {ElNotification} from "element-plus";
import {useProcessStore} from '@/stores/processStore.js'; import {useProcessStore} from '@/stores/processStore.js';
import {getPhaseDetail} from "@/api/project-manage"; import {getPhaseDetail} from "@/api/project-manage";
import {computed, ref} from "vue";
import {getBaseInfoApi} from "@/components/steps/api";
const route = useRoute() const route = useRoute()
const summaryData = ref({}) const summaryData = ref({})
@@ -19,6 +23,34 @@ const loading = ref(false)
const auditOpinion = ref('') const auditOpinion = ref('')
const copyName = ref('') const copyName = ref('')
const fileListShow = ref('READ') const fileListShow = ref('READ')
const schema = computed(() => {
return [
{
label: '征集名称',
prop: 'requirementName',
colProps: {
span: 12
}
},
{
label: '项目名称',
prop: 'projectName',
colProps: {
span: 12
}
}
]
})
const baseForm = ref()
const getBaseInfo = async () => {
try {
const {code, data} = await getBaseInfoApi(route.query.projectId)
baseForm.value.setValues(data)
} catch {
}
}
getBaseInfo()
const getInfo = async () => { const getInfo = async () => {
fileListShow.value = 'READ' fileListShow.value = 'READ'
const projectId = route.query.projectId const projectId = route.query.projectId

View File

@@ -25,26 +25,12 @@ const schema = computed(() => {
span: 12 span: 12
} }
}, },
{
label: '征集类型',
prop: 'collectType',
colProps: {
span: 12
}
},
{ {
label: '项目名称', label: '项目名称',
prop: 'projectName', prop: 'projectName',
colProps: { colProps: {
span: 12 span: 12
} }
},
{
label: '所属公司',
prop: 'affiliatedCompany',
colProps: {
span: 12
}
} }
] ]
}) })

View File

@@ -1,4 +1,6 @@
<template> <template>
<baseTitle title="基础信息"></baseTitle>
<fvForm :schema="schema" @getInstance="(e)=>baseForm = e"></fvForm>
<baseTitle title="标签名称"></baseTitle> <baseTitle title="标签名称"></baseTitle>
<el-form :model="formData" ref="tagForm" label-width="auto" :rules="rules"> <el-form :model="formData" ref="tagForm" label-width="auto" :rules="rules">
<el-form-item label="标签名称" prop="tagName"> <el-form-item label="标签名称" prop="tagName">
@@ -34,12 +36,33 @@ import {getTags} from "@/api/project-manage";
import {ElNotification} from "element-plus"; import {ElNotification} from "element-plus";
import {useTagsView} from '@/stores/tagsview.js' import {useTagsView} from '@/stores/tagsview.js'
import {uploadFileList} from "@/api/project-manage/attachment"; import {uploadFileList} from "@/api/project-manage/attachment";
import {computed, ref} from "vue";
import {getBaseInfoApi} from "@/components/steps/api";
const tagsViewStore = useTagsView() const tagsViewStore = useTagsView()
const route = useRoute() const route = useRoute()
const router = useRouter() const router = useRouter()
const fileList = ref([]) const fileList = ref([])
const showInput = ref(false) const showInput = ref(false)
const schema = computed(() => {
return [
{
label: '征集名称',
prop: 'requirementName',
colProps: {
span: 12
}
},
{
label: '项目名称',
prop: 'projectName',
colProps: {
span: 12
}
}
]
})
const baseForm = ref()
const tagsOption = ref([]) const tagsOption = ref([])
const formData = ref({ const formData = ref({
tagName: '' tagName: ''
@@ -88,6 +111,15 @@ const name = ref(router.currentRoute.value.name)
const rules = reactive({ const rules = reactive({
tagName: [{required: true, message: '请输入标签名称', trigger: ['blur', 'change']}], tagName: [{required: true, message: '请输入标签名称', trigger: ['blur', 'change']}],
}) })
const getBaseInfo = async () => {
try {
const {code, data} = await getBaseInfoApi(route.query.id)
baseForm.value.setValues(data)
} catch {
}
}
getBaseInfo()
const changeInput = () => { const changeInput = () => {
showInput.value = !showInput.value; showInput.value = !showInput.value;
formData.value.tagName = ''; formData.value.tagName = '';

View File

@@ -102,26 +102,12 @@ const schema = computed(() => {
span: 12 span: 12
} }
}, },
{
label: '征集类型',
prop: 'collectType',
colProps: {
span: 12
}
},
{ {
label: '项目名称', label: '项目名称',
prop: 'projectName', prop: 'projectName',
colProps: { colProps: {
span: 12 span: 12
} }
},
{
label: '所属公司',
prop: 'affiliatedCompany',
colProps: {
span: 12
}
} }
] ]
}) })