From 1f9be6227c8e959d849a273c703cb5b8bf46e722 Mon Sep 17 00:00:00 2001 From: qsh <> Date: Mon, 27 May 2024 15:58:17 +0800 Subject: [PATCH] =?UTF-8?q?=E8=81=94=E8=B0=83?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/infra/config/index.ts | 48 +++++++++++++++++++ src/components/IFrame/src/IFrame.vue | 2 +- src/layout/components/Logo/src/Logo.vue | 4 +- src/permission.js | 2 +- src/router/modules/remaining.ts | 13 +++++ src/store/modules/user.ts | 23 +-------- src/utils/formatTime.ts | 2 +- src/views/Basic/Dept/index.vue | 26 ++++++++-- src/views/Basic/GeneralSet/index.vue | 5 +- src/views/Basic/Role/RoleAssignMenuForm.vue | 8 +++- .../Basic/Role/RoleDataPermissionForm.vue | 8 +++- src/views/Basic/Role/index.vue | 12 ++++- src/views/Basic/Swagger/index.vue | 24 ++++++++++ src/views/Basic/User/index.vue | 39 ++++++++++++--- 14 files changed, 173 insertions(+), 43 deletions(-) create mode 100644 src/api/infra/config/index.ts create mode 100644 src/views/Basic/Swagger/index.vue diff --git a/src/api/infra/config/index.ts b/src/api/infra/config/index.ts new file mode 100644 index 0000000..bbee3b3 --- /dev/null +++ b/src/api/infra/config/index.ts @@ -0,0 +1,48 @@ +import request from '@/config/axios' + +export interface ConfigVO { + id: number | undefined + category: string + name: string + key: string + value: string + type: number + visible: boolean + remark: string + createTime: Date +} + +// 查询参数列表 +export const getConfigPage = (params: PageParam) => { + return request.get({ url: '/admin-api/infra/config/page', params }) +} + +// 查询参数详情 +export const getConfig = (id: number) => { + return request.get({ url: '/admin-api/infra/config/get?id=' + id }) +} + +// 根据参数键名查询参数值 +export const getConfigKey = (configKey: string) => { + return request.get({ url: '/admin-api/infra/config/get-value-by-key?key=' + configKey }) +} + +// 新增参数 +export const createConfig = (data: ConfigVO) => { + return request.post({ url: '/admin-api/infra/config/create', data }) +} + +// 修改参数 +export const updateConfig = (data: ConfigVO) => { + return request.put({ url: '/admin-api/infra/config/update', data }) +} + +// 删除参数 +export const deleteConfig = (id: number) => { + return request.delete({ url: '/admin-api/infra/config/delete?id=' + id }) +} + +// 导出参数 +export const exportConfig = (params) => { + return request.download({ url: '/admin-api/infra/config/export', params }) +} diff --git a/src/components/IFrame/src/IFrame.vue b/src/components/IFrame/src/IFrame.vue index a8864a7..d578e35 100644 --- a/src/components/IFrame/src/IFrame.vue +++ b/src/components/IFrame/src/IFrame.vue @@ -18,7 +18,7 @@ onMounted(() => { })