流程审批回到上一个标签页
This commit is contained in:
parent
36014b7536
commit
20358ba86b
@ -59,7 +59,7 @@ const open = async (id: string) => {
|
||||
defineExpose({ open }) // 提供 openModal 方法,用于打开弹窗
|
||||
|
||||
/** 提交表单 */
|
||||
const emit = defineEmits(['success']) // 定义 success 事件,用于操作成功后的回调
|
||||
const emit = defineEmits(['success','backView']) // 定义 success 事件,用于操作成功后的回调
|
||||
const submitForm = async () => {
|
||||
// 校验表单
|
||||
if (!formRef) return
|
||||
@ -72,6 +72,7 @@ const submitForm = async () => {
|
||||
dialogVisible.value = false
|
||||
// 发送操作成功的事件
|
||||
emit('success')
|
||||
emit('backView')
|
||||
} finally {
|
||||
formLoading.value = false
|
||||
}
|
||||
|
@ -59,7 +59,7 @@ const open = async (id: string) => {
|
||||
defineExpose({ open }) // 提供 openModal 方法,用于打开弹窗
|
||||
|
||||
/** 提交表单 */
|
||||
const emit = defineEmits(['success']) // 定义 success 事件,用于操作成功后的回调
|
||||
const emit = defineEmits(['success','backView']) // 定义 success 事件,用于操作成功后的回调
|
||||
const submitForm = async () => {
|
||||
// 校验表单
|
||||
if (!formRef) return
|
||||
@ -73,6 +73,7 @@ const submitForm = async () => {
|
||||
dialogVisible.value = false
|
||||
// 发送操作成功的事件
|
||||
emit('success')
|
||||
emit('backView')
|
||||
} finally {
|
||||
formLoading.value = false
|
||||
}
|
||||
|
@ -66,7 +66,7 @@ const open = async (id: string) => {
|
||||
defineExpose({ open }) // 提供 openModal 方法,用于打开弹窗
|
||||
|
||||
/** 提交表单 */
|
||||
const emit = defineEmits(['success']) // 定义 success 事件,用于操作成功后的回调
|
||||
const emit = defineEmits(['success','backView']) // 定义 success 事件,用于操作成功后的回调
|
||||
const submitForm = async (type: string) => {
|
||||
// 校验表单
|
||||
if (!formRef) return
|
||||
@ -81,6 +81,7 @@ const submitForm = async (type: string) => {
|
||||
dialogVisible.value = false
|
||||
// 发送操作成功的事件
|
||||
emit('success')
|
||||
emit('backView')
|
||||
} finally {
|
||||
formLoading.value = false
|
||||
}
|
||||
|
@ -59,7 +59,7 @@ const open = async (id: string) => {
|
||||
defineExpose({ open }) // 提供 openModal 方法,用于打开弹窗
|
||||
|
||||
/** 提交表单 */
|
||||
const emit = defineEmits(['success']) // 定义 success 事件,用于操作成功后的回调
|
||||
const emit = defineEmits(['success','backView']) // 定义 success 事件,用于操作成功后的回调
|
||||
const submitForm = async () => {
|
||||
// 校验表单
|
||||
if (!formRef) return
|
||||
@ -72,6 +72,7 @@ const submitForm = async () => {
|
||||
dialogVisible.value = false
|
||||
// 发送操作成功的事件
|
||||
emit('success')
|
||||
emit('backView')
|
||||
} finally {
|
||||
formLoading.value = false
|
||||
}
|
||||
|
@ -131,13 +131,13 @@
|
||||
</el-tab-pane>
|
||||
</el-tabs>
|
||||
<!-- 弹窗:转派审批人 -->
|
||||
<TaskTransferForm ref="taskTransferFormRef" @success="getDetail" />
|
||||
<TaskTransferForm ref="taskTransferFormRef" @success="getDetail" @back-view="backView" />
|
||||
<!-- 弹窗:回退节点 -->
|
||||
<TaskReturnForm ref="taskReturnFormRef" @success="getDetail" />
|
||||
<TaskReturnForm ref="taskReturnFormRef" @success="getDetail" @back-view="backView" />
|
||||
<!-- 弹窗:委派,将任务委派给别人处理,处理完成后,会重新回到原审批人手中-->
|
||||
<TaskDelegateForm ref="taskDelegateForm" @success="getDetail" />
|
||||
<TaskDelegateForm ref="taskDelegateForm" @success="getDetail" @back-view="backView" />
|
||||
<!-- 弹窗:加签,当前任务审批人为A,向前加签选了一个C,则需要C先审批,然后再是A审批,向后加签B,A审批完,需要B再审批完,才算完成这个任务节点 -->
|
||||
<TaskSignCreateForm ref="taskSignCreateFormRef" @success="getDetail" />
|
||||
<TaskSignCreateForm ref="taskSignCreateFormRef" @success="getDetail" @back-view="backView" />
|
||||
</ContentWrap>
|
||||
</template>
|
||||
<script lang="ts" setup>
|
||||
@ -158,8 +158,7 @@ import { isEmpty } from '@/utils/is'
|
||||
import * as UserApi from '@/api/system/user'
|
||||
import {TabsPaneContext} from "element-plus";
|
||||
import { FormProcessMappingApi} from '@/api/bpm/formprocessmapping'
|
||||
// import {useRouter} from "vue-router";
|
||||
// const {push} = useRouter()
|
||||
import {useTagsViewStore} from "@/store/modules/tagsView";
|
||||
|
||||
defineOptions({ name: 'BpmProcessInstanceDetail' })
|
||||
|
||||
@ -167,6 +166,8 @@ const { query } = useRoute() // 查询参数
|
||||
const message = useMessage() // 消息弹窗
|
||||
const { proxy } = getCurrentInstance() as any
|
||||
|
||||
const { delView } = useTagsViewStore()//视图操作
|
||||
const { currentRoute, back } = useRouter()
|
||||
const userId = useUserStore().getUser.id // 当前登录的编号
|
||||
const id = query.id as unknown as string // 流程实例的编号
|
||||
const processInstanceLoading = ref(false) // 流程实例的加载中
|
||||
@ -244,6 +245,13 @@ const handleAudit = async (task, pass) => {
|
||||
}
|
||||
// 2.2 加载最新数据
|
||||
getDetail()
|
||||
delView(unref(currentRoute))
|
||||
back()
|
||||
}
|
||||
//关闭当前标签回到上个标签
|
||||
const backView = ()=>{
|
||||
delView(unref(currentRoute))
|
||||
back()
|
||||
}
|
||||
|
||||
/** 转派审批人 */
|
||||
|
Loading…
Reference in New Issue
Block a user