会议管理新版

This commit is contained in:
XaoLi717 2024-11-27 14:46:27 +08:00
parent 25d5d4ff86
commit 58af80edd2
2 changed files with 25 additions and 1 deletions

View File

@ -4,6 +4,8 @@ import request from '@/config/axios'
export interface HyglVO {
id: number // id
title: string // 会议标题
curfullpath: string // 申请用户名称
processDefinitionKey: string // 申请用户名称
userName: string // 申请人名字
userId: number // 申请人id
deptName: string // 申请部门名字

View File

@ -164,6 +164,7 @@
import * as UserApi from '@/api/system/user'
import {useTagsViewStore} from "@/store/modules/tagsView";
import {HysglApi, HysglVO} from "@/api/home/hysgl";
import {FormProcessMappingApi} from "@/api/bpm/formprocessmapping";
/** 会议管理 表单 */
defineOptions({ name: 'HyglCreate' })
@ -228,7 +229,7 @@
//
const { delView } = useTagsViewStore()//
const { push, currentRoute } = useRouter()
const processDefineKey = 'hygl-001' // Key
/* const processDefineKey = 'hygl-001' 流程定义 Key*/
const startUserSelectTasks = ref([]) //
const startUserSelectAssignees = ref({}) //
const startUserSelectAssigneesFormRef = ref() // Ref
@ -277,6 +278,17 @@
if(startUserSelectTasks.value?.length > 0){
data.startUserSelectAssignees = startUserSelectAssignees.value
}
const curFullPath = currentRoute.value.fullPath
if( curFullPath ) {
data.curfullpath = curFullPath
}
const processKey = await FormProcessMappingApi.selectProcessKey( curFullPath )
if ( processKey) {
data.processDefinitionKey = processKey
}
await HyglApi.createHygl(data)
message.success(t('common.createSuccess'))
delView(unref(currentRoute))
@ -316,6 +328,16 @@
onMounted(async () => {
await getUserInfo()
await getList()
const curFullPath = currentRoute.value.fullPath
const processKey = await FormProcessMappingApi.selectProcessKey( curFullPath )
if ( !processKey ) {
message.error('流程对应表单模型未配置,请检查!')
return
}
const processDefinitionDetail = await DefinitionApi.getProcessDefinition(
undefined,
processDefineKey