mirror of
https://gitee.com/dapppp/ruoyi-plus-vben5.git
synced 2025-12-30 09:42:25 +00:00
refactor: 调整命名
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
动态渲染要显示的内容 需要再flowDescripionsMap先定义好组件
|
||||
-->
|
||||
<script setup lang="ts">
|
||||
import type { DescripionsMapKey } from '../register';
|
||||
import type { FlowComponentsMapMapKey } from '../register';
|
||||
|
||||
import type { FlowInfoResponse } from '#/api/workflow/instance/model';
|
||||
import type { TaskInfo } from '#/api/workflow/task/model';
|
||||
@@ -11,7 +11,7 @@ import type { TaskInfo } from '#/api/workflow/task/model';
|
||||
import { Divider } from 'ant-design-vue';
|
||||
|
||||
import { ApprovalTimeline } from '.';
|
||||
import { flowDescripionsMap } from '../register';
|
||||
import { flowComponentsMap } from '../register';
|
||||
|
||||
defineOptions({
|
||||
name: 'ApprovalDetails',
|
||||
@@ -33,7 +33,7 @@ defineProps<{
|
||||
business-id为业务ID 必传
|
||||
-->
|
||||
<component
|
||||
:is="flowDescripionsMap[task.formPath as DescripionsMapKey]"
|
||||
:is="flowComponentsMap[task.formPath as FlowComponentsMapMapKey]"
|
||||
:business-id="task.businessId"
|
||||
/>
|
||||
<Divider />
|
||||
|
||||
@@ -11,11 +11,11 @@ const LeaveDescription = defineAsyncComponent(
|
||||
/**
|
||||
* key为流程的路径(task.formPath) value为要显示的组件
|
||||
*/
|
||||
export const flowDescripionsMap = {
|
||||
export const flowComponentsMap = {
|
||||
/**
|
||||
* 请假申请 详情
|
||||
*/
|
||||
'/workflow/leaveEdit/index': markRaw(LeaveDescription),
|
||||
};
|
||||
|
||||
export type DescripionsMapKey = keyof typeof flowDescripionsMap;
|
||||
export type FlowComponentsMapMapKey = keyof typeof flowComponentsMap;
|
||||
|
||||
Reference in New Issue
Block a user