refactor: 将枚举和常量从utils移动到constants

pull/209/head
xingyu4j 2025-09-04 18:28:13 +08:00
parent 37fba1474e
commit cf8745d844
7 changed files with 12 additions and 7 deletions

View File

@ -1,5 +1,8 @@
import type {
BpmCandidateStrategyEnum,
BpmNodeTypeEnum,
} from '@vben/constants';
import type { PageParam, PageResult } from '@vben/request';
import type { BpmCandidateStrategyEnum, BpmNodeTypeEnum } from '@vben/utils';
import type { BpmTaskApi } from '../task';

View File

@ -4,8 +4,8 @@ import type { AiWriteApi } from '#/api/ai/write';
import { ref } from 'vue';
import { AiWriteTypeEnum, WriteExample } from '@vben/constants';
import { IconifyIcon } from '@vben/icons';
import { AiWriteTypeEnum, WriteExample } from '@vben/utils';
import { createReusableTemplate } from '@vueuse/core';
import { Button, message, Textarea } from 'ant-design-vue';

View File

@ -5,8 +5,8 @@ import type { BpmFormApi } from '#/api/bpm/form';
import { ref, watch } from 'vue';
import { BpmModelFormType } from '@vben/constants';
import { CircleHelp } from '@vben/icons';
import { BpmModelFormType } from '@vben/utils';
import FormCreate from '@form-create/ant-design-vue';
import {

View File

@ -3,7 +3,7 @@ import type { Ref } from 'vue';
import { computed, inject, nextTick, ref } from 'vue';
import { BpmModelType } from '@vben/utils';
import { BpmModelType } from '@vben/constants';
// TODO BPM BpmModelEditor
import SimpleModelDesign from './simple-model-design.vue';

View File

@ -155,7 +155,7 @@ const [Grid, gridApi] = useVbenVxeGrid({
</template>
<template #file-content="{ row }">
<Image v-if="row.type && row.type.includes('image')" :src="row.url" />
<Button v-else type="link" @click="() => openWindow(row.url)">
<Button v-else type="link" @click="() => openWindow(row.url!)">
{{ row.type && row.type.includes('pdf') ? '预览' : '下载' }}
</Button>
</template>

View File

@ -4,7 +4,8 @@ import type { InfraApiAccessLogApi } from '#/api/infra/api-access-log';
import { ref } from 'vue';
import { useVbenModal } from '@vben/common-ui';
import { DICT_TYPE, formatDateTime } from '@vben/utils';
import { DICT_TYPE } from '@vben/constants';
import { formatDateTime } from '@vben/utils';
import { ElDescriptions, ElDescriptionsItem } from 'element-plus';

View File

@ -4,8 +4,9 @@ import type { EchartsUIType } from '@vben/plugins/echarts';
import { onMounted, reactive, ref } from 'vue';
import { AnalysisChartCard } from '@vben/common-ui';
import { TimeRangeTypeEnum } from '@vben/constants';
import { EchartsUI, useEcharts } from '@vben/plugins/echarts';
import { fenToYuan, formatDate, TimeRangeTypeEnum } from '@vben/utils';
import { fenToYuan, formatDate } from '@vben/utils';
import dayjs, { Dayjs } from 'dayjs';