Merge branch 'dev' of gitee.com:yudaocode/yudao-ui-admin-vue3 into dev

Signed-off-by: puhui999 <puhui999@163.com>
This commit is contained in:
puhui999 2023-04-08 05:22:26 +00:00 committed by Gitee
commit b2a91aa1c8
64 changed files with 239 additions and 169 deletions

View File

@ -116,7 +116,7 @@ const remainingRouter: AppRouteRecordRaw[] = [
{
path: 'type/data/:dictType',
component: () => import('@/views/system/dict/data/index.vue'),
name: 'data',
name: 'SystemDictData',
meta: {
title: '字典数据',
noCache: true,
@ -140,7 +140,7 @@ const remainingRouter: AppRouteRecordRaw[] = [
{
path: 'edit',
component: () => import('@/views/infra/codegen/EditTable.vue'),
name: 'EditTable',
name: 'InfraCodegenEditTable',
meta: {
noCache: true,
hidden: true,
@ -163,7 +163,7 @@ const remainingRouter: AppRouteRecordRaw[] = [
{
path: 'job-log',
component: () => import('@/views/infra/job/logger/index.vue'),
name: 'JobLog',
name: 'InfraJobLog',
meta: {
noCache: true,
hidden: true,
@ -236,7 +236,7 @@ const remainingRouter: AppRouteRecordRaw[] = [
{
path: '/manager/form/edit',
component: () => import('@/views/bpm/form/editor/index.vue'),
name: 'bpmFormEditor',
name: 'BpmFormEditor',
meta: {
noCache: true,
hidden: true,
@ -248,7 +248,7 @@ const remainingRouter: AppRouteRecordRaw[] = [
{
path: '/manager/model/edit',
component: () => import('@/views/bpm/model/editor/index.vue'),
name: 'modelEditor',
name: 'BpmModelEditor',
meta: {
noCache: true,
hidden: true,
@ -260,7 +260,7 @@ const remainingRouter: AppRouteRecordRaw[] = [
{
path: '/manager/definition',
component: () => import('@/views/bpm/definition/index.vue'),
name: 'BpmProcessDefinitionList',
name: 'BpmProcessDefinition',
meta: {
noCache: true,
hidden: true,
@ -272,7 +272,7 @@ const remainingRouter: AppRouteRecordRaw[] = [
{
path: '/manager/task-assign-rule',
component: () => import('@/views/bpm/taskAssignRule/index.vue'),
name: 'BpmTaskAssignRuleList',
name: 'BpmTaskAssignRule',
meta: {
noCache: true,
hidden: true,
@ -315,30 +315,6 @@ const remainingRouter: AppRouteRecordRaw[] = [
title: '发起 OA 请假',
activeMenu: 'bpm/oa/leave/create'
}
},
{
path: '/bpm/task/todo',
component: () => import('@/views/bpm/task/todo/index.vue'),
name: 'TaskTodo',
meta: {
noCache: true,
hidden: true,
canTo: true,
title: '代办任务',
activeMenu: 'bpm/task/todo/index'
}
},
{
path: '/bpm/processInstance',
component: () => import('@/views/bpm/processInstance/index.vue'),
name: 'processInstance',
meta: {
noCache: true,
hidden: true,
canTo: true,
title: '流程办理',
activeMenu: 'bpm/processInstance/index'
}
}
]
},
@ -353,7 +329,7 @@ const remainingRouter: AppRouteRecordRaw[] = [
{
path: 'value/:propertyId(\\d+)',
component: () => import('@/views/mall/product/property/value/index.vue'),
name: 'PropertyValue',
name: 'ProductPropertyValue',
meta: { title: '商品属性值', icon: '', activeMenu: '/product/property' }
}
]

View File

@ -55,10 +55,14 @@ declare module '@vue/runtime-core' {
ElIcon: typeof import('element-plus/es')['ElIcon']
ElImageViewer: typeof import('element-plus/es')['ElImageViewer']
ElInput: typeof import('element-plus/es')['ElInput']
ElInputNumber: typeof import('element-plus/es')['ElInputNumber']
ElLink: typeof import('element-plus/es')['ElLink']
ElOption: typeof import('element-plus/es')['ElOption']
ElPagination: typeof import('element-plus/es')['ElPagination']
ElPopover: typeof import('element-plus/es')['ElPopover']
ElRadio: typeof import('element-plus/es')['ElRadio']
ElRadioButton: typeof import('element-plus/es')['ElRadioButton']
ElRadioGroup: typeof import('element-plus/es')['ElRadioGroup']
ElRow: typeof import('element-plus/es')['ElRow']
ElScrollbar: typeof import('element-plus/es')['ElScrollbar']
ElSelect: typeof import('element-plus/es')['ElSelect']

View File

@ -93,7 +93,7 @@
</Dialog>
</template>
<script setup lang="ts" name="Form">
<script setup lang="ts" name="BpmProcessDefinition">
import { DICT_TYPE } from '@/utils/dict'
import { dateFormatter } from '@/utils/formatTime'
import * as DefinitionApi from '@/api/bpm/definition'

View File

@ -83,12 +83,11 @@
</Dialog>
</template>
<script setup lang="ts" name="Form">
<script setup lang="ts" name="BpmForm">
import { DICT_TYPE } from '@/utils/dict'
import { dateFormatter } from '@/utils/formatTime'
import * as FormApi from '@/api/bpm/form'
import { setConfAndFields2 } from '@/utils/formCreate'
const message = useMessage() //
const { t } = useI18n() //
const { push } = useRouter() //
@ -130,7 +129,7 @@ const resetQuery = () => {
/** 添加/修改操作 */
const openForm = (id?: number) => {
push({
name: 'bpmFormEditor',
name: 'BpmFormEditor',
query: {
id
}

View File

@ -111,7 +111,7 @@
<UserGroupForm ref="formRef" @success="getList" />
</template>
<script setup lang="ts" name="UserGroup">
<script setup lang="ts" name="BpmUserGroup">
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
import { dateFormatter } from '@/utils/formatTime'
import * as UserGroupApi from '@/api/bpm/userGroup'

View File

@ -24,7 +24,7 @@
</ContentWrap>
</template>
<script setup lang="ts">
<script setup lang="ts" name="BpmModelEditor">
//
import CustomContentPadProvider from '@/components/bpmnProcessDesigner/package/designer/plugins/content-pad'
//

View File

@ -224,7 +224,7 @@
</Dialog>
</template>
<script setup lang="ts" name="Form">
<script setup lang="ts" name="BpmModel">
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
import { dateFormatter, formatDate } from '@/utils/formatTime'
import * as ModelApi from '@/api/bpm/model'
@ -319,7 +319,7 @@ const handleChangeState = async (row) => {
/** 设计流程 */
const handleDesign = (row) => {
push({
name: 'modelEditor',
name: 'BpmModelEditor',
query: {
modelId: row.id
}
@ -352,7 +352,7 @@ const handleAssignRule = (row) => {
/** 跳转到指定流程定义列表 */
const handleDefinitionList = (row) => {
push({
name: 'BpmProcessDefinitionList',
name: 'BpmProcessDefinition',
query: {
key: row.key
}

View File

@ -46,7 +46,7 @@
<ProcessInstanceBpmnViewer :bpmn-xml="bpmnXML" />
</ContentWrap>
</template>
<script setup lang="ts">
<script setup lang="ts" name="BpmProcessInstanceCreate">
import { DICT_TYPE } from '@/utils/dict'
import * as DefinitionApi from '@/api/bpm/definition'
import * as ProcessInstanceApi from '@/api/bpm/processInstance'

View File

@ -96,7 +96,7 @@
<TaskUpdateAssigneeForm ref="taskUpdateAssigneeFormRef" @success="getDetail" />
</ContentWrap>
</template>
<script setup lang="ts">
<script setup lang="ts" name="BpmProcessInstanceDetail">
import { useUserStore } from '@/store/modules/user'
import { setConfAndFields2 } from '@/utils/formCreate'
import type { ApiAttrs } from '@form-create/element-ui/types/config'

View File

@ -81,7 +81,7 @@
v-hasPermi="['bpm:process-instance:query']"
@click="handleCreate"
>
发起流程
<Icon icon="ep:plus" class="mr-5px" /> 发起流程
</el-button>
</el-form-item>
</el-form>
@ -159,7 +159,7 @@
/>
</ContentWrap>
</template>
<script setup lang="ts">
<script setup lang="ts" name="BpmProcessInstance">
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
import { dateFormatter } from '@/utils/formatTime'
import { ElMessageBox } from 'element-plus'

View File

@ -74,7 +74,7 @@
<!-- 表单弹窗详情 -->
<TaskDetail ref="detailRef" @success="getList" />
</template>
<script setup lang="tsx">
<script setup lang="tsx" name="BpmTodoTask">
import { DICT_TYPE } from '@/utils/dict'
import { dateFormatter } from '@/utils/formatTime'
import * as TaskApi from '@/api/bpm/task'

View File

@ -71,7 +71,7 @@
</ContentWrap>
</template>
<script setup lang="tsx">
<script setup lang="tsx" name="BpmDoneTask">
import { dateFormatter } from '@/utils/formatTime'
const { push } = useRouter() //
import * as TaskApi from '@/api/bpm/task'

View File

@ -32,7 +32,7 @@
<!-- 添加/修改弹窗 -->
<TaskAssignRuleForm ref="formRef" @success="getList" />
</template>
<script setup lang="ts" name="TaskAssignRule">
<script setup lang="ts" name="BpmTaskAssignRule">
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
import * as TaskAssignRuleApi from '@/api/bpm/taskAssignRule'
import * as RoleApi from '@/api/system/role'

View File

@ -139,7 +139,7 @@
<!-- 表单弹窗详情 -->
<ApiAccessLogDetail ref="detailRef" />
</template>
<script setup lang="ts" name="ApiAccessLog">
<script setup lang="ts" name="InfraApiAccessLog">
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
import download from '@/utils/download'
import { formatDate } from '@/utils/formatTime'

View File

@ -158,14 +158,13 @@
<ApiErrorLogDetail ref="detailRef" />
</template>
<script setup lang="ts" name="ApiErrorLog">
<script setup lang="ts" name="InfraApiErrorLog">
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
import { dateFormatter } from '@/utils/formatTime'
import download from '@/utils/download'
import * as ApiErrorLogApi from '@/api/infra/apiErrorLog'
import ApiErrorLogDetail from './ApiErrorLogDetail.vue'
import { InfraApiErrorLogProcessStatusEnum } from '@/utils/constants'
const message = useMessage() //
const loading = ref(true) //

View File

@ -31,7 +31,7 @@
</div>
</Dialog>
</template>
<script setup lang="ts" name="Build">
<script setup lang="ts" name="InfraBuild">
import formCreate from '@form-create/element-ui'
import { useClipboard } from '@vueuse/core'
const { t } = useI18n() //

View File

@ -142,7 +142,7 @@
<!-- 弹窗预览代码 -->
<PreviewCode ref="previewRef" />
</template>
<script setup lang="ts" name="Codegen">
<script setup lang="ts" name="InfraCodegen">
import { dateFormatter } from '@/utils/formatTime'
import download from '@/utils/download'
import * as CodegenApi from '@/api/infra/codegen'

View File

@ -137,7 +137,7 @@
<!-- 表单弹窗添加/修改 -->
<ConfigForm ref="formRef" @success="getList" />
</template>
<script setup lang="ts" name="Config">
<script setup lang="ts" name="InfraConfig">
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
import { dateFormatter } from '@/utils/formatTime'
import download from '@/utils/download'

View File

@ -57,7 +57,7 @@
<!-- 表单弹窗添加/修改 -->
<DataSourceConfigForm ref="formRef" @success="getList" />
</template>
<script setup lang="ts" name="DataSourceConfig">
<script setup lang="ts" name="InfraDataSourceConfig">
import { dateFormatter } from '@/utils/formatTime'
import * as DataSourceConfigApi from '@/api/infra/dataSourceConfig'
import DataSourceConfigForm from './DataSourceConfigForm.vue'

View File

@ -2,46 +2,38 @@
<doc-alert title="数据库文档" url="https://doc.iocoder.cn/db-doc/" />
<ContentWrap title="数据库文档">
<!-- 操作工具栏 -->
<div class="mb-10px">
<XButton
type="primary"
preIcon="ep:download"
:title="t('action.export') + ' HTML'"
@click="handleExport('HTML')"
/>
<XButton
type="primary"
preIcon="ep:download"
:title="t('action.export') + ' Word'"
@click="handleExport('Word')"
/>
<XButton
type="primary"
preIcon="ep:download"
:title="t('action.export') + ' Markdown'"
@click="handleExport('Markdown')"
/>
<el-button type="primary" plain @click="handleExport('HTML')">
<Icon icon="ep:download" /> 导出 HTML
</el-button>
<el-button type="primary" plain @click="handleExport('Word')">
<Icon icon="ep:download" /> 导出 Word
</el-button>
<el-button type="primary" plain @click="handleExport('Markdown')">
<Icon icon="ep:download" /> 导出 Markdown
</el-button>
</div>
<IFrame v-if="!loding" v-loading="loding" :src="src" />
<IFrame v-if="!loading" v-loading="loading" :src="src" />
</ContentWrap>
</template>
<script setup lang="ts" name="DbDoc">
<script setup lang="ts" name="InfraDBDoc">
import download from '@/utils/download'
import * as DbDocApi from '@/api/infra/dbDoc'
const { t } = useI18n() //
const src = ref('')
const loding = ref(true)
const loading = ref(true) //
const src = ref('') // HTML
/** 页面加载 */
const init = async () => {
const res = await DbDocApi.exportHtml()
let blob = new Blob([res], { type: 'text/html' })
let blobUrl = window.URL.createObjectURL(blob)
src.value = blobUrl
loding.value = false
try {
const data = await DbDocApi.exportHtml()
const blob = new Blob([data], { type: 'text/html' })
src.value = window.URL.createObjectURL(blob)
} finally {
loading.value = false
}
}
/** 处理导出 */
const handleExport = async (type: string) => {
if (type === 'HTML') {
@ -57,6 +49,8 @@ const handleExport = async (type: string) => {
download.markdown(res, '数据库文档.md')
}
}
/** 初始化 */
onMounted(async () => {
await init()
})

View File

@ -3,10 +3,24 @@
<doc-alert title="多数据源(读写分离)" url="https://doc.iocoder.cn/dynamic-datasource/" />
<ContentWrap>
<IFrame :src="src" />
<IFrame v-if="!loading" :src="url" />
</ContentWrap>
</template>
<script setup lang="ts" name="Druid">
const BASE_URL = import.meta.env.VITE_BASE_URL
const src = ref(BASE_URL + '/druid/index.html')
<script setup lang="ts" name="InfraDruid">
import * as ConfigApi from '@/api/infra/config'
const loading = ref(true) //
const url = ref(import.meta.env.VITE_BASE_URL + '/druid/index.html')
/** 初始化 */
onMounted(async () => {
try {
const data = await ConfigApi.getConfigKey('url.druid')
if (data && data.length > 0) {
url.value = data
}
} finally {
loading.value = false
}
})
</script>

View File

@ -2,17 +2,19 @@
<Dialog title="上传文件" v-model="dialogVisible">
<el-upload
ref="uploadRef"
:limit="1"
accept=".jpg, .png, .gif"
:auto-upload="false"
drag
:headers="headers"
:action="url"
:data="data"
:disabled="formLoading"
:headers="uploadHeaders"
v-model:file-list="fileList"
drag
accept=".jpg, .png, .gif"
:limit="1"
:on-success="submitFormSuccess"
:on-exceed="handleExceed"
:on-error="submitFormError"
:on-change="handleFileChange"
:on-progress="handleFileUploadProgress"
:on-success="handleFileSuccess"
:auto-upload="false"
:disabled="formLoading"
>
<i class="el-icon-upload"></i>
<div class="el-upload__text"> 将文件拖到此处 <em>点击上传</em> </div>
@ -29,44 +31,47 @@
</Dialog>
</template>
<script setup lang="ts">
import { Dialog } from '@/components/Dialog'
import { getAccessToken } from '@/utils/auth'
import { getAccessToken, getTenantId } from '@/utils/auth'
const { t } = useI18n() //
const message = useMessage() //
const dialogVisible = ref(false) //
const dialogTitle = ref('') //
const formLoading = ref(false) // 12
const formLoading = ref(false) //
const url = import.meta.env.VITE_UPLOAD_URL
const headers = { Authorization: 'Bearer ' + getAccessToken() }
const uploadHeaders = ref() // Header
const fileList = ref([]) //
const data = ref({ path: '' })
const uploadRef = ref()
/** 打开弹窗 */
const open = async () => {
dialogVisible.value = true
resetForm()
}
defineExpose({ open }) // open
/** 提交表单 */
const emit = defineEmits(['success']) // success
/** 处理上传的文件发生变化 */
const handleFileChange = (file) => {
data.value.path = file.name
}
/** 处理文件上传中 */
const handleFileUploadProgress = () => {
formLoading.value = true //
}
/** 发起文件上传 */
/** 提交表单 */
const submitFileForm = () => {
if (fileList.value.length == 0) {
message.error('请上传文件')
return
}
//
uploadHeaders.value = {
Authorization: 'Bearer ' + getAccessToken(),
'tenant-id': getTenantId()
}
unref(uploadRef)?.submit()
}
/** 文件上传成功处理 */
const handleFileSuccess = () => {
const emit = defineEmits(['success']) // success
const submitFormSuccess = () => {
//
dialogVisible.value = false
formLoading.value = false
@ -75,4 +80,22 @@ const handleFileSuccess = () => {
message.success(t('common.createSuccess'))
emit('success')
}
/** 上传错误提示 */
const submitFormError = (): void => {
message.error('上传失败,请您重新上传!')
formLoading.value = false
}
/** 重置表单 */
const resetForm = () => {
//
formLoading.value = false
uploadRef.value?.clearFiles()
}
/** 文件数超出提示 */
const handleExceed = (): void => {
message.error('最多只能上传一个文件!')
}
</script>

View File

@ -1,9 +1,14 @@
<template>
<doc-alert title="上传下载" url="https://doc.iocoder.cn/file/"/>
<doc-alert title="上传下载" url="https://doc.iocoder.cn/file/" />
<!-- 搜索 -->
<ContentWrap>
<el-form class="-mb-15px" :model="queryParams" ref="queryFormRef" :inline="true">
<el-form
class="-mb-15px"
:model="queryParams"
ref="queryFormRef"
:inline="true"
label-width="68px"
>
<el-form-item label="文件路径" prop="path">
<el-input
v-model="queryParams.path"
@ -33,7 +38,7 @@
<el-form-item>
<el-button @click="handleQuery"><Icon icon="ep:search" class="mr-5px" /> 搜索</el-button>
<el-button @click="resetQuery"><Icon icon="ep:refresh" class="mr-5px" /> 重置</el-button>
<el-button type="primary" @click="openForm">
<el-button type="primary" plain @click="openForm">
<Icon icon="ep:upload" class="mr-5px" /> 上传文件
</el-button>
</el-form-item>
@ -86,11 +91,11 @@
<!-- 表单弹窗添加/修改 -->
<FileForm ref="formRef" @success="getList" />
</template>
<script setup lang="ts" name="Config">
<script setup lang="ts" name="InfraFile">
import { fileSizeFormatter } from '@/utils'
import { dateFormatter } from '@/utils/formatTime'
import * as FileApi from '@/api/infra/file'
import FileUploadForm from './FileForm.vue'
import FileForm from './FileForm.vue'
const message = useMessage() //
const { t } = useI18n() //

View File

@ -3,17 +3,29 @@
<!-- 搜索 -->
<ContentWrap>
<el-form class="-mb-15px" :model="queryParams" ref="queryFormRef" :inline="true">
<el-form
class="-mb-15px"
:model="queryParams"
ref="queryFormRef"
:inline="true"
label-width="68px"
>
<el-form-item label="配置名" prop="name">
<el-input
v-model="queryParams.name"
placeholder="请输入配置名"
clearable
@keyup.enter="handleQuery"
class="!w-240px"
/>
</el-form-item>
<el-form-item label="存储器" prop="storage">
<el-select v-model="queryParams.storage" placeholder="请选择存储器" clearable>
<el-select
v-model="queryParams.storage"
placeholder="请选择存储器"
clearable
class="!w-240px"
>
<el-option
v-for="dict in getIntDictOptions(DICT_TYPE.INFRA_FILE_STORAGE)"
:key="dict.value"
@ -30,6 +42,7 @@
start-placeholder="开始日期"
end-placeholder="结束日期"
:default-time="[new Date('1 00:00:00'), new Date('1 23:59:59')]"
class="!w-240px"
/>
</el-form-item>
<el-form-item>
@ -113,7 +126,7 @@
<!-- 表单弹窗添加/修改 -->
<FileConfigForm ref="formRef" @success="getList" />
</template>
<script setup lang="ts" name="Config">
<script setup lang="ts" name="InfraFileConfig">
import * as FileConfigApi from '@/api/infra/fileConfig'
import FileConfigForm from './FileConfigForm.vue'
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'

View File

@ -147,7 +147,7 @@
<!-- 表单弹窗查看 -->
<JobDetail ref="detailRef" />
</template>
<script setup lang="ts" name="Job">
<script setup lang="ts" name="InfraJob">
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
import { checkPermi } from '@/utils/permission'
import JobForm from './JobForm.vue'

View File

@ -121,7 +121,7 @@
<!-- 表单弹窗查看 -->
<JobLogDetail ref="detailRef" />
</template>
<script setup lang="ts" name="JobLog">
<script setup lang="ts" name="InfraJobLog">
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
import { formatDate } from '@/utils/formatTime'
import download from '@/utils/download'

View File

@ -63,7 +63,7 @@
</el-row>
</el-scrollbar>
</template>
<script setup lang="ts" name="Redis">
<script setup lang="ts" name="InfraRedis">
import * as echarts from 'echarts'
import * as RedisApi from '@/api/infra/redis'
import { RedisMonitorInfoVO } from '@/api/infra/redis/types'

View File

@ -1,10 +1,25 @@
<template>
<doc-alert title="服务监控" url="https://doc.iocoder.cn/server-monitor/" />
<ContentWrap>
<IFrame :src="src" />
<IFrame v-if="!loading" v-loading="loading" :src="src" />
</ContentWrap>
</template>
<script setup lang="ts" name="AdminServer">
const BASE_URL = import.meta.env.VITE_BASE_URL
const src = ref(BASE_URL + '/admin/applications')
<script setup lang="ts" name="InfraAdminServer">
import * as ConfigApi from '@/api/infra/config'
const loading = ref(true) //
const src = ref(import.meta.env.VITE_BASE_URL + '/admin/applications')
/** 初始化 */
onMounted(async () => {
try {
const data = await ConfigApi.getConfigKey('url.spring-boot-admin')
if (data && data.length > 0) {
src.value = data
}
} finally {
loading.value = false
}
})
</script>

View File

@ -1,9 +1,25 @@
<template>
<doc-alert title="服务监控" url="https://doc.iocoder.cn/server-monitor/" />
<ContentWrap>
<IFrame :src="src" />
<IFrame v-if="!loading" v-loading="loading" :src="src" />
</ContentWrap>
</template>
<script setup lang="ts" name="Skywalking">
<script setup lang="ts" name="InfraSkyWalking">
import * as ConfigApi from '@/api/infra/config'
const loading = ref(true) //
const src = ref('http://skywalking.shop.iocoder.cn')
/** 初始化 */
onMounted(async () => {
try {
const data = await ConfigApi.getConfigKey('url.skywalking')
if (data && data.length > 0) {
src.value = data
}
} finally {
loading.value = false
}
})
</script>

View File

@ -5,8 +5,22 @@
<IFrame :src="src" />
</ContentWrap>
</template>
<script setup lang="ts" name="Swagger">
const BASE_URL = import.meta.env.VITE_BASE_URL
// const src = ref(BASE_URL + '/doc.html')
const src = ref(BASE_URL + '/swagger-ui')
<script setup lang="ts" name="InfraSwagger">
import * as ConfigApi from '@/api/infra/config'
const loading = ref(true) //
const src = ref(import.meta.env.VITE_BASE_URL + '/doc.html') // Knife4j UI
// const src = ref(import.meta.env.VITE_BASE_URL + '/swagger-ui') // Swagger UI
/** 初始化 */
onMounted(async () => {
try {
const data = await ConfigApi.getConfigKey('url.swagger')
if (data && data.length > 0) {
src.value = data
}
} finally {
loading.value = false
}
})
</script>

View File

@ -50,7 +50,7 @@
</template>
</Dialog>
</template>
<script setup lang="ts">
<script setup lang="ts" name="ProductCategory">
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
import { CommonStatusEnum } from '@/utils/constants'
import { handleTree } from '@/utils/tree'

View File

@ -92,7 +92,7 @@
<!-- 表单弹窗添加/修改 -->
<PropertyForm ref="formRef" @success="getList" />
</template>
<script setup lang="ts" name="Config">
<script setup lang="ts" name="ProductProperty">
import { dateFormatter } from '@/utils/formatTime'
import * as PropertyApi from '@/api/mall/product/property'
import PropertyForm from './PropertyForm.vue'

View File

@ -88,7 +88,7 @@
<!-- 表单弹窗添加/修改 -->
<ValueForm ref="formRef" @success="getList" />
</template>
<script setup lang="ts" name="Config">
<script setup lang="ts" name="ProductPropertyValue">
import { dateFormatter } from '@/utils/formatTime'
import * as PropertyApi from '@/api/mall/product/property'
import ValueForm from './ValueForm.vue'

View File

@ -59,7 +59,7 @@
</ContentWrap>
</template>
<script setup lang="ts" name="freePublish">
<script setup lang="ts" name="MpFreePublish">
import * as FreePublishApi from '@/api/mp/freePublish'
import * as MpAccountApi from '@/api/mp/account'
import WxNews from '@/views/mp/components/wx-news/main.vue'

View File

@ -75,7 +75,7 @@
</template>
</XModal>
</template>
<script setup lang="ts" name="App">
<script setup lang="ts" name="PayApp">
import type { FormExpose } from '@/components/Form'
import { rules, allSchemas } from './app.data'
import * as AppApi from '@/api/pay/app'

View File

@ -137,7 +137,7 @@
<!-- 表单弹窗添加/修改 -->
<MerchantForm ref="formRef" @success="getList" />
</template>
<script setup lang="ts" name="Merchant">
<script setup lang="ts" name="PayMerchant">
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
import { CommonStatusEnum } from '@/utils/constants'
import { dateFormatter } from '@/utils/formatTime'

View File

@ -41,7 +41,7 @@
</template>
</XModal>
</template>
<script setup lang="ts" name="Order">
<script setup lang="ts" name="PayOrder">
import { allSchemas } from './order.data'
import * as OrderApi from '@/api/pay/order'

View File

@ -33,7 +33,7 @@
</template>
</XModal>
</template>
<script setup lang="ts" name="Refund">
<script setup lang="ts" name="PayRefund">
import { allSchemas } from './refund.data'
import * as RefundApi from '@/api/pay/refund'

View File

@ -30,7 +30,7 @@
<!-- 表单弹窗添加/修改 -->
<AreaForm ref="formRef" />
</template>
<script setup lang="tsx" name="Area">
<script setup lang="tsx" name="SystemArea">
import type { Column } from 'element-plus'
import AreaForm from './AreaForm.vue'
import * as AreaApi from '@/api/system/area'

View File

@ -103,7 +103,7 @@
<!-- 表单弹窗添加/修改 -->
<DeptForm ref="formRef" @success="getList" />
</template>
<script setup lang="ts" name="Dept">
<script setup lang="ts" name="SystemDept">
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
import { dateFormatter } from '@/utils/formatTime'
import { handleTree } from '@/utils/tree'

View File

@ -115,7 +115,7 @@
<!-- 表单弹窗添加/修改 -->
<DictDataForm ref="formRef" @success="getList" />
</template>
<script setup lang="ts" name="DictData">
<script setup lang="ts" name="SystemDictData">
import { getIntDictOptions, DICT_TYPE } from '@/utils/dict'
import { dateFormatter } from '@/utils/formatTime'
import download from '@/utils/download'

View File

@ -132,7 +132,7 @@
<DictTypeForm ref="formRef" @success="getList" />
</template>
<script setup lang="ts" name="DictType">
<script setup lang="ts" name="SystemDictType">
import { getIntDictOptions, DICT_TYPE } from '@/utils/dict'
import { dateFormatter } from '@/utils/formatTime'
import * as DictTypeApi from '@/api/system/dict/dict.type'

View File

@ -137,7 +137,7 @@
<ErrorCodeForm ref="formRef" @success="getList" />
</template>
<script setup lang="ts" name="ErrorCode">
<script setup lang="ts" name="SystemErrorCode">
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
import { dateFormatter } from '@/utils/formatTime'
import download from '@/utils/download'

View File

@ -104,7 +104,7 @@
<!-- 表单弹窗详情 -->
<LoginLogDetail ref="detailRef" />
</template>
<script setup lang="ts" name="LoginLog">
<script setup lang="ts" name="SystemLoginLog">
import { DICT_TYPE } from '@/utils/dict'
import { dateFormatter } from '@/utils/formatTime'
import download from '@/utils/download'

View File

@ -64,7 +64,7 @@
<!-- 详情弹窗 -->
<MailAccountDetail ref="detailRef" />
</template>
<script setup lang="ts" name="MailAccount">
<script setup lang="ts" name="SystemMailAccount">
import { allSchemas } from './account.data'
import * as MailAccountApi from '@/api/system/mail/account'
import MailAccountForm from './MailAccountForm.vue'

View File

@ -34,7 +34,7 @@
<!-- 表单弹窗详情 -->
<mail-log-detail ref="detailRef" />
</template>
<script setup lang="ts" name="MailLog">
<script setup lang="ts" name="SystemMailLog">
import { allSchemas } from './log.data'
import * as MailLogApi from '@/api/system/mail/log'
import MailLogDetail from './MailLogDetail.vue'

View File

@ -65,7 +65,7 @@
<!-- 表单弹窗发送测试 -->
<MailTemplateSendForm ref="sendFormRef" />
</template>
<script setup lang="ts" name="MailTemplate">
<script setup lang="ts" name="SystemMailTemplate">
import { allSchemas } from './template.data'
import * as MailTemplateApi from '@/api/system/mail/template'
import MailTemplateForm from './MailTemplateForm.vue'

View File

@ -111,7 +111,7 @@
<!-- 表单弹窗添加/修改 -->
<MenuForm ref="formRef" @success="getList" />
</template>
<script setup lang="ts" name="Menu">
<script setup lang="ts" name="SystemMenu">
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
import { handleTree } from '@/utils/tree'
import * as MenuApi from '@/api/system/menu'

View File

@ -102,7 +102,7 @@
<!-- 表单弹窗添加/修改 -->
<NoticeForm ref="formRef" @success="getList" />
</template>
<script setup lang="tsx">
<script setup lang="tsx" name="SystemNotice">
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
import { dateFormatter } from '@/utils/formatTime'
import * as NoticeApi from '@/api/system/notice'

View File

@ -153,7 +153,7 @@
<!-- 表单弹窗详情 -->
<NotifyMessageDetail ref="detailRef" />
</template>
<script setup lang="ts" name="NotifyMessage">
<script setup lang="ts" name="SystemNotifyMessage">
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
import { dateFormatter } from '@/utils/formatTime'
import * as NotifyMessageApi from '@/api/system/notify/message'

View File

@ -115,7 +115,7 @@
<MyNotifyMessageDetail ref="detailRef" />
</template>
<script setup lang="ts" name="MyNotifyMessage">
<script setup lang="ts" name="SystemMyNotify">
import { DICT_TYPE, getBoolDictOptions } from '@/utils/dict'
import { dateFormatter } from '@/utils/formatTime'
import * as NotifyMessageApi from '@/api/system/notify/message'

View File

@ -114,7 +114,7 @@
</template>
</XModal>
</template>
<script setup lang="ts" name="NotifyTemplate">
<script setup lang="ts" name="SystemNotifyTemplate">
import { FormExpose } from '@/components/Form'
// import
import { rules, allSchemas } from './template.data'

View File

@ -119,7 +119,7 @@
<!-- 表单弹窗添加/修改 -->
<ClientForm ref="formRef" @success="getList" />
</template>
<script setup lang="ts">
<script setup lang="ts" name="SystemOAuth2Client">
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
import { dateFormatter } from '@/utils/formatTime'
import * as ClientApi from '@/api/system/oauth2/client'

View File

@ -98,7 +98,7 @@
</ContentWrap>
</template>
<script setup lang="ts" name="Oauth2AccessToken">
<script setup lang="ts" name="SystemTokenClient">
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
import { dateFormatter } from '@/utils/formatTime'
import * as OAuth2AccessTokenApi from '@/api/system/oauth2/token'

View File

@ -135,7 +135,7 @@
<!-- 表单弹窗详情 -->
<OperateLogDetail ref="detailRef" />
</template>
<script setup lang="ts" name="OperateLog">
<script setup lang="ts" name="SystemOperateLog">
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
import { dateFormatter } from '@/utils/formatTime'
import download from '@/utils/download'

View File

@ -111,13 +111,12 @@
<!-- 表单弹窗添加/修改 -->
<PostForm ref="formRef" @success="getList" />
</template>
<script setup lang="tsx">
<script setup lang="tsx" name="SystemPost">
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
import { dateFormatter } from '@/utils/formatTime'
import download from '@/utils/download'
import * as PostApi from '@/api/system/post'
import PostForm from './PostForm.vue'
const message = useMessage() //
const { t } = useI18n() //

View File

@ -152,7 +152,7 @@
<!-- 表单弹窗数据权限 -->
<RoleDataPermissionForm ref="dataPermissionFormRef" />
</template>
<script setup lang="tsx">
<script setup lang="tsx" name="SystemRole">
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
import { dateFormatter } from '@/utils/formatTime'
import download from '@/utils/download'

View File

@ -143,7 +143,7 @@
<!-- 表单弹窗测试敏感词 -->
<SensitiveWordTestForm ref="testFormRef" />
</template>
<script setup lang="ts" name="SensitiveWord">
<script setup lang="ts" name="SystemSensitiveWordhao">
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
import { dateFormatter } from '@/utils/formatTime'
import download from '@/utils/download'

View File

@ -129,7 +129,7 @@
<!-- 表单弹窗添加/修改 -->
<SmsChannelForm ref="formRef" @success="getList" />
</template>
<script setup lang="ts" name="SmsChannel">
<script setup lang="ts" name="SystemSmsChannel">
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
import { dateFormatter } from '@/utils/formatTime'
import * as SmsChannelApi from '@/api/system/sms/smsChannel'

View File

@ -184,7 +184,7 @@
<!-- 表单弹窗详情 -->
<SmsLogDetail ref="detailRef" />
</template>
<script setup lang="ts" name="smsLog">
<script setup lang="ts" name="SystemSmsLog">
import { DICT_TYPE, getIntDictOptions, getDictLabel } from '@/utils/dict'
import { dateFormatter, formatDate } from '@/utils/formatTime'
import download from '@/utils/download'

View File

@ -211,7 +211,7 @@
<!-- 表单弹窗测试发送 -->
<SmsTemplateSendForm ref="sendFormRef" />
</template>
<script setup lang="ts" name="SmsTemplate">
<script setup lang="ts" name="SystemSmsTemplate">
import { DICT_TYPE, getIntDictOptions, getDictLabel } from '@/utils/dict'
import { dateFormatter } from '@/utils/formatTime'
import * as SmsTemplateApi from '@/api/system/sms/smsTemplate'

View File

@ -171,14 +171,13 @@
<!-- 表单弹窗添加/修改 -->
<TenantForm ref="formRef" @success="getList" />
</template>
<script setup lang="ts" name="Tenant">
<script setup lang="ts" name="SystemTenant">
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
import { dateFormatter } from '@/utils/formatTime'
import download from '@/utils/download'
import * as TenantApi from '@/api/system/tenant'
import * as TenantPackageApi from '@/api/system/tenantPackage'
import TenantForm from './TenantForm.vue'
const message = useMessage() //
const { t } = useI18n() //

View File

@ -106,7 +106,7 @@
<!-- 表单弹窗添加/修改 -->
<TenantPackageForm ref="formRef" @success="getList" />
</template>
<script setup lang="ts" name="TenantPackage">
<script setup lang="ts" name="SystemTenantPackage">
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
import { dateFormatter } from '@/utils/formatTime'
import * as TenantPackageApi from '@/api/system/tenantPackage'

View File

@ -198,7 +198,7 @@
<!-- 分配角色 -->
<UserAssignRoleForm ref="assignRoleFormRef" @success="getList" />
</template>
<script setup lang="ts" name="User">
<script setup lang="ts" name="SystemUser">
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
import { checkPermi } from '@/utils/permission'
import { dateFormatter } from '@/utils/formatTime'