修改 查看详情 返回页面刷新

This commit is contained in:
GGJ
2024-06-04 18:06:17 +08:00
parent eb62676b5d
commit 9ee495f40d
13 changed files with 404 additions and 278 deletions

View File

@@ -53,9 +53,10 @@ const adminInfo = useAdminInfo()
defineOptions({
name: 'plan'
})
const flag = ref(false)
// const layout = mainHeight(120) as any
const dictData = useDictData()
const { push } = useRouter()
const { push, options, currentRoute } = useRouter()
const router = useRouter() // 路由对象
const TableHeaderRef = ref()
const tableRef = ref()
@@ -172,6 +173,7 @@ const tableStore = new TableStore({
icon: 'el-icon-EditPen',
render: 'basicButton',
click: row => {
flag.value = true
handleDetails(row.processInstanceId, row.historyInstanceId)
},
disabled: row => {
@@ -208,9 +210,7 @@ const tableStore = new TableStore({
icon: 'el-icon-Open',
render: 'basicButton',
disabled: row => {
return (
row.createBy != adminInfo.$state.id || row.status !=3
)
return row.createBy != adminInfo.$state.id || row.status != 3
},
click: row => {
addForms.value.open({
@@ -226,9 +226,7 @@ const tableStore = new TableStore({
icon: 'el-icon-Open',
render: 'basicButton',
disabled: row => {
return (
row.createBy != adminInfo.$state.id || row.status != 1
)
return row.createBy != adminInfo.$state.id || row.status != 1
},
click: row => {
cancelLeave(row)
@@ -359,4 +357,16 @@ const handleEffectProblem = (row: any) => {
}
})
}
watch(
() => currentRoute.value.path,
() => {
if (flag.value && options.history.state.forward?.split('/')[1] == 'bpm') {
tableStore.index()
flag.value = false
}
},
{
deep: true
}
)
</script>