任务详情开启关闭规则

pull/110/head
Dragon 1 year ago
parent 7ff4a7324c
commit c1581d69a0

@ -28,9 +28,10 @@ const routes: Array<RouteRecordRaw> = [
children: [
{
path: 'final',
name: 'final-main',
name: 'FinalMain',
meta: {
title: '任务终审',
keepAlive: true,
},
component: () => import('@/views/final/index.vue'),
},

@ -5,6 +5,7 @@ import { getFilter } from '@/api/home/filter'
export interface ConfigState {
customConfig: string[] | null
asideValue: any
listKey: number
}
export const useFinalStore = defineStore({
@ -12,6 +13,7 @@ export const useFinalStore = defineStore({
state: (): ConfigState => ({
customConfig: null,
asideValue: null,
listKey: 0,
}),
getters: {
getCustomConfig(): string[] | null {
@ -25,6 +27,9 @@ export const useFinalStore = defineStore({
setAsideValue(value) {
this.asideValue = value
},
setListKey() {
this.listKey = new Date().getTime()
},
// 获取终审个性化配置
async fetchCustomConfig() {
const res = await getFilter(1)

@ -824,6 +824,13 @@ watch(
{ deep: true },
)
watch(
() => finalStore.listKey,
(newVal, oldVal) => {
refreshHandler()
},
)
function reset() {
pagination.page = 1
pagination.pageCount = 1

@ -4,25 +4,26 @@ import Aside from './aside/Aside.vue'
import Content from './content/Content.vue'
import ListContent from './content/ListContent.vue'
const showList = ref(false);
const contentRef:any = ref(null);
const inputChange = (keyword)=>{
defineOptions({
name: 'FinalMain',
})
const showList = ref(false)
const contentRef: any = ref(null)
function inputChange(keyword) {
contentRef.value.filterTableData(keyword)
}
</script>
<template>
<div class="main">
<!-- 侧边 -->
<Aside @inputChange="inputChange" />
<Aside @input-change="inputChange" />
<!-- 内容 -->
<Content @changeShow="showList=true" ref="contentRef" v-show="!showList" />
<Content v-show="!showList" ref="contentRef" @change-show="showList = true" />
<!-- 任务管理 -->
<!-- TODO:本地演示即可 上传注释注释 -->
<ListContent v-show="showList" @changeShow="showList=false" />
<ListContent v-show="showList" @change-show="showList = false" />
</div>
</template>

@ -11,6 +11,7 @@ import History from './History.vue'
import NotPassed from '@/components/Approval/NotPassed.vue'
import { getAllfieldList, getfieldList } from '@/api/home/filter'
import { TASK_STATUS_OBJ } from '@/enums/index'
import { useFinal } from '@/store/modules/final'
import {
audit,
@ -41,6 +42,7 @@ const CustomSettingModalRef = ref(null)
const taskTableData = ref<any[]>([])
const route = useRoute()
const isDetail = ref(false) //
const finalStore = useFinal()
const sortBy: any = {
orderType: 'desc',
orderName: 'similarityScore',
@ -366,7 +368,7 @@ function reloadList(param, text) {
//
const id = currentTaskId()
const hasCurrentId = param.flowTaskInfoList.find(item => item.formId === id)
finalStore.setListKey()
if (hasCurrentId)
emit('setAsideItemName', text)

Loading…
Cancel
Save