Commit 9896e501a946c4b1c911eeb7eae58c47d4a0f117
Committed by
Gitee
!234 vue3 添加验证码关闭功能 修复vue2部分查询问题
Merge pull request !234 from xingyu/master
Showing
59 changed files
with
931 additions
and
261 deletions
yudao-framework/yudao-spring-boot-starter-file/src/main/java/cn/iocoder/yudao/framework/file/core/client/ftp/FtpFileClient.java
| @@ -10,7 +10,6 @@ import cn.iocoder.yudao.framework.file.core.client.AbstractFileClient; | @@ -10,7 +10,6 @@ import cn.iocoder.yudao.framework.file.core.client.AbstractFileClient; | ||
| 10 | 10 | ||
| 11 | import java.io.ByteArrayInputStream; | 11 | import java.io.ByteArrayInputStream; |
| 12 | import java.io.ByteArrayOutputStream; | 12 | import java.io.ByteArrayOutputStream; |
| 13 | -import java.io.File; | ||
| 14 | 13 | ||
| 15 | /** | 14 | /** |
| 16 | * Ftp 文件客户端 | 15 | * Ftp 文件客户端 |
yudao-module-infra/yudao-module-infra-biz/src/main/resources/codegen/vue3/views/index.vue.vm
| @@ -19,11 +19,6 @@ | @@ -19,11 +19,6 @@ | ||
| 19 | }) | 19 | }) |
| 20 | const { getList, setSearchParams, delList, exportList } = methods | 20 | const { getList, setSearchParams, delList, exportList } = methods |
| 21 | 21 | ||
| 22 | - // 导出操作 | ||
| 23 | - const handleExport = async () => { | ||
| 24 | - await exportList('数据.xls') | ||
| 25 | - } | ||
| 26 | - | ||
| 27 | // ========== CRUD 相关 ========== | 22 | // ========== CRUD 相关 ========== |
| 28 | const actionLoading = ref(false) // 遮罩层 | 23 | const actionLoading = ref(false) // 遮罩层 |
| 29 | const actionType = ref('') // 操作按钮的类型 | 24 | const actionType = ref('') // 操作按钮的类型 |
| @@ -74,11 +69,6 @@ | @@ -74,11 +69,6 @@ | ||
| 74 | } | 69 | } |
| 75 | } | 70 | } |
| 76 | 71 | ||
| 77 | - // 删除操作 | ||
| 78 | - const handleDelete = (row: ${simpleClassName}VO) => { | ||
| 79 | - delList(row.id, false) | ||
| 80 | - } | ||
| 81 | - | ||
| 82 | // ========== 详情相关 ========== | 72 | // ========== 详情相关 ========== |
| 83 | const detailRef = ref() // 详情 Ref | 73 | const detailRef = ref() // 详情 Ref |
| 84 | 74 | ||
| @@ -108,7 +98,7 @@ | @@ -108,7 +98,7 @@ | ||
| 108 | type="warning" | 98 | type="warning" |
| 109 | v-hasPermi="['${permissionPrefix}:export']" | 99 | v-hasPermi="['${permissionPrefix}:export']" |
| 110 | :loading="tableObject.exportLoading" | 100 | :loading="tableObject.exportLoading" |
| 111 | - @click="handleExport" | 101 | + @click="exportList('数据.xls')" |
| 112 | > | 102 | > |
| 113 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} | 103 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} |
| 114 | </el-button> | 104 | </el-button> |
| @@ -161,7 +151,7 @@ | @@ -161,7 +151,7 @@ | ||
| 161 | link | 151 | link |
| 162 | type="primary" | 152 | type="primary" |
| 163 | v-hasPermi="['${permissionPrefix}:delete']" | 153 | v-hasPermi="['${permissionPrefix}:delete']" |
| 164 | - @click="handleDelete(row)" | 154 | + @click="delList(row.id, false)" |
| 165 | > | 155 | > |
| 166 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} | 156 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} |
| 167 | </el-button> | 157 | </el-button> |
yudao-ui-admin-vue3/package.json
| @@ -26,8 +26,8 @@ | @@ -26,8 +26,8 @@ | ||
| 26 | }, | 26 | }, |
| 27 | "dependencies": { | 27 | "dependencies": { |
| 28 | "@iconify/iconify": "^2.2.1", | 28 | "@iconify/iconify": "^2.2.1", |
| 29 | - "@vueuse/core": "^8.9.4", | ||
| 30 | - "@wangeditor/editor": "^5.1.10", | 29 | + "@vueuse/core": "^9.0.0", |
| 30 | + "@wangeditor/editor": "^5.1.14", | ||
| 31 | "@wangeditor/editor-for-vue": "^5.1.10", | 31 | "@wangeditor/editor-for-vue": "^5.1.10", |
| 32 | "@zxcvbn-ts/core": "^2.0.3", | 32 | "@zxcvbn-ts/core": "^2.0.3", |
| 33 | "animate.css": "^4.1.1", | 33 | "animate.css": "^4.1.1", |
| @@ -35,7 +35,7 @@ | @@ -35,7 +35,7 @@ | ||
| 35 | "dayjs": "^1.11.4", | 35 | "dayjs": "^1.11.4", |
| 36 | "echarts": "^5.3.3", | 36 | "echarts": "^5.3.3", |
| 37 | "echarts-wordcloud": "^2.0.0", | 37 | "echarts-wordcloud": "^2.0.0", |
| 38 | - "element-plus": "2.2.9", | 38 | + "element-plus": "2.2.11", |
| 39 | "intro.js": "^6.0.0", | 39 | "intro.js": "^6.0.0", |
| 40 | "jsencrypt": "^3.2.1", | 40 | "jsencrypt": "^3.2.1", |
| 41 | "lodash-es": "^4.17.21", | 41 | "lodash-es": "^4.17.21", |
| @@ -49,14 +49,14 @@ | @@ -49,14 +49,14 @@ | ||
| 49 | "vue": "3.2.37", | 49 | "vue": "3.2.37", |
| 50 | "vue-cropper": "^1.0.3", | 50 | "vue-cropper": "^1.0.3", |
| 51 | "vue-i18n": "9.1.10", | 51 | "vue-i18n": "9.1.10", |
| 52 | - "vue-router": "^4.1.2", | 52 | + "vue-router": "^4.1.3", |
| 53 | "vue-types": "^4.2.0", | 53 | "vue-types": "^4.2.0", |
| 54 | "web-storage-cache": "^1.1.1" | 54 | "web-storage-cache": "^1.1.1" |
| 55 | }, | 55 | }, |
| 56 | "devDependencies": { | 56 | "devDependencies": { |
| 57 | "@commitlint/cli": "^17.0.3", | 57 | "@commitlint/cli": "^17.0.3", |
| 58 | "@commitlint/config-conventional": "^17.0.3", | 58 | "@commitlint/config-conventional": "^17.0.3", |
| 59 | - "@iconify/json": "^2.1.82", | 59 | + "@iconify/json": "^2.1.84", |
| 60 | "@intlify/vite-plugin-vue-i18n": "^5.0.1", | 60 | "@intlify/vite-plugin-vue-i18n": "^5.0.1", |
| 61 | "@purge-icons/generated": "^0.8.1", | 61 | "@purge-icons/generated": "^0.8.1", |
| 62 | "@types/intro.js": "^5.1.0", | 62 | "@types/intro.js": "^5.1.0", |
| @@ -83,7 +83,7 @@ | @@ -83,7 +83,7 @@ | ||
| 83 | "postcss-less": "^6.0.0", | 83 | "postcss-less": "^6.0.0", |
| 84 | "prettier": "^2.7.1", | 84 | "prettier": "^2.7.1", |
| 85 | "rimraf": "^3.0.2", | 85 | "rimraf": "^3.0.2", |
| 86 | - "rollup": "^2.77.0", | 86 | + "rollup": "^2.77.2", |
| 87 | "stylelint": "^14.9.1", | 87 | "stylelint": "^14.9.1", |
| 88 | "stylelint-config-html": "^1.1.0", | 88 | "stylelint-config-html": "^1.1.0", |
| 89 | "stylelint-config-prettier": "^9.0.3", | 89 | "stylelint-config-prettier": "^9.0.3", |
| @@ -100,7 +100,7 @@ | @@ -100,7 +100,7 @@ | ||
| 100 | "vite-plugin-style-import": "^1.4.1", | 100 | "vite-plugin-style-import": "^1.4.1", |
| 101 | "vite-plugin-svg-icons": "^2.0.1", | 101 | "vite-plugin-svg-icons": "^2.0.1", |
| 102 | "vite-plugin-windicss": "^1.8.7", | 102 | "vite-plugin-windicss": "^1.8.7", |
| 103 | - "vue-tsc": "^0.39.0", | 103 | + "vue-tsc": "^0.39.2", |
| 104 | "windicss": "^3.5.6", | 104 | "windicss": "^3.5.6", |
| 105 | "windicss-analysis": "^0.3.5" | 105 | "windicss-analysis": "^0.3.5" |
| 106 | }, | 106 | }, |
yudao-ui-admin-vue3/src/api/bpm/form/index.ts
0 → 100644
| 1 | +import { useAxios } from '@/hooks/web/useAxios' | ||
| 2 | +import { FormVO } from './types' | ||
| 3 | +const request = useAxios() | ||
| 4 | + | ||
| 5 | +// 创建工作流的表单定义 | ||
| 6 | +export const createFormApi = async (data: FormVO) => { | ||
| 7 | + return await request.post({ | ||
| 8 | + url: '/bpm/form/create', | ||
| 9 | + data: data | ||
| 10 | + }) | ||
| 11 | +} | ||
| 12 | + | ||
| 13 | +// 更新工作流的表单定义 | ||
| 14 | +export const updateFormApi = async (data: FormVO) => { | ||
| 15 | + return await request.put({ | ||
| 16 | + url: '/bpm/form/update', | ||
| 17 | + data: data | ||
| 18 | + }) | ||
| 19 | +} | ||
| 20 | + | ||
| 21 | +// 删除工作流的表单定义 | ||
| 22 | +export const deleteFormApi = async (id: number) => { | ||
| 23 | + return await request.delete({ | ||
| 24 | + url: '/bpm/form/delete?id=' + id | ||
| 25 | + }) | ||
| 26 | +} | ||
| 27 | + | ||
| 28 | +// 获得工作流的表单定义 | ||
| 29 | +export const getFormApi = async (id: number) => { | ||
| 30 | + return await request.get({ | ||
| 31 | + url: '/bpm/form/get?id=' + id | ||
| 32 | + }) | ||
| 33 | +} | ||
| 34 | + | ||
| 35 | +// 获得工作流的表单定义分页 | ||
| 36 | +export const getFormPageApi = async (params) => { | ||
| 37 | + return await request.get({ | ||
| 38 | + url: '/bpm/form/page', | ||
| 39 | + params | ||
| 40 | + }) | ||
| 41 | +} | ||
| 42 | + | ||
| 43 | +// 获得动态表单的精简列表 | ||
| 44 | +export const getSimpleFormsApi = async () => { | ||
| 45 | + return await request.get({ | ||
| 46 | + url: '/bpm/form/list-all-simple' | ||
| 47 | + }) | ||
| 48 | +} |
yudao-ui-admin-vue3/src/api/bpm/form/types.ts
0 → 100644
yudao-ui-admin-vue3/src/api/bpm/leave/index.ts
0 → 100644
| 1 | +import { useAxios } from '@/hooks/web/useAxios' | ||
| 2 | +import { LeaveVO } from './types' | ||
| 3 | +const request = useAxios() | ||
| 4 | + | ||
| 5 | +// 创建请假申请 | ||
| 6 | +export const createLeaveApi = async (data: LeaveVO) => { | ||
| 7 | + return await request.post({ url: '/bpm/oa/leave/create', data: data }) | ||
| 8 | +} | ||
| 9 | + | ||
| 10 | +// 获得请假申请 | ||
| 11 | +export const getLeaveApi = async (id: number) => { | ||
| 12 | + return await request.get({ url: '/bpm/oa/leave/get?id=' + id }) | ||
| 13 | +} | ||
| 14 | + | ||
| 15 | +// 获得请假申请分页 | ||
| 16 | +export const getLeavePageApi = async (params) => { | ||
| 17 | + return await request.get({ url: '/bpm/oa/leave/page', params }) | ||
| 18 | +} |
yudao-ui-admin-vue3/src/api/bpm/leave/types.ts
0 → 100644
yudao-ui-admin-vue3/src/api/bpm/model/index.ts
0 → 100644
| 1 | +import { useAxios } from '@/hooks/web/useAxios' | ||
| 2 | +import { ModelVO } from './types' | ||
| 3 | +const request = useAxios() | ||
| 4 | + | ||
| 5 | +export const getModelPage = async (params) => { | ||
| 6 | + return await request.get({ url: '/bpm/model/page', params }) | ||
| 7 | +} | ||
| 8 | + | ||
| 9 | +export const getModel = async (id: number) => { | ||
| 10 | + return await request.get({ url: '/bpm/model/get?id=' + id }) | ||
| 11 | +} | ||
| 12 | + | ||
| 13 | +export const updateModel = async (data: ModelVO) => { | ||
| 14 | + return await request.put({ url: '/bpm/model/update', data: data }) | ||
| 15 | +} | ||
| 16 | + | ||
| 17 | +// 任务状态修改 | ||
| 18 | +export const updateModelState = async (id: number, state: string) => { | ||
| 19 | + const data = { | ||
| 20 | + id: id, | ||
| 21 | + state: state | ||
| 22 | + } | ||
| 23 | + return await request.put({ url: '/bpm/model/update-state', data: data }) | ||
| 24 | +} | ||
| 25 | + | ||
| 26 | +export const createModel = async (data: ModelVO) => { | ||
| 27 | + return await request.post({ url: '/bpm/model/create', data: data }) | ||
| 28 | +} | ||
| 29 | + | ||
| 30 | +export const deleteModel = async (id: number) => { | ||
| 31 | + return await request.delete({ url: '/bpm/model/delete?id=' + id }) | ||
| 32 | +} | ||
| 33 | + | ||
| 34 | +export const deployModel = async (id: number) => { | ||
| 35 | + return await request.post({ url: '/bpm/model/deploy?id=' + id }) | ||
| 36 | +} |
yudao-ui-admin-vue3/src/api/bpm/model/types.ts
0 → 100644
| 1 | +export type ModelVO = { | ||
| 2 | + id: number | ||
| 3 | + formName: string | ||
| 4 | + key: string | ||
| 5 | + name: string | ||
| 6 | + description: string | ||
| 7 | + category: string | ||
| 8 | + formType: number | ||
| 9 | + formId: number | ||
| 10 | + formCustomCreatePath: string | ||
| 11 | + formCustomViewPath: string | ||
| 12 | + status: number | ||
| 13 | + remark: string | ||
| 14 | + createTime: string | ||
| 15 | +} |
yudao-ui-admin-vue3/src/api/bpm/processInstance/index.ts
0 → 100644
| 1 | +import { useAxios } from '@/hooks/web/useAxios' | ||
| 2 | +import { ProcessInstanceVO } from './types' | ||
| 3 | +const request = useAxios() | ||
| 4 | + | ||
| 5 | +export const getMyProcessInstancePage = async (params) => { | ||
| 6 | + return await request.get({ url: '/bpm/process-instance/my-page', params }) | ||
| 7 | +} | ||
| 8 | + | ||
| 9 | +export const createProcessInstance = async (data: ProcessInstanceVO) => { | ||
| 10 | + return await request.post({ url: '/bpm/process-instance/create', data: data }) | ||
| 11 | +} | ||
| 12 | + | ||
| 13 | +export const cancelProcessInstance = async (id: number, reason: string) => { | ||
| 14 | + const data = { | ||
| 15 | + id: id, | ||
| 16 | + reason: reason | ||
| 17 | + } | ||
| 18 | + return await request.delete({ url: '/bpm/process-instance/cancel', data: data }) | ||
| 19 | +} | ||
| 20 | + | ||
| 21 | +export const getProcessInstance = async (id: number) => { | ||
| 22 | + return await request.get({ url: '/bpm/process-instance/get?id=' + id }) | ||
| 23 | +} |
yudao-ui-admin-vue3/src/api/bpm/processInstance/types.ts
0 → 100644
| 1 | +export type task = { | ||
| 2 | + id: string | ||
| 3 | + name: string | ||
| 4 | +} | ||
| 5 | +export type ProcessInstanceVO = { | ||
| 6 | + id: number | ||
| 7 | + name: string | ||
| 8 | + processDefinitionId: string | ||
| 9 | + category: string | ||
| 10 | + result: number | ||
| 11 | + tasks: task[] | ||
| 12 | + fields: string[] | ||
| 13 | + status: number | ||
| 14 | + remark: string | ||
| 15 | + businessKey: string | ||
| 16 | + createTime: string | ||
| 17 | + endTime: string | ||
| 18 | +} |
yudao-ui-admin-vue3/src/api/bpm/task/index.ts
0 → 100644
| 1 | +import { useAxios } from '@/hooks/web/useAxios' | ||
| 2 | + | ||
| 3 | +const request = useAxios() | ||
| 4 | + | ||
| 5 | +export const getTodoTaskPage = async (params) => { | ||
| 6 | + return await request.get({ url: '/bpm/task/todo-page', params }) | ||
| 7 | +} | ||
| 8 | + | ||
| 9 | +export const getDoneTaskPage = async (params) => { | ||
| 10 | + return await request.get({ url: '/bpm/task/done-page', params }) | ||
| 11 | +} | ||
| 12 | + | ||
| 13 | +export const completeTask = async (data) => { | ||
| 14 | + return await request.put({ url: '/bpm/task/complete', data: data }) | ||
| 15 | +} | ||
| 16 | + | ||
| 17 | +export const approveTask = async (data) => { | ||
| 18 | + return await request.put({ url: '/bpm/task/approve', data: data }) | ||
| 19 | +} | ||
| 20 | + | ||
| 21 | +export const rejectTask = async (data) => { | ||
| 22 | + return await request.put({ url: '/bpm/task/reject', data: data }) | ||
| 23 | +} | ||
| 24 | +export const backTask = async (data) => { | ||
| 25 | + return await request.put({ url: '/bpm/task/back', data: data }) | ||
| 26 | +} | ||
| 27 | + | ||
| 28 | +export const updateTaskAssignee = async (data) => { | ||
| 29 | + return await request.put({ url: '/bpm/task/update-assignee', data: data }) | ||
| 30 | +} | ||
| 31 | + | ||
| 32 | +export const getTaskListByProcessInstanceId = async (processInstanceId) => { | ||
| 33 | + return await request.get({ | ||
| 34 | + url: '/bpm/task/list-by-process-instance-id?processInstanceId=' + processInstanceId | ||
| 35 | + }) | ||
| 36 | +} |
yudao-ui-admin-vue3/src/api/bpm/task/types.ts
0 → 100644
yudao-ui-admin-vue3/src/api/bpm/taskAssignRule/index.ts
0 → 100644
| 1 | +import { useAxios } from '@/hooks/web/useAxios' | ||
| 2 | +import { TaskAssignVO } from './types' | ||
| 3 | +const request = useAxios() | ||
| 4 | + | ||
| 5 | +export const getTaskAssignRuleList = async (params) => { | ||
| 6 | + return await request.get({ url: '/bpm/task-assign-rule/list', params }) | ||
| 7 | +} | ||
| 8 | + | ||
| 9 | +export const createTaskAssignRule = async (data: TaskAssignVO) => { | ||
| 10 | + return await request.post({ | ||
| 11 | + url: '/bpm/task-assign-rule/create', | ||
| 12 | + data: data | ||
| 13 | + }) | ||
| 14 | +} | ||
| 15 | + | ||
| 16 | +export const updateTaskAssignRule = async (data: TaskAssignVO) => { | ||
| 17 | + return await request.put({ | ||
| 18 | + url: '/bpm/task-assign-rule/update', | ||
| 19 | + data: data | ||
| 20 | + }) | ||
| 21 | +} |
yudao-ui-admin-vue3/src/api/bpm/taskAssignRule/types.ts
0 → 100644
yudao-ui-admin-vue3/src/api/bpm/userGroup/index.ts
0 → 100644
| 1 | +import { useAxios } from '@/hooks/web/useAxios' | ||
| 2 | +import { UserGroupVO } from './types' | ||
| 3 | +const request = useAxios() | ||
| 4 | + | ||
| 5 | +// 创建用户组 | ||
| 6 | +export const createUserGroupApi = async (data: UserGroupVO) => { | ||
| 7 | + return await request.post({ | ||
| 8 | + url: '/bpm/user-group/create', | ||
| 9 | + data: data | ||
| 10 | + }) | ||
| 11 | +} | ||
| 12 | + | ||
| 13 | +// 更新用户组 | ||
| 14 | +export const updateUserGroupApi = async (data: UserGroupVO) => { | ||
| 15 | + return await request.put({ | ||
| 16 | + url: '/bpm/user-group/update', | ||
| 17 | + data: data | ||
| 18 | + }) | ||
| 19 | +} | ||
| 20 | + | ||
| 21 | +// 删除用户组 | ||
| 22 | +export const deleteUserGroupApi = async (id: number) => { | ||
| 23 | + return await request.delete({ url: '/bpm/user-group/delete?id=' + id }) | ||
| 24 | +} | ||
| 25 | + | ||
| 26 | +// 获得用户组 | ||
| 27 | +export const getUserGroupApi = async (id: number) => { | ||
| 28 | + return await request.get({ url: '/bpm/user-group/get?id=' + id }) | ||
| 29 | +} | ||
| 30 | + | ||
| 31 | +// 获得用户组分页 | ||
| 32 | +export const getUserGroupPageApi = async (params) => { | ||
| 33 | + return await request.get({ url: '/bpm/user-group/page', params }) | ||
| 34 | +} | ||
| 35 | + | ||
| 36 | +// 获取用户组精简信息列表 | ||
| 37 | +export const listSimpleUserGroupsApi = async () => { | ||
| 38 | + return await request.get({ url: '/bpm/user-group/list-all-simple' }) | ||
| 39 | +} |
yudao-ui-admin-vue3/src/api/bpm/userGroup/types.ts
0 → 100644
yudao-ui-admin-vue3/src/api/system/user/index.ts
| @@ -55,3 +55,8 @@ export const updateUserStatusApi = (id: number, status: number) => { | @@ -55,3 +55,8 @@ export const updateUserStatusApi = (id: number, status: number) => { | ||
| 55 | } | 55 | } |
| 56 | return request.put({ url: '/system/user/update-status', data: data }) | 56 | return request.put({ url: '/system/user/update-status', data: data }) |
| 57 | } | 57 | } |
| 58 | + | ||
| 59 | +// 获取用户精简信息列表 | ||
| 60 | +export const getListSimpleUsersApi = () => { | ||
| 61 | + return request.get({ url: '/system/user/list-all-simple' }) | ||
| 62 | +} |
yudao-ui-admin-vue3/src/api/system/user/profile/index.ts
| @@ -24,6 +24,6 @@ export const updateUserPwdApi = (oldPassword: string, newPassword: string) => { | @@ -24,6 +24,6 @@ export const updateUserPwdApi = (oldPassword: string, newPassword: string) => { | ||
| 24 | } | 24 | } |
| 25 | 25 | ||
| 26 | // 用户头像上传 | 26 | // 用户头像上传 |
| 27 | -export const uploadAvatarApi = (data) => { | ||
| 28 | - return request.put({ url: '/system/user/profile/update-avatar', data: data }) | 27 | +export const uploadAvatarApi = (params) => { |
| 28 | + return request.upload({ url: '/system/user/profile/update-avatar', params }) | ||
| 29 | } | 29 | } |
yudao-ui-admin-vue3/src/hooks/web/useAxios.ts
| @@ -42,12 +42,19 @@ async function downloadFn<T = any>(option: AxiosConfig): Promise<T> { | @@ -42,12 +42,19 @@ async function downloadFn<T = any>(option: AxiosConfig): Promise<T> { | ||
| 42 | return res as unknown as Promise<T> | 42 | return res as unknown as Promise<T> |
| 43 | } | 43 | } |
| 44 | 44 | ||
| 45 | +async function uploadFn<T = any>(option: AxiosConfig): Promise<T> { | ||
| 46 | + option.headersType = 'multipart/form-data' | ||
| 47 | + const res = await request({ method: 'PUT', ...option }) | ||
| 48 | + return res as unknown as Promise<T> | ||
| 49 | +} | ||
| 50 | + | ||
| 45 | export const useAxios = () => { | 51 | export const useAxios = () => { |
| 46 | return { | 52 | return { |
| 47 | get: getFn, | 53 | get: getFn, |
| 48 | post: postFn, | 54 | post: postFn, |
| 49 | delete: deleteFn, | 55 | delete: deleteFn, |
| 50 | put: putFn, | 56 | put: putFn, |
| 51 | - download: downloadFn | 57 | + download: downloadFn, |
| 58 | + upload: uploadFn | ||
| 52 | } | 59 | } |
| 53 | } | 60 | } |
yudao-ui-admin-vue3/src/views/Login/components/LoginForm.vue
| @@ -47,12 +47,17 @@ const iconHouse = useIcon({ icon: 'ep:house' }) | @@ -47,12 +47,17 @@ const iconHouse = useIcon({ icon: 'ep:house' }) | ||
| 47 | const iconAvatar = useIcon({ icon: 'ep:avatar' }) | 47 | const iconAvatar = useIcon({ icon: 'ep:avatar' }) |
| 48 | const iconLock = useIcon({ icon: 'ep:lock' }) | 48 | const iconLock = useIcon({ icon: 'ep:lock' }) |
| 49 | const iconCircleCheck = useIcon({ icon: 'ep:circle-check' }) | 49 | const iconCircleCheck = useIcon({ icon: 'ep:circle-check' }) |
| 50 | -const LoginRules = { | 50 | +const LoginCaptchaRules = { |
| 51 | tenantName: [required], | 51 | tenantName: [required], |
| 52 | username: [required], | 52 | username: [required], |
| 53 | password: [required], | 53 | password: [required], |
| 54 | code: [required] | 54 | code: [required] |
| 55 | } | 55 | } |
| 56 | +const LoginRules = { | ||
| 57 | + tenantName: [required], | ||
| 58 | + username: [required], | ||
| 59 | + password: [required] | ||
| 60 | +} | ||
| 56 | const loginLoading = ref(false) | 61 | const loginLoading = ref(false) |
| 57 | const loginData = reactive({ | 62 | const loginData = reactive({ |
| 58 | codeImg: '', | 63 | codeImg: '', |
| @@ -76,8 +81,11 @@ const loginData = reactive({ | @@ -76,8 +81,11 @@ const loginData = reactive({ | ||
| 76 | // 获取验证码 | 81 | // 获取验证码 |
| 77 | const getCode = async () => { | 82 | const getCode = async () => { |
| 78 | const res = await LoginApi.getCodeImgApi() | 83 | const res = await LoginApi.getCodeImgApi() |
| 79 | - loginData.codeImg = 'data:image/gif;base64,' + res.img | ||
| 80 | - loginData.loginForm.uuid = res.uuid | 84 | + loginData.captchaEnable = res.enable |
| 85 | + if (res.enable) { | ||
| 86 | + loginData.codeImg = 'data:image/gif;base64,' + res.img | ||
| 87 | + loginData.loginForm.uuid = res.uuid | ||
| 88 | + } | ||
| 81 | } | 89 | } |
| 82 | //获取租户ID | 90 | //获取租户ID |
| 83 | const getTenantId = async () => { | 91 | const getTenantId = async () => { |
| @@ -159,7 +167,7 @@ onMounted(async () => { | @@ -159,7 +167,7 @@ onMounted(async () => { | ||
| 159 | <template> | 167 | <template> |
| 160 | <el-form | 168 | <el-form |
| 161 | :model="loginData.loginForm" | 169 | :model="loginData.loginForm" |
| 162 | - :rules="LoginRules" | 170 | + :rules="loginData.captchaEnable ? LoginCaptchaRules : LoginRules" |
| 163 | label-position="top" | 171 | label-position="top" |
| 164 | class="login-form" | 172 | class="login-form" |
| 165 | label-width="120px" | 173 | label-width="120px" |
| @@ -205,7 +213,7 @@ onMounted(async () => { | @@ -205,7 +213,7 @@ onMounted(async () => { | ||
| 205 | </el-form-item> | 213 | </el-form-item> |
| 206 | </el-col> | 214 | </el-col> |
| 207 | <el-col :span="24" style="padding-left: 10px; padding-right: 10px"> | 215 | <el-col :span="24" style="padding-left: 10px; padding-right: 10px"> |
| 208 | - <el-form-item prop="code"> | 216 | + <el-form-item prop="code" v-if="loginData.captchaEnable"> |
| 209 | <el-row justify="space-between" style="width: 100%"> | 217 | <el-row justify="space-between" style="width: 100%"> |
| 210 | <el-col :span="14"> | 218 | <el-col :span="14"> |
| 211 | <el-input | 219 | <el-input |
yudao-ui-admin-vue3/src/views/Profile/components/ProfileUser.vue
| @@ -2,7 +2,7 @@ | @@ -2,7 +2,7 @@ | ||
| 2 | import { getUserProfileApi } from '@/api/system/user/profile' | 2 | import { getUserProfileApi } from '@/api/system/user/profile' |
| 3 | import { onMounted, reactive } from 'vue' | 3 | import { onMounted, reactive } from 'vue' |
| 4 | import dayjs from 'dayjs' | 4 | import dayjs from 'dayjs' |
| 5 | -import { UserAvatarVue } from './' | 5 | +import UserAvatar from './UserAvatar.vue' |
| 6 | import { ProfileVO } from '@/api/system/user/profile/types' | 6 | import { ProfileVO } from '@/api/system/user/profile/types' |
| 7 | import { useI18n } from '@/hooks/web/useI18n' | 7 | import { useI18n } from '@/hooks/web/useI18n' |
| 8 | const { t } = useI18n() | 8 | const { t } = useI18n() |
| @@ -43,7 +43,7 @@ onMounted(async () => { | @@ -43,7 +43,7 @@ onMounted(async () => { | ||
| 43 | <template> | 43 | <template> |
| 44 | <div> | 44 | <div> |
| 45 | <div class="text-center"> | 45 | <div class="text-center"> |
| 46 | - <UserAvatarVue :img="userInfo.user.avatar" /> | 46 | + <UserAvatar :img="userInfo.user.avatar" /> |
| 47 | </div> | 47 | </div> |
| 48 | <ul class="list-group list-group-striped"> | 48 | <ul class="list-group list-group-striped"> |
| 49 | <li class="list-group-item"> | 49 | <li class="list-group-item"> |
yudao-ui-admin-vue3/src/views/Profile/components/UserAvatar.vue
| @@ -2,7 +2,7 @@ | @@ -2,7 +2,7 @@ | ||
| 2 | import { ref, reactive, watch } from 'vue' | 2 | import { ref, reactive, watch } from 'vue' |
| 3 | import 'vue-cropper/dist/index.css' | 3 | import 'vue-cropper/dist/index.css' |
| 4 | import { VueCropper } from 'vue-cropper' | 4 | import { VueCropper } from 'vue-cropper' |
| 5 | -import { ElRow, ElCol, ElUpload, ElMessage } from 'element-plus' | 5 | +import { ElRow, ElCol, ElUpload, ElMessage, ElDialog } from 'element-plus' |
| 6 | import { propTypes } from '@/utils/propTypes' | 6 | import { propTypes } from '@/utils/propTypes' |
| 7 | import { uploadAvatarApi } from '@/api/system/user/profile' | 7 | import { uploadAvatarApi } from '@/api/system/user/profile' |
| 8 | const cropper = ref() | 8 | const cropper = ref() |
| @@ -43,6 +43,8 @@ const changeScale = (num: number) => { | @@ -43,6 +43,8 @@ const changeScale = (num: number) => { | ||
| 43 | num = num || 1 | 43 | num = num || 1 |
| 44 | cropper.value.changeScale(num) | 44 | cropper.value.changeScale(num) |
| 45 | } | 45 | } |
| 46 | +// 覆盖默认的上传行为 | ||
| 47 | +const requestUpload = () => {} | ||
| 46 | /** 上传预处理 */ | 48 | /** 上传预处理 */ |
| 47 | const beforeUpload = (file: Blob) => { | 49 | const beforeUpload = (file: Blob) => { |
| 48 | if (file.type.indexOf('image/') == -1) { | 50 | if (file.type.indexOf('image/') == -1) { |
| @@ -84,7 +86,7 @@ watch( | @@ -84,7 +86,7 @@ watch( | ||
| 84 | <div class="user-info-head" @click="editCropper()"> | 86 | <div class="user-info-head" @click="editCropper()"> |
| 85 | <img :src="state.options.img" title="点击上传头像" class="img-circle img-lg" alt="" /> | 87 | <img :src="state.options.img" title="点击上传头像" class="img-circle img-lg" alt="" /> |
| 86 | </div> | 88 | </div> |
| 87 | - <Dialog | 89 | + <el-dialog |
| 88 | v-model="state.dialogVisible" | 90 | v-model="state.dialogVisible" |
| 89 | :title="state.dialogTitle" | 91 | :title="state.dialogTitle" |
| 90 | width="50%" | 92 | width="50%" |
| @@ -92,7 +94,7 @@ watch( | @@ -92,7 +94,7 @@ watch( | ||
| 92 | style="padding: 30px 20px" | 94 | style="padding: 30px 20px" |
| 93 | > | 95 | > |
| 94 | <el-row> | 96 | <el-row> |
| 95 | - <el-col :xs="24" :md="12" :style="{ height: '350px' }"> | 97 | + <el-col :xs="24" :md="12" style="height: 350px"> |
| 96 | <VueCropper | 98 | <VueCropper |
| 97 | ref="cropper" | 99 | ref="cropper" |
| 98 | :img="state.options.img" | 100 | :img="state.options.img" |
| @@ -105,7 +107,7 @@ watch( | @@ -105,7 +107,7 @@ watch( | ||
| 105 | v-if="state.cropperVisible" | 107 | v-if="state.cropperVisible" |
| 106 | /> | 108 | /> |
| 107 | </el-col> | 109 | </el-col> |
| 108 | - <el-col :xs="24" :md="12" :style="{ height: '350px' }"> | 110 | + <el-col :xs="24" :md="12" style="height: 350px"> |
| 109 | <div class="avatar-upload-preview"> | 111 | <div class="avatar-upload-preview"> |
| 110 | <img | 112 | <img |
| 111 | :src="state.previews.url" | 113 | :src="state.previews.url" |
| @@ -119,7 +121,12 @@ watch( | @@ -119,7 +121,12 @@ watch( | ||
| 119 | <template #footer> | 121 | <template #footer> |
| 120 | <el-row> | 122 | <el-row> |
| 121 | <el-col :lg="2" :md="2"> | 123 | <el-col :lg="2" :md="2"> |
| 122 | - <el-upload action="#" :show-file-list="false" :before-upload="beforeUpload"> | 124 | + <el-upload |
| 125 | + action="#" | ||
| 126 | + :http-request="requestUpload" | ||
| 127 | + :show-file-list="false" | ||
| 128 | + :before-upload="beforeUpload" | ||
| 129 | + > | ||
| 123 | <el-button size="small"> | 130 | <el-button size="small"> |
| 124 | <Icon icon="ep:upload-filled" class="mr-5px" /> | 131 | <Icon icon="ep:upload-filled" class="mr-5px" /> |
| 125 | 选择 | 132 | 选择 |
| @@ -151,7 +158,7 @@ watch( | @@ -151,7 +158,7 @@ watch( | ||
| 151 | </el-col> | 158 | </el-col> |
| 152 | </el-row> | 159 | </el-row> |
| 153 | </template> | 160 | </template> |
| 154 | - </Dialog> | 161 | + </el-dialog> |
| 155 | </template> | 162 | </template> |
| 156 | <style scoped> | 163 | <style scoped> |
| 157 | .user-info-head { | 164 | .user-info-head { |
yudao-ui-admin-vue3/src/views/bpm/definition/index.vue deleted
yudao-ui-admin-vue3/src/views/bpm/form/form.data.ts
0 → 100644
| 1 | +import { reactive } from 'vue' | ||
| 2 | +import { useI18n } from '@/hooks/web/useI18n' | ||
| 3 | +import { required } from '@/utils/formRules' | ||
| 4 | +import { CrudSchema, useCrudSchemas } from '@/hooks/web/useCrudSchemas' | ||
| 5 | +import { DICT_TYPE } from '@/utils/dict' | ||
| 6 | +const { t } = useI18n() // 国际化 | ||
| 7 | + | ||
| 8 | +// 表单校验 | ||
| 9 | +export const rules = reactive({ | ||
| 10 | + name: [required] | ||
| 11 | +}) | ||
| 12 | + | ||
| 13 | +// CrudSchema | ||
| 14 | +const crudSchemas = reactive<CrudSchema[]>([ | ||
| 15 | + { | ||
| 16 | + label: t('common.index'), | ||
| 17 | + field: 'id', | ||
| 18 | + type: 'index', | ||
| 19 | + form: { | ||
| 20 | + show: false | ||
| 21 | + }, | ||
| 22 | + detail: { | ||
| 23 | + show: false | ||
| 24 | + } | ||
| 25 | + }, | ||
| 26 | + { | ||
| 27 | + label: '表单名', | ||
| 28 | + field: 'name', | ||
| 29 | + search: { | ||
| 30 | + show: true | ||
| 31 | + } | ||
| 32 | + }, | ||
| 33 | + { | ||
| 34 | + label: t('common.status'), | ||
| 35 | + field: 'status', | ||
| 36 | + dictType: DICT_TYPE.COMMON_STATUS | ||
| 37 | + }, | ||
| 38 | + { | ||
| 39 | + label: '备注', | ||
| 40 | + field: 'remark' | ||
| 41 | + }, | ||
| 42 | + { | ||
| 43 | + label: t('common.createTime'), | ||
| 44 | + field: 'createTime', | ||
| 45 | + form: { | ||
| 46 | + show: false | ||
| 47 | + } | ||
| 48 | + }, | ||
| 49 | + { | ||
| 50 | + label: t('table.action'), | ||
| 51 | + field: 'action', | ||
| 52 | + width: '240px', | ||
| 53 | + form: { | ||
| 54 | + show: false | ||
| 55 | + }, | ||
| 56 | + detail: { | ||
| 57 | + show: false | ||
| 58 | + } | ||
| 59 | + } | ||
| 60 | +]) | ||
| 61 | +export const { allSchemas } = useCrudSchemas(crudSchemas) |
yudao-ui-admin-vue3/src/views/bpm/form/index.vue
| 1 | -<script setup lang="ts"></script> | 1 | +<script setup lang="ts"> |
| 2 | +import { ref, unref } from 'vue' | ||
| 3 | +import dayjs from 'dayjs' | ||
| 4 | +import { ElMessage } from 'element-plus' | ||
| 5 | +import { DICT_TYPE } from '@/utils/dict' | ||
| 6 | +import { useTable } from '@/hooks/web/useTable' | ||
| 7 | +import { useI18n } from '@/hooks/web/useI18n' | ||
| 8 | +import { FormExpose } from '@/components/Form' | ||
| 9 | +import type { FormVO } from '@/api/bpm/form/types' | ||
| 10 | +import { rules, allSchemas } from './form.data' | ||
| 11 | +import * as FormApi from '@/api/bpm/form' | ||
| 12 | +const { t } = useI18n() // 国际化 | ||
| 13 | + | ||
| 14 | +// ========== 列表相关 ========== | ||
| 15 | +const { register, tableObject, methods } = useTable<FormVO>({ | ||
| 16 | + getListApi: FormApi.getFormPageApi, | ||
| 17 | + delListApi: FormApi.deleteFormApi | ||
| 18 | +}) | ||
| 19 | +const { getList, setSearchParams, delList } = methods | ||
| 20 | + | ||
| 21 | +// ========== CRUD 相关 ========== | ||
| 22 | +const actionLoading = ref(false) // 遮罩层 | ||
| 23 | +const actionType = ref('') // 操作按钮的类型 | ||
| 24 | +const dialogVisible = ref(false) // 是否显示弹出层 | ||
| 25 | +const dialogTitle = ref('edit') // 弹出层标题 | ||
| 26 | +const formRef = ref<FormExpose>() // 表单 Ref | ||
| 27 | + | ||
| 28 | +// 设置标题 | ||
| 29 | +const setDialogTile = (type: string) => { | ||
| 30 | + dialogTitle.value = t('action.' + type) | ||
| 31 | + actionType.value = type | ||
| 32 | + dialogVisible.value = true | ||
| 33 | +} | ||
| 34 | + | ||
| 35 | +// 新增操作 | ||
| 36 | +const handleCreate = () => { | ||
| 37 | + setDialogTile('create') | ||
| 38 | + // 重置表单 | ||
| 39 | + unref(formRef)?.getElFormRef()?.resetFields() | ||
| 40 | +} | ||
| 41 | + | ||
| 42 | +// 修改操作 | ||
| 43 | +const handleUpdate = async (row: FormVO) => { | ||
| 44 | + setDialogTile('update') | ||
| 45 | + // 设置数据 | ||
| 46 | + const res = await FormApi.getFormApi(row.id) | ||
| 47 | + unref(formRef)?.setValues(res) | ||
| 48 | +} | ||
| 49 | + | ||
| 50 | +// 提交按钮 | ||
| 51 | +const submitForm = async () => { | ||
| 52 | + actionLoading.value = true | ||
| 53 | + // 提交请求 | ||
| 54 | + try { | ||
| 55 | + const data = unref(formRef)?.formModel as FormVO | ||
| 56 | + if (actionType.value === 'create') { | ||
| 57 | + await FormApi.createFormApi(data) | ||
| 58 | + ElMessage.success(t('common.createSuccess')) | ||
| 59 | + } else { | ||
| 60 | + await FormApi.updateFormApi(data) | ||
| 61 | + ElMessage.success(t('common.updateSuccess')) | ||
| 62 | + } | ||
| 63 | + // 操作成功,重新加载列表 | ||
| 64 | + dialogVisible.value = false | ||
| 65 | + await getList() | ||
| 66 | + } finally { | ||
| 67 | + actionLoading.value = false | ||
| 68 | + } | ||
| 69 | +} | ||
| 70 | + | ||
| 71 | +// ========== 详情相关 ========== | ||
| 72 | +const detailRef = ref() // 详情 Ref | ||
| 73 | + | ||
| 74 | +// 详情操作 | ||
| 75 | +const handleDetail = async (row: FormVO) => { | ||
| 76 | + // 设置数据 | ||
| 77 | + detailRef.value = row | ||
| 78 | + setDialogTile('detail') | ||
| 79 | +} | ||
| 80 | + | ||
| 81 | +// ========== 初始化 ========== | ||
| 82 | +getList() | ||
| 83 | +</script> | ||
| 2 | 84 | ||
| 3 | <template> | 85 | <template> |
| 4 | - <div>index</div> | ||
| 5 | -</template> | 86 | + <!-- 搜索工作区 --> |
| 87 | + <ContentWrap> | ||
| 88 | + <Search :schema="allSchemas.searchSchema" @search="setSearchParams" @reset="setSearchParams" /> | ||
| 89 | + </ContentWrap> | ||
| 90 | + <ContentWrap> | ||
| 91 | + <!-- 操作工具栏 --> | ||
| 92 | + <div class="mb-10px"> | ||
| 93 | + <el-button type="primary" v-hasPermi="['bpm:form:create']" @click="handleCreate"> | ||
| 94 | + <Icon icon="ep:zoom-in" class="mr-5px" /> {{ t('action.add') }} | ||
| 95 | + </el-button> | ||
| 96 | + </div> | ||
| 97 | + <!-- 列表 --> | ||
| 98 | + <Table | ||
| 99 | + :columns="allSchemas.tableColumns" | ||
| 100 | + :selection="false" | ||
| 101 | + :data="tableObject.tableList" | ||
| 102 | + :loading="tableObject.loading" | ||
| 103 | + :pagination="{ | ||
| 104 | + total: tableObject.total | ||
| 105 | + }" | ||
| 106 | + v-model:pageSize="tableObject.pageSize" | ||
| 107 | + v-model:currentPage="tableObject.currentPage" | ||
| 108 | + @register="register" | ||
| 109 | + > | ||
| 110 | + <template #status="{ row }"> | ||
| 111 | + <DictTag :type="DICT_TYPE.COMMON_STATUS" :value="row.status" /> | ||
| 112 | + </template> | ||
| 113 | + <template #createTime="{ row }"> | ||
| 114 | + <span>{{ dayjs(row.createTime).format('YYYY-MM-DD HH:mm:ss') }}</span> | ||
| 115 | + </template> | ||
| 116 | + <template #action="{ row }"> | ||
| 117 | + <el-button link type="primary" v-hasPermi="['bpm:form:update']" @click="handleUpdate(row)"> | ||
| 118 | + <Icon icon="ep:edit" class="mr-1px" /> {{ t('action.edit') }} | ||
| 119 | + </el-button> | ||
| 120 | + <el-button link type="primary" v-hasPermi="['bpm:form:update']" @click="handleDetail(row)"> | ||
| 121 | + <Icon icon="ep:view" class="mr-1px" /> {{ t('action.detail') }} | ||
| 122 | + </el-button> | ||
| 123 | + <el-button | ||
| 124 | + link | ||
| 125 | + type="primary" | ||
| 126 | + v-hasPermi="['bpm:form:delete']" | ||
| 127 | + @click="delList(row.id, false)" | ||
| 128 | + > | ||
| 129 | + <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} | ||
| 130 | + </el-button> | ||
| 131 | + </template> | ||
| 132 | + </Table> | ||
| 133 | + </ContentWrap> | ||
| 6 | 134 | ||
| 7 | -<style scoped></style> | 135 | + <Dialog v-model="dialogVisible" :title="dialogTitle"> |
| 136 | + <!-- 对话框(添加 / 修改) --> | ||
| 137 | + <Form | ||
| 138 | + v-if="['create', 'update'].includes(actionType)" | ||
| 139 | + :schema="allSchemas.formSchema" | ||
| 140 | + :rules="rules" | ||
| 141 | + ref="formRef" | ||
| 142 | + /> | ||
| 143 | + <!-- 对话框(详情) --> | ||
| 144 | + <Descriptions | ||
| 145 | + v-if="actionType === 'detail'" | ||
| 146 | + :schema="allSchemas.detailSchema" | ||
| 147 | + :data="detailRef" | ||
| 148 | + > | ||
| 149 | + <template #status="{ row }"> | ||
| 150 | + <DictTag :type="DICT_TYPE.COMMON_STATUS" :value="row.status" /> | ||
| 151 | + </template> | ||
| 152 | + <template #createTime="{ row }"> | ||
| 153 | + <span>{{ dayjs(row.createTime).format('YYYY-MM-DD HH:mm:ss') }}</span> | ||
| 154 | + </template> | ||
| 155 | + </Descriptions> | ||
| 156 | + <!-- 操作按钮 --> | ||
| 157 | + <template #footer> | ||
| 158 | + <el-button | ||
| 159 | + v-if="['create', 'update'].includes(actionType)" | ||
| 160 | + type="primary" | ||
| 161 | + :loading="actionLoading" | ||
| 162 | + @click="submitForm" | ||
| 163 | + > | ||
| 164 | + {{ t('action.save') }} | ||
| 165 | + </el-button> | ||
| 166 | + <el-button @click="dialogVisible = false">{{ t('dialog.close') }}</el-button> | ||
| 167 | + </template> | ||
| 168 | + </Dialog> | ||
| 169 | +</template> |
yudao-ui-admin-vue3/src/views/bpm/group/group.data.ts
0 → 100644
| 1 | +import { reactive } from 'vue' | ||
| 2 | +import { useI18n } from '@/hooks/web/useI18n' | ||
| 3 | +import { required } from '@/utils/formRules' | ||
| 4 | +import { CrudSchema, useCrudSchemas } from '@/hooks/web/useCrudSchemas' | ||
| 5 | +import { DICT_TYPE } from '@/utils/dict' | ||
| 6 | +const { t } = useI18n() // 国际化 | ||
| 7 | + | ||
| 8 | +// 表单校验 | ||
| 9 | +export const rules = reactive({ | ||
| 10 | + name: [required] | ||
| 11 | +}) | ||
| 12 | + | ||
| 13 | +// CrudSchema | ||
| 14 | +const crudSchemas = reactive<CrudSchema[]>([ | ||
| 15 | + { | ||
| 16 | + label: t('common.index'), | ||
| 17 | + field: 'id', | ||
| 18 | + type: 'index', | ||
| 19 | + form: { | ||
| 20 | + show: false | ||
| 21 | + }, | ||
| 22 | + detail: { | ||
| 23 | + show: false | ||
| 24 | + } | ||
| 25 | + }, | ||
| 26 | + { | ||
| 27 | + label: '组名', | ||
| 28 | + field: 'name', | ||
| 29 | + search: { | ||
| 30 | + show: true | ||
| 31 | + } | ||
| 32 | + }, | ||
| 33 | + { | ||
| 34 | + label: '成员', | ||
| 35 | + field: 'memberUserIds' | ||
| 36 | + }, | ||
| 37 | + { | ||
| 38 | + label: '描述', | ||
| 39 | + field: 'description' | ||
| 40 | + }, | ||
| 41 | + { | ||
| 42 | + label: t('common.status'), | ||
| 43 | + field: 'status', | ||
| 44 | + dictType: DICT_TYPE.COMMON_STATUS | ||
| 45 | + }, | ||
| 46 | + { | ||
| 47 | + label: '备注', | ||
| 48 | + field: 'remark', | ||
| 49 | + table: { | ||
| 50 | + show: false | ||
| 51 | + } | ||
| 52 | + }, | ||
| 53 | + { | ||
| 54 | + label: t('common.createTime'), | ||
| 55 | + field: 'createTime', | ||
| 56 | + form: { | ||
| 57 | + show: false | ||
| 58 | + } | ||
| 59 | + }, | ||
| 60 | + { | ||
| 61 | + label: t('table.action'), | ||
| 62 | + field: 'action', | ||
| 63 | + width: '240px', | ||
| 64 | + form: { | ||
| 65 | + show: false | ||
| 66 | + }, | ||
| 67 | + detail: { | ||
| 68 | + show: false | ||
| 69 | + } | ||
| 70 | + } | ||
| 71 | +]) | ||
| 72 | +export const { allSchemas } = useCrudSchemas(crudSchemas) |
yudao-ui-admin-vue3/src/views/bpm/group/index.vue
| 1 | -<script setup lang="ts"></script> | 1 | +<script setup lang="ts"> |
| 2 | +import { ref, unref, onMounted } from 'vue' | ||
| 3 | +import dayjs from 'dayjs' | ||
| 4 | +import { ElMessage, ElSelect, ElOption } from 'element-plus' | ||
| 5 | +import { DICT_TYPE } from '@/utils/dict' | ||
| 6 | +import { useTable } from '@/hooks/web/useTable' | ||
| 7 | +import { useI18n } from '@/hooks/web/useI18n' | ||
| 8 | +import { FormExpose } from '@/components/Form' | ||
| 9 | +import type { UserGroupVO } from '@/api/bpm/userGroup/types' | ||
| 10 | +import { rules, allSchemas } from './group.data' | ||
| 11 | +import * as UserGroupApi from '@/api/bpm/userGroup' | ||
| 12 | +import { getListSimpleUsersApi } from '@/api/system/user' | ||
| 13 | +import { UserVO } from '@/api/system/user/types' | ||
| 14 | + | ||
| 15 | +const { t } = useI18n() // 国际化 | ||
| 16 | + | ||
| 17 | +// ========== 列表相关 ========== | ||
| 18 | +const { register, tableObject, methods } = useTable<UserGroupVO>({ | ||
| 19 | + getListApi: UserGroupApi.getUserGroupPageApi, | ||
| 20 | + delListApi: UserGroupApi.deleteUserGroupApi | ||
| 21 | +}) | ||
| 22 | +const { getList, setSearchParams, delList } = methods | ||
| 23 | + | ||
| 24 | +// ========== CRUD 相关 ========== | ||
| 25 | +const actionLoading = ref(false) // 遮罩层 | ||
| 26 | +const actionType = ref('') // 操作按钮的类型 | ||
| 27 | +const dialogVisible = ref(false) // 是否显示弹出层 | ||
| 28 | +const dialogTitle = ref('edit') // 弹出层标题 | ||
| 29 | +const formRef = ref<FormExpose>() // 表单 Ref | ||
| 30 | + | ||
| 31 | +// ========== 用户选择 ========== | ||
| 32 | +const userIds = ref<number[]>([]) | ||
| 33 | +const userOptions = ref<UserVO[]>([]) | ||
| 34 | +const getUserOptions = async () => { | ||
| 35 | + const res = await getListSimpleUsersApi() | ||
| 36 | + userOptions.value.push(...res) | ||
| 37 | +} | ||
| 38 | + | ||
| 39 | +// 设置标题 | ||
| 40 | +const setDialogTile = (type: string) => { | ||
| 41 | + dialogTitle.value = t('action.' + type) | ||
| 42 | + actionType.value = type | ||
| 43 | + dialogVisible.value = true | ||
| 44 | +} | ||
| 45 | + | ||
| 46 | +// 新增操作 | ||
| 47 | +const handleCreate = () => { | ||
| 48 | + setDialogTile('create') | ||
| 49 | + userIds.value = [] | ||
| 50 | + // 重置表单 | ||
| 51 | + unref(formRef)?.getElFormRef()?.resetFields() | ||
| 52 | +} | ||
| 53 | + | ||
| 54 | +// 修改操作 | ||
| 55 | +const handleUpdate = async (row: UserGroupVO) => { | ||
| 56 | + setDialogTile('update') | ||
| 57 | + // 设置数据 | ||
| 58 | + const res = await UserGroupApi.getUserGroupApi(row.id) | ||
| 59 | + userIds.value = res.memberUserIds | ||
| 60 | + unref(formRef)?.setValues(res) | ||
| 61 | +} | ||
| 62 | + | ||
| 63 | +// 提交按钮 | ||
| 64 | +const submitForm = async () => { | ||
| 65 | + actionLoading.value = true | ||
| 66 | + // 提交请求 | ||
| 67 | + try { | ||
| 68 | + const data = unref(formRef)?.formModel as UserGroupVO | ||
| 69 | + data.memberUserIds = userIds.value | ||
| 70 | + if (actionType.value === 'create') { | ||
| 71 | + await UserGroupApi.createUserGroupApi(data) | ||
| 72 | + ElMessage.success(t('common.createSuccess')) | ||
| 73 | + } else { | ||
| 74 | + await UserGroupApi.updateUserGroupApi(data) | ||
| 75 | + ElMessage.success(t('common.updateSuccess')) | ||
| 76 | + } | ||
| 77 | + // 操作成功,重新加载列表 | ||
| 78 | + dialogVisible.value = false | ||
| 79 | + await getList() | ||
| 80 | + } finally { | ||
| 81 | + actionLoading.value = false | ||
| 82 | + } | ||
| 83 | +} | ||
| 84 | + | ||
| 85 | +// 根据用户名获取用户真实名 | ||
| 86 | +const getUserNickName = (userId: number) => { | ||
| 87 | + for (const user of userOptions.value) { | ||
| 88 | + if (user.id === userId) return user.nickname | ||
| 89 | + } | ||
| 90 | + return '未知(' + userId + ')' | ||
| 91 | +} | ||
| 92 | +// ========== 详情相关 ========== | ||
| 93 | +const detailRef = ref() // 详情 Ref | ||
| 94 | + | ||
| 95 | +// 详情操作 | ||
| 96 | +const handleDetail = async (row: UserGroupVO) => { | ||
| 97 | + // 设置数据 | ||
| 98 | + detailRef.value = row | ||
| 99 | + setDialogTile('detail') | ||
| 100 | +} | ||
| 101 | + | ||
| 102 | +// ========== 初始化 ========== | ||
| 103 | +onMounted(async () => { | ||
| 104 | + await getList() | ||
| 105 | + await getUserOptions() | ||
| 106 | +}) | ||
| 107 | +</script> | ||
| 2 | 108 | ||
| 3 | <template> | 109 | <template> |
| 4 | - <div>index</div> | ||
| 5 | -</template> | 110 | + <!-- 搜索工作区 --> |
| 111 | + <ContentWrap> | ||
| 112 | + <Search :schema="allSchemas.searchSchema" @search="setSearchParams" @reset="setSearchParams" /> | ||
| 113 | + </ContentWrap> | ||
| 114 | + <ContentWrap> | ||
| 115 | + <!-- 操作工具栏 --> | ||
| 116 | + <div class="mb-10px"> | ||
| 117 | + <el-button type="primary" v-hasPermi="['bpm:user-group:create']" @click="handleCreate"> | ||
| 118 | + <Icon icon="ep:zoom-in" class="mr-5px" /> {{ t('action.add') }} | ||
| 119 | + </el-button> | ||
| 120 | + </div> | ||
| 121 | + <!-- 列表 --> | ||
| 122 | + <Table | ||
| 123 | + :columns="allSchemas.tableColumns" | ||
| 124 | + :selection="false" | ||
| 125 | + :data="tableObject.tableList" | ||
| 126 | + :loading="tableObject.loading" | ||
| 127 | + :pagination="{ | ||
| 128 | + total: tableObject.total | ||
| 129 | + }" | ||
| 130 | + v-model:pageSize="tableObject.pageSize" | ||
| 131 | + v-model:currentPage="tableObject.currentPage" | ||
| 132 | + @register="register" | ||
| 133 | + > | ||
| 134 | + <template #status="{ row }"> | ||
| 135 | + <DictTag :type="DICT_TYPE.COMMON_STATUS" :value="row.status" /> | ||
| 136 | + </template> | ||
| 137 | + <template #memberUserIds="{ row }"> | ||
| 138 | + <span v-for="userId in row.memberUserIds" :key="userId"> | ||
| 139 | + {{ getUserNickName(userId) + ' ' }} | ||
| 140 | + </span> | ||
| 141 | + </template> | ||
| 142 | + <template #createTime="{ row }"> | ||
| 143 | + <span>{{ dayjs(row.createTime).format('YYYY-MM-DD HH:mm:ss') }}</span> | ||
| 144 | + </template> | ||
| 145 | + <template #action="{ row }"> | ||
| 146 | + <el-button | ||
| 147 | + link | ||
| 148 | + type="primary" | ||
| 149 | + v-hasPermi="['bpm:user-group:update']" | ||
| 150 | + @click="handleUpdate(row)" | ||
| 151 | + > | ||
| 152 | + <Icon icon="ep:edit" class="mr-1px" /> {{ t('action.edit') }} | ||
| 153 | + </el-button> | ||
| 154 | + <el-button | ||
| 155 | + link | ||
| 156 | + type="primary" | ||
| 157 | + v-hasPermi="['bpm:user-group:update']" | ||
| 158 | + @click="handleDetail(row)" | ||
| 159 | + > | ||
| 160 | + <Icon icon="ep:view" class="mr-1px" /> {{ t('action.detail') }} | ||
| 161 | + </el-button> | ||
| 162 | + <el-button | ||
| 163 | + link | ||
| 164 | + type="primary" | ||
| 165 | + v-hasPermi="['bpm:user-group:delete']" | ||
| 166 | + @click="delList(row.id, false)" | ||
| 167 | + > | ||
| 168 | + <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} | ||
| 169 | + </el-button> | ||
| 170 | + </template> | ||
| 171 | + </Table> | ||
| 172 | + </ContentWrap> | ||
| 6 | 173 | ||
| 7 | -<style scoped></style> | 174 | + <Dialog v-model="dialogVisible" :title="dialogTitle"> |
| 175 | + <!-- 对话框(添加 / 修改) --> | ||
| 176 | + <Form | ||
| 177 | + v-if="['create', 'update'].includes(actionType)" | ||
| 178 | + :schema="allSchemas.formSchema" | ||
| 179 | + :rules="rules" | ||
| 180 | + ref="formRef" | ||
| 181 | + > | ||
| 182 | + <template #memberUserIds> | ||
| 183 | + <el-select v-model="userIds" multiple> | ||
| 184 | + <el-option | ||
| 185 | + v-for="item in userOptions" | ||
| 186 | + :key="item.id" | ||
| 187 | + :label="item.nickname" | ||
| 188 | + :value="item.id" | ||
| 189 | + /> | ||
| 190 | + </el-select> | ||
| 191 | + </template> | ||
| 192 | + </Form> | ||
| 193 | + <!-- 对话框(详情) --> | ||
| 194 | + <Descriptions | ||
| 195 | + v-if="actionType === 'detail'" | ||
| 196 | + :schema="allSchemas.detailSchema" | ||
| 197 | + :data="detailRef" | ||
| 198 | + > | ||
| 199 | + <template #memberUserIds="{ row }"> | ||
| 200 | + <span v-for="userId in row.memberUserIds" :key="userId"> | ||
| 201 | + {{ getUserNickName(userId) + ' ' }} | ||
| 202 | + </span> | ||
| 203 | + </template> | ||
| 204 | + <template #status="{ row }"> | ||
| 205 | + <DictTag :type="DICT_TYPE.COMMON_STATUS" :value="row.status" /> | ||
| 206 | + </template> | ||
| 207 | + <template #createTime="{ row }"> | ||
| 208 | + <span>{{ dayjs(row.createTime).format('YYYY-MM-DD HH:mm:ss') }}</span> | ||
| 209 | + </template> | ||
| 210 | + </Descriptions> | ||
| 211 | + <!-- 操作按钮 --> | ||
| 212 | + <template #footer> | ||
| 213 | + <el-button | ||
| 214 | + v-if="['create', 'update'].includes(actionType)" | ||
| 215 | + type="primary" | ||
| 216 | + :loading="actionLoading" | ||
| 217 | + @click="submitForm" | ||
| 218 | + > | ||
| 219 | + {{ t('action.save') }} | ||
| 220 | + </el-button> | ||
| 221 | + <el-button @click="dialogVisible = false">{{ t('dialog.close') }}</el-button> | ||
| 222 | + </template> | ||
| 223 | + </Dialog> | ||
| 224 | +</template> |
yudao-ui-admin-vue3/src/views/infra/apiErrorLog/index.vue
| @@ -23,10 +23,6 @@ const { getList, setSearchParams, exportList } = methods | @@ -23,10 +23,6 @@ const { getList, setSearchParams, exportList } = methods | ||
| 23 | const detailRef = ref() // 详情 Ref | 23 | const detailRef = ref() // 详情 Ref |
| 24 | const dialogVisible = ref(false) // 是否显示弹出层 | 24 | const dialogVisible = ref(false) // 是否显示弹出层 |
| 25 | const dialogTitle = ref('') // 弹出层标题 | 25 | const dialogTitle = ref('') // 弹出层标题 |
| 26 | -// 导出操作 | ||
| 27 | -const handleExport = async () => { | ||
| 28 | - await exportList('用户数据.xls') | ||
| 29 | -} | ||
| 30 | 26 | ||
| 31 | // 详情操作 | 27 | // 详情操作 |
| 32 | const handleDetail = (row: ApiErrorLogVO) => { | 28 | const handleDetail = (row: ApiErrorLogVO) => { |
| @@ -57,7 +53,7 @@ getList() | @@ -57,7 +53,7 @@ getList() | ||
| 57 | <Search :schema="allSchemas.searchSchema" @search="setSearchParams" @reset="setSearchParams" /> | 53 | <Search :schema="allSchemas.searchSchema" @search="setSearchParams" @reset="setSearchParams" /> |
| 58 | </ContentWrap> | 54 | </ContentWrap> |
| 59 | <ContentWrap> | 55 | <ContentWrap> |
| 60 | - <el-button v-hasPermi="['infra:api-error-log:export']" @click="handleExport"> | 56 | + <el-button v-hasPermi="['infra:api-error-log:export']" @click="exportList('错误数据.xls')"> |
| 61 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} | 57 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} |
| 62 | </el-button> | 58 | </el-button> |
| 63 | <!-- 列表 --> | 59 | <!-- 列表 --> |
yudao-ui-admin-vue3/src/views/infra/codegen/index.vue
| @@ -49,10 +49,6 @@ const handleGenTable = async (row: CodegenTableVO) => { | @@ -49,10 +49,6 @@ const handleGenTable = async (row: CodegenTableVO) => { | ||
| 49 | const res = await CodegenApi.downloadCodegenApi(row.id) | 49 | const res = await CodegenApi.downloadCodegenApi(row.id) |
| 50 | download.zip(res, 'codegen-' + row.className + '.zip') | 50 | download.zip(res, 'codegen-' + row.className + '.zip') |
| 51 | } | 51 | } |
| 52 | -// 删除操作 | ||
| 53 | -const handleDelete = (row: CodegenTableVO) => { | ||
| 54 | - delList(row.id, false) | ||
| 55 | -} | ||
| 56 | // 查询操作 | 52 | // 查询操作 |
| 57 | const handleQuery = () => { | 53 | const handleQuery = () => { |
| 58 | getList() | 54 | getList() |
| @@ -112,7 +108,7 @@ getList() | @@ -112,7 +108,7 @@ getList() | ||
| 112 | link | 108 | link |
| 113 | type="primary" | 109 | type="primary" |
| 114 | v-hasPermi="['infra:codegen:delete']" | 110 | v-hasPermi="['infra:codegen:delete']" |
| 115 | - @click="handleDelete(row)" | 111 | + @click="delList(row.id, false)" |
| 116 | > | 112 | > |
| 117 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} | 113 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} |
| 118 | </el-button> | 114 | </el-button> |
yudao-ui-admin-vue3/src/views/infra/config/index.vue
| @@ -19,11 +19,6 @@ const { register, tableObject, methods } = useTable<ConfigVO>({ | @@ -19,11 +19,6 @@ const { register, tableObject, methods } = useTable<ConfigVO>({ | ||
| 19 | }) | 19 | }) |
| 20 | const { getList, setSearchParams, delList, exportList } = methods | 20 | const { getList, setSearchParams, delList, exportList } = methods |
| 21 | 21 | ||
| 22 | -// 导出操作 | ||
| 23 | -const handleExport = async () => { | ||
| 24 | - await exportList('参数配置.xls') | ||
| 25 | -} | ||
| 26 | - | ||
| 27 | // ========== CRUD 相关 ========== | 22 | // ========== CRUD 相关 ========== |
| 28 | const actionLoading = ref(false) // 遮罩层 | 23 | const actionLoading = ref(false) // 遮罩层 |
| 29 | const actionType = ref('') // 操作按钮的类型 | 24 | const actionType = ref('') // 操作按钮的类型 |
| @@ -74,11 +69,6 @@ const submitForm = async () => { | @@ -74,11 +69,6 @@ const submitForm = async () => { | ||
| 74 | } | 69 | } |
| 75 | } | 70 | } |
| 76 | 71 | ||
| 77 | -// 删除操作 | ||
| 78 | -const handleDelete = (row: ConfigVO) => { | ||
| 79 | - delList(row.id, false) | ||
| 80 | -} | ||
| 81 | - | ||
| 82 | // ========== 详情相关 ========== | 72 | // ========== 详情相关 ========== |
| 83 | const detailRef = ref() // 详情 Ref | 73 | const detailRef = ref() // 详情 Ref |
| 84 | 74 | ||
| @@ -108,7 +98,7 @@ getList() | @@ -108,7 +98,7 @@ getList() | ||
| 108 | type="warning" | 98 | type="warning" |
| 109 | v-hasPermi="['infra:config:export']" | 99 | v-hasPermi="['infra:config:export']" |
| 110 | :loading="tableObject.exportLoading" | 100 | :loading="tableObject.exportLoading" |
| 111 | - @click="handleExport" | 101 | + @click="exportList('参数配置.xls')" |
| 112 | > | 102 | > |
| 113 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} | 103 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} |
| 114 | </el-button> | 104 | </el-button> |
| @@ -156,7 +146,7 @@ getList() | @@ -156,7 +146,7 @@ getList() | ||
| 156 | link | 146 | link |
| 157 | type="primary" | 147 | type="primary" |
| 158 | v-hasPermi="['infra:config:delete']" | 148 | v-hasPermi="['infra:config:delete']" |
| 159 | - @click="handleDelete(row)" | 149 | + @click="delList(row.id, false)" |
| 160 | > | 150 | > |
| 161 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} | 151 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} |
| 162 | </el-button> | 152 | </el-button> |
yudao-ui-admin-vue3/src/views/infra/fileConfig/index.vue
| @@ -79,11 +79,6 @@ const submitForm = async () => { | @@ -79,11 +79,6 @@ const submitForm = async () => { | ||
| 79 | } | 79 | } |
| 80 | } | 80 | } |
| 81 | 81 | ||
| 82 | -// 删除操作 | ||
| 83 | -const handleDelete = (row: FileConfigVO) => { | ||
| 84 | - delList(row.id, false) | ||
| 85 | -} | ||
| 86 | - | ||
| 87 | // ========== 详情相关 ========== | 82 | // ========== 详情相关 ========== |
| 88 | const detailRef = ref() // 详情 Ref | 83 | const detailRef = ref() // 详情 Ref |
| 89 | 84 | ||
| @@ -169,7 +164,7 @@ getList() | @@ -169,7 +164,7 @@ getList() | ||
| 169 | link | 164 | link |
| 170 | type="primary" | 165 | type="primary" |
| 171 | v-hasPermi="['infra:file-config:delete']" | 166 | v-hasPermi="['infra:file-config:delete']" |
| 172 | - @click="handleDelete(row)" | 167 | + @click="delList(row.id, false)" |
| 173 | > | 168 | > |
| 174 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} | 169 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} |
| 175 | </el-button> | 170 | </el-button> |
yudao-ui-admin-vue3/src/views/infra/fileList/index.vue
| @@ -69,10 +69,6 @@ const excelUploadError = (): void => { | @@ -69,10 +69,6 @@ const excelUploadError = (): void => { | ||
| 69 | const detailRef = ref() // 详情 Ref | 69 | const detailRef = ref() // 详情 Ref |
| 70 | const dialogVisible = ref(false) // 是否显示弹出层 | 70 | const dialogVisible = ref(false) // 是否显示弹出层 |
| 71 | const dialogTitle = ref('') // 弹出层标题 | 71 | const dialogTitle = ref('') // 弹出层标题 |
| 72 | -// 删除操作 | ||
| 73 | -const handleDelete = (row: FileVO) => { | ||
| 74 | - delList(row.id, false) | ||
| 75 | -} | ||
| 76 | // 详情操作 | 72 | // 详情操作 |
| 77 | const handleDetail = (row: FileVO) => { | 73 | const handleDetail = (row: FileVO) => { |
| 78 | // 设置数据 | 74 | // 设置数据 |
| @@ -128,7 +124,7 @@ getList() | @@ -128,7 +124,7 @@ getList() | ||
| 128 | link | 124 | link |
| 129 | type="primary" | 125 | type="primary" |
| 130 | v-hasPermi="['infra:file:delete']" | 126 | v-hasPermi="['infra:file:delete']" |
| 131 | - @click="handleDelete(row)" | 127 | + @click="delList(row.id, false)" |
| 132 | > | 128 | > |
| 133 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} | 129 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} |
| 134 | </el-button> | 130 | </el-button> |
yudao-ui-admin-vue3/src/views/infra/job/JobLog.vue
| @@ -25,10 +25,6 @@ const getTableList = async () => { | @@ -25,10 +25,6 @@ const getTableList = async () => { | ||
| 25 | } | 25 | } |
| 26 | await getList() | 26 | await getList() |
| 27 | } | 27 | } |
| 28 | -// 导出操作 | ||
| 29 | -const handleExport = async () => { | ||
| 30 | - await exportList('定时任务日志.xls') | ||
| 31 | -} | ||
| 32 | 28 | ||
| 33 | // ========== CRUD 相关 ========== | 29 | // ========== CRUD 相关 ========== |
| 34 | const dialogVisible = ref(false) // 是否显示弹出层 | 30 | const dialogVisible = ref(false) // 是否显示弹出层 |
| @@ -63,7 +59,7 @@ onMounted(() => { | @@ -63,7 +59,7 @@ onMounted(() => { | ||
| 63 | type="warning" | 59 | type="warning" |
| 64 | v-hasPermi="['infra:job:export']" | 60 | v-hasPermi="['infra:job:export']" |
| 65 | :loading="tableObject.exportLoading" | 61 | :loading="tableObject.exportLoading" |
| 66 | - @click="handleExport" | 62 | + @click="exportList('定时任务日志.xls')" |
| 67 | > | 63 | > |
| 68 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} | 64 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} |
| 69 | </el-button> | 65 | </el-button> |
yudao-ui-admin-vue3/src/views/infra/job/index.vue
| @@ -22,11 +22,6 @@ const { register, tableObject, methods } = useTable<JobVO>({ | @@ -22,11 +22,6 @@ const { register, tableObject, methods } = useTable<JobVO>({ | ||
| 22 | }) | 22 | }) |
| 23 | const { getList, setSearchParams, delList, exportList } = methods | 23 | const { getList, setSearchParams, delList, exportList } = methods |
| 24 | 24 | ||
| 25 | -// 导出操作 | ||
| 26 | -const handleExport = async () => { | ||
| 27 | - await exportList('定时任务.xls') | ||
| 28 | -} | ||
| 29 | - | ||
| 30 | // ========== CRUD 相关 ========== | 25 | // ========== CRUD 相关 ========== |
| 31 | const actionLoading = ref(false) // 遮罩层 | 26 | const actionLoading = ref(false) // 遮罩层 |
| 32 | const actionType = ref('') // 操作按钮的类型 | 27 | const actionType = ref('') // 操作按钮的类型 |
| @@ -92,11 +87,6 @@ const submitForm = async () => { | @@ -92,11 +87,6 @@ const submitForm = async () => { | ||
| 92 | } | 87 | } |
| 93 | } | 88 | } |
| 94 | 89 | ||
| 95 | -// 删除操作 | ||
| 96 | -const handleDelete = (row: JobVO) => { | ||
| 97 | - delList(row.id, false) | ||
| 98 | -} | ||
| 99 | - | ||
| 100 | // ========== 详情相关 ========== | 90 | // ========== 详情相关 ========== |
| 101 | const detailRef = ref() // 详情 Ref | 91 | const detailRef = ref() // 详情 Ref |
| 102 | 92 | ||
| @@ -126,7 +116,7 @@ getList() | @@ -126,7 +116,7 @@ getList() | ||
| 126 | type="warning" | 116 | type="warning" |
| 127 | v-hasPermi="['infra:job:export']" | 117 | v-hasPermi="['infra:job:export']" |
| 128 | :loading="tableObject.exportLoading" | 118 | :loading="tableObject.exportLoading" |
| 129 | - @click="handleExport" | 119 | + @click="exportList('定时任务.xls')" |
| 130 | > | 120 | > |
| 131 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} | 121 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} |
| 132 | </el-button> | 122 | </el-button> |
| @@ -157,7 +147,12 @@ getList() | @@ -157,7 +147,12 @@ getList() | ||
| 157 | <el-button link type="primary" v-hasPermi="['infra:job:query']" @click="handleDetail(row)"> | 147 | <el-button link type="primary" v-hasPermi="['infra:job:query']" @click="handleDetail(row)"> |
| 158 | <Icon icon="ep:view" class="mr-1px" /> {{ t('action.detail') }} | 148 | <Icon icon="ep:view" class="mr-1px" /> {{ t('action.detail') }} |
| 159 | </el-button> | 149 | </el-button> |
| 160 | - <el-button link type="primary" v-hasPermi="['infra:job:delete']" @click="handleDelete(row)"> | 150 | + <el-button |
| 151 | + link | ||
| 152 | + type="primary" | ||
| 153 | + v-hasPermi="['infra:job:delete']" | ||
| 154 | + @click="delList(row.id, false)" | ||
| 155 | + > | ||
| 161 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} | 156 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} |
| 162 | </el-button> | 157 | </el-button> |
| 163 | <el-button link type="primary" v-hasPermi="['infra:job:trigger']" @click="handleRun(row)"> | 158 | <el-button link type="primary" v-hasPermi="['infra:job:trigger']" @click="handleRun(row)"> |
yudao-ui-admin-vue3/src/views/pay/app/index.vue
| @@ -19,11 +19,6 @@ const { register, tableObject, methods } = useTable<AppVO>({ | @@ -19,11 +19,6 @@ const { register, tableObject, methods } = useTable<AppVO>({ | ||
| 19 | }) | 19 | }) |
| 20 | const { getList, setSearchParams, delList, exportList } = methods | 20 | const { getList, setSearchParams, delList, exportList } = methods |
| 21 | 21 | ||
| 22 | -// 导出操作 | ||
| 23 | -const handleExport = async () => { | ||
| 24 | - await exportList('应用数据.xls') | ||
| 25 | -} | ||
| 26 | - | ||
| 27 | // ========== CRUD 相关 ========== | 22 | // ========== CRUD 相关 ========== |
| 28 | const actionLoading = ref(false) // 遮罩层 | 23 | const actionLoading = ref(false) // 遮罩层 |
| 29 | const actionType = ref('') // 操作按钮的类型 | 24 | const actionType = ref('') // 操作按钮的类型 |
| @@ -74,11 +69,6 @@ const submitForm = async () => { | @@ -74,11 +69,6 @@ const submitForm = async () => { | ||
| 74 | } | 69 | } |
| 75 | } | 70 | } |
| 76 | 71 | ||
| 77 | -// 删除操作 | ||
| 78 | -const handleDelete = (row: AppVO) => { | ||
| 79 | - delList(row.id, false) | ||
| 80 | -} | ||
| 81 | - | ||
| 82 | // ========== 详情相关 ========== | 72 | // ========== 详情相关 ========== |
| 83 | const detailRef = ref() // 详情 Ref | 73 | const detailRef = ref() // 详情 Ref |
| 84 | 74 | ||
| @@ -108,7 +98,7 @@ getList() | @@ -108,7 +98,7 @@ getList() | ||
| 108 | type="warning" | 98 | type="warning" |
| 109 | v-hasPermi="['system:post:export']" | 99 | v-hasPermi="['system:post:export']" |
| 110 | :loading="tableObject.exportLoading" | 100 | :loading="tableObject.exportLoading" |
| 111 | - @click="handleExport" | 101 | + @click="exportList('应用数据.xls')" |
| 112 | > | 102 | > |
| 113 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} | 103 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} |
| 114 | </el-button> | 104 | </el-button> |
| @@ -153,7 +143,7 @@ getList() | @@ -153,7 +143,7 @@ getList() | ||
| 153 | link | 143 | link |
| 154 | type="primary" | 144 | type="primary" |
| 155 | v-hasPermi="['system:post:delete']" | 145 | v-hasPermi="['system:post:delete']" |
| 156 | - @click="handleDelete(row)" | 146 | + @click="delList(row.id, false)" |
| 157 | > | 147 | > |
| 158 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} | 148 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} |
| 159 | </el-button> | 149 | </el-button> |
yudao-ui-admin-vue3/src/views/pay/merchant/index.vue
| @@ -19,11 +19,6 @@ const { register, tableObject, methods } = useTable<MerchantVO>({ | @@ -19,11 +19,6 @@ const { register, tableObject, methods } = useTable<MerchantVO>({ | ||
| 19 | }) | 19 | }) |
| 20 | const { getList, setSearchParams, delList, exportList } = methods | 20 | const { getList, setSearchParams, delList, exportList } = methods |
| 21 | 21 | ||
| 22 | -// 导出操作 | ||
| 23 | -const handleExport = async () => { | ||
| 24 | - await exportList('商户数据.xls') | ||
| 25 | -} | ||
| 26 | - | ||
| 27 | // ========== CRUD 相关 ========== | 22 | // ========== CRUD 相关 ========== |
| 28 | const actionLoading = ref(false) // 遮罩层 | 23 | const actionLoading = ref(false) // 遮罩层 |
| 29 | const actionType = ref('') // 操作按钮的类型 | 24 | const actionType = ref('') // 操作按钮的类型 |
| @@ -74,11 +69,6 @@ const submitForm = async () => { | @@ -74,11 +69,6 @@ const submitForm = async () => { | ||
| 74 | } | 69 | } |
| 75 | } | 70 | } |
| 76 | 71 | ||
| 77 | -// 删除操作 | ||
| 78 | -const handleDelete = (row: MerchantVO) => { | ||
| 79 | - delList(row.id, false) | ||
| 80 | -} | ||
| 81 | - | ||
| 82 | // ========== 详情相关 ========== | 72 | // ========== 详情相关 ========== |
| 83 | const detailRef = ref() // 详情 Ref | 73 | const detailRef = ref() // 详情 Ref |
| 84 | 74 | ||
| @@ -108,7 +98,7 @@ getList() | @@ -108,7 +98,7 @@ getList() | ||
| 108 | type="warning" | 98 | type="warning" |
| 109 | v-hasPermi="['system:post:export']" | 99 | v-hasPermi="['system:post:export']" |
| 110 | :loading="tableObject.exportLoading" | 100 | :loading="tableObject.exportLoading" |
| 111 | - @click="handleExport" | 101 | + @click="exportList('商户数据.xls')" |
| 112 | > | 102 | > |
| 113 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} | 103 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} |
| 114 | </el-button> | 104 | </el-button> |
| @@ -153,7 +143,7 @@ getList() | @@ -153,7 +143,7 @@ getList() | ||
| 153 | link | 143 | link |
| 154 | type="primary" | 144 | type="primary" |
| 155 | v-hasPermi="['system:post:delete']" | 145 | v-hasPermi="['system:post:delete']" |
| 156 | - @click="handleDelete(row)" | 146 | + @click="delList(row.id, false)" |
| 157 | > | 147 | > |
| 158 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} | 148 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} |
| 159 | </el-button> | 149 | </el-button> |
yudao-ui-admin-vue3/src/views/pay/order/index.vue
| @@ -17,10 +17,6 @@ const { register, tableObject, methods } = useTable<OrderVO>({ | @@ -17,10 +17,6 @@ const { register, tableObject, methods } = useTable<OrderVO>({ | ||
| 17 | exportListApi: OrderApi.exportOrderApi | 17 | exportListApi: OrderApi.exportOrderApi |
| 18 | }) | 18 | }) |
| 19 | const { getList, setSearchParams, delList, exportList } = methods | 19 | const { getList, setSearchParams, delList, exportList } = methods |
| 20 | -// 导出操作 | ||
| 21 | -const handleExport = async () => { | ||
| 22 | - await exportList('订单数据.xls') | ||
| 23 | -} | ||
| 24 | // ========== CRUD 相关 ========== | 20 | // ========== CRUD 相关 ========== |
| 25 | const actionLoading = ref(false) // 遮罩层 | 21 | const actionLoading = ref(false) // 遮罩层 |
| 26 | const actionType = ref('') // 操作按钮的类型 | 22 | const actionType = ref('') // 操作按钮的类型 |
| @@ -71,11 +67,6 @@ const submitForm = async () => { | @@ -71,11 +67,6 @@ const submitForm = async () => { | ||
| 71 | } | 67 | } |
| 72 | } | 68 | } |
| 73 | 69 | ||
| 74 | -// 删除操作 | ||
| 75 | -const handleDelete = (row: OrderVO) => { | ||
| 76 | - delList(row.id, false) | ||
| 77 | -} | ||
| 78 | - | ||
| 79 | // ========== 详情相关 ========== | 70 | // ========== 详情相关 ========== |
| 80 | const detailRef = ref() // 详情 Ref | 71 | const detailRef = ref() // 详情 Ref |
| 81 | 72 | ||
| @@ -105,7 +96,7 @@ getList() | @@ -105,7 +96,7 @@ getList() | ||
| 105 | type="warning" | 96 | type="warning" |
| 106 | v-hasPermi="['pay:order:export']" | 97 | v-hasPermi="['pay:order:export']" |
| 107 | :loading="tableObject.exportLoading" | 98 | :loading="tableObject.exportLoading" |
| 108 | - @click="handleExport" | 99 | + @click="exportList('订单数据.xls')" |
| 109 | > | 100 | > |
| 110 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} | 101 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} |
| 111 | </el-button> | 102 | </el-button> |
| @@ -133,7 +124,12 @@ getList() | @@ -133,7 +124,12 @@ getList() | ||
| 133 | <el-button link type="primary" v-hasPermi="['pay:order:update']" @click="handleDetail(row)"> | 124 | <el-button link type="primary" v-hasPermi="['pay:order:update']" @click="handleDetail(row)"> |
| 134 | <Icon icon="ep:view" class="mr-1px" /> {{ t('action.detail') }} | 125 | <Icon icon="ep:view" class="mr-1px" /> {{ t('action.detail') }} |
| 135 | </el-button> | 126 | </el-button> |
| 136 | - <el-button link type="primary" v-hasPermi="['pay:order:delete']" @click="handleDelete(row)"> | 127 | + <el-button |
| 128 | + link | ||
| 129 | + type="primary" | ||
| 130 | + v-hasPermi="['pay:order:delete']" | ||
| 131 | + @click="delList(row.id, false)" | ||
| 132 | + > | ||
| 137 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} | 133 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} |
| 138 | </el-button> | 134 | </el-button> |
| 139 | </template> | 135 | </template> |
yudao-ui-admin-vue3/src/views/pay/refund/index.vue
| @@ -17,20 +17,10 @@ const { register, tableObject, methods } = useTable<RefundVO>({ | @@ -17,20 +17,10 @@ const { register, tableObject, methods } = useTable<RefundVO>({ | ||
| 17 | }) | 17 | }) |
| 18 | const { getList, setSearchParams, delList, exportList } = methods | 18 | const { getList, setSearchParams, delList, exportList } = methods |
| 19 | 19 | ||
| 20 | -// 导出操作 | ||
| 21 | -const handleExport = async () => { | ||
| 22 | - await exportList('退款订单.xls') | ||
| 23 | -} | ||
| 24 | - | ||
| 25 | // ========== CRUD 相关 ========== | 20 | // ========== CRUD 相关 ========== |
| 26 | const dialogVisible = ref(false) // 是否显示弹出层 | 21 | const dialogVisible = ref(false) // 是否显示弹出层 |
| 27 | const dialogTitle = ref('edit') // 弹出层标题 | 22 | const dialogTitle = ref('edit') // 弹出层标题 |
| 28 | 23 | ||
| 29 | -// 删除操作 | ||
| 30 | -const handleDelete = (row: RefundVO) => { | ||
| 31 | - delList(row.id, false) | ||
| 32 | -} | ||
| 33 | - | ||
| 34 | // ========== 详情相关 ========== | 24 | // ========== 详情相关 ========== |
| 35 | const detailRef = ref() // 详情 Ref | 25 | const detailRef = ref() // 详情 Ref |
| 36 | 26 | ||
| @@ -58,7 +48,7 @@ getList() | @@ -58,7 +48,7 @@ getList() | ||
| 58 | type="warning" | 48 | type="warning" |
| 59 | v-hasPermi="['system:post:export']" | 49 | v-hasPermi="['system:post:export']" |
| 60 | :loading="tableObject.exportLoading" | 50 | :loading="tableObject.exportLoading" |
| 61 | - @click="handleExport" | 51 | + @click="exportList('退款订单.xls')" |
| 62 | > | 52 | > |
| 63 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} | 53 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} |
| 64 | </el-button> | 54 | </el-button> |
| @@ -95,7 +85,7 @@ getList() | @@ -95,7 +85,7 @@ getList() | ||
| 95 | link | 85 | link |
| 96 | type="primary" | 86 | type="primary" |
| 97 | v-hasPermi="['system:post:delete']" | 87 | v-hasPermi="['system:post:delete']" |
| 98 | - @click="handleDelete(row)" | 88 | + @click="delList(row.id, false)" |
| 99 | > | 89 | > |
| 100 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} | 90 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} |
| 101 | </el-button> | 91 | </el-button> |
yudao-ui-admin-vue3/src/views/system/dict/index.vue
| @@ -38,10 +38,6 @@ const handleTypeUpdate = async (row: DictTypeVO) => { | @@ -38,10 +38,6 @@ const handleTypeUpdate = async (row: DictTypeVO) => { | ||
| 38 | const res = await DictTypeApi.getDictTypeApi(row.id) | 38 | const res = await DictTypeApi.getDictTypeApi(row.id) |
| 39 | unref(typeFormRef)?.setValues(res) | 39 | unref(typeFormRef)?.setValues(res) |
| 40 | } | 40 | } |
| 41 | -// 字典分类删除操作 | ||
| 42 | -const handleTypeDelete = async (row: DictTypeVO) => { | ||
| 43 | - await delTypeList(row.id, false) | ||
| 44 | -} | ||
| 45 | 41 | ||
| 46 | // ========== 字典数据列表相关 ========== | 42 | // ========== 字典数据列表相关 ========== |
| 47 | const tableTypeSelect = ref(false) | 43 | const tableTypeSelect = ref(false) |
| @@ -71,10 +67,6 @@ const handleDataUpdate = async (row: DictDataVO) => { | @@ -71,10 +67,6 @@ const handleDataUpdate = async (row: DictDataVO) => { | ||
| 71 | const res = await DictDataApi.getDictDataApi(row.id) | 67 | const res = await DictDataApi.getDictDataApi(row.id) |
| 72 | unref(dataFormRef)?.setValues(res) | 68 | unref(dataFormRef)?.setValues(res) |
| 73 | } | 69 | } |
| 74 | -// 字典数据删除操作 | ||
| 75 | -const handleDataDelete = async (row: DictTypeVO) => { | ||
| 76 | - await delDataList(row.id, false) | ||
| 77 | -} | ||
| 78 | // 字典分类点击行事件 | 70 | // 字典分类点击行事件 |
| 79 | const parentType = ref('') | 71 | const parentType = ref('') |
| 80 | const onClickType = async (data: { [key: string]: any }) => { | 72 | const onClickType = async (data: { [key: string]: any }) => { |
| @@ -195,7 +187,7 @@ onMounted(async () => { | @@ -195,7 +187,7 @@ onMounted(async () => { | ||
| 195 | link | 187 | link |
| 196 | type="primary" | 188 | type="primary" |
| 197 | v-hasPermi="['system:dict:delete']" | 189 | v-hasPermi="['system:dict:delete']" |
| 198 | - @click="handleTypeDelete(row)" | 190 | + @click="delTypeList(row.id, false)" |
| 199 | > | 191 | > |
| 200 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} | 192 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} |
| 201 | </el-button> | 193 | </el-button> |
| @@ -252,7 +244,7 @@ onMounted(async () => { | @@ -252,7 +244,7 @@ onMounted(async () => { | ||
| 252 | link | 244 | link |
| 253 | type="primary" | 245 | type="primary" |
| 254 | v-hasPermi="['system:dict:delete']" | 246 | v-hasPermi="['system:dict:delete']" |
| 255 | - @click="handleDataDelete(row)" | 247 | + @click="delDataList(row.id, false)" |
| 256 | > | 248 | > |
| 257 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} | 249 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} |
| 258 | </el-button> | 250 | </el-button> |
yudao-ui-admin-vue3/src/views/system/errorCode/index.vue
| @@ -68,11 +68,6 @@ const submitForm = async () => { | @@ -68,11 +68,6 @@ const submitForm = async () => { | ||
| 68 | } | 68 | } |
| 69 | } | 69 | } |
| 70 | 70 | ||
| 71 | -// 删除操作 | ||
| 72 | -const handleDelete = (row: ErrorCodeVO) => { | ||
| 73 | - delList(row.id, false) | ||
| 74 | -} | ||
| 75 | - | ||
| 76 | // ========== 详情相关 ========== | 71 | // ========== 详情相关 ========== |
| 77 | const detailRef = ref() // 详情 Ref | 72 | const detailRef = ref() // 详情 Ref |
| 78 | 73 | ||
| @@ -139,7 +134,7 @@ getList() | @@ -139,7 +134,7 @@ getList() | ||
| 139 | link | 134 | link |
| 140 | type="primary" | 135 | type="primary" |
| 141 | v-hasPermi="['system:error-code:delete']" | 136 | v-hasPermi="['system:error-code:delete']" |
| 142 | - @click="handleDelete(row)" | 137 | + @click="delList(row.id, false)" |
| 143 | > | 138 | > |
| 144 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} | 139 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} |
| 145 | </el-button> | 140 | </el-button> |
yudao-ui-admin-vue3/src/views/system/notice/index.vue
| @@ -67,11 +67,6 @@ const submitForm = async () => { | @@ -67,11 +67,6 @@ const submitForm = async () => { | ||
| 67 | } | 67 | } |
| 68 | } | 68 | } |
| 69 | 69 | ||
| 70 | -// 删除操作 | ||
| 71 | -const handleDelete = (row: NoticeVO) => { | ||
| 72 | - delList(row.id, false) | ||
| 73 | -} | ||
| 74 | - | ||
| 75 | // ========== 详情相关 ========== | 70 | // ========== 详情相关 ========== |
| 76 | const detailRef = ref() // 详情 Ref | 71 | const detailRef = ref() // 详情 Ref |
| 77 | 72 | ||
| @@ -141,7 +136,7 @@ getList() | @@ -141,7 +136,7 @@ getList() | ||
| 141 | link | 136 | link |
| 142 | type="primary" | 137 | type="primary" |
| 143 | v-hasPermi="['system:notice:delete']" | 138 | v-hasPermi="['system:notice:delete']" |
| 144 | - @click="handleDelete(row)" | 139 | + @click="delList(row.id, false)" |
| 145 | > | 140 | > |
| 146 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} | 141 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} |
| 147 | </el-button> | 142 | </el-button> |
yudao-ui-admin-vue3/src/views/system/oauth2/client/index.vue
| @@ -68,11 +68,6 @@ const submitForm = async () => { | @@ -68,11 +68,6 @@ const submitForm = async () => { | ||
| 68 | } | 68 | } |
| 69 | } | 69 | } |
| 70 | 70 | ||
| 71 | -// 删除操作 | ||
| 72 | -const handleDelete = (row: OAuth2ClientVo) => { | ||
| 73 | - delList(row.id, false) | ||
| 74 | -} | ||
| 75 | - | ||
| 76 | // ========== 详情相关 ========== | 71 | // ========== 详情相关 ========== |
| 77 | const detailRef = ref() // 详情 Ref | 72 | const detailRef = ref() // 详情 Ref |
| 78 | 73 | ||
| @@ -152,7 +147,7 @@ getList() | @@ -152,7 +147,7 @@ getList() | ||
| 152 | link | 147 | link |
| 153 | type="primary" | 148 | type="primary" |
| 154 | v-hasPermi="['system:oauth2-client:delete']" | 149 | v-hasPermi="['system:oauth2-client:delete']" |
| 155 | - @click="handleDelete(row)" | 150 | + @click="delList(row.id, false)" |
| 156 | > | 151 | > |
| 157 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} | 152 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} |
| 158 | </el-button> | 153 | </el-button> |
yudao-ui-admin-vue3/src/views/system/operatelog/index.vue
| @@ -18,10 +18,6 @@ const detailRef = ref() // 详情 Ref | @@ -18,10 +18,6 @@ const detailRef = ref() // 详情 Ref | ||
| 18 | const dialogVisible = ref(false) // 是否显示弹出层 | 18 | const dialogVisible = ref(false) // 是否显示弹出层 |
| 19 | const dialogTitle = ref(t('action.detail')) // 弹出层标题 | 19 | const dialogTitle = ref(t('action.detail')) // 弹出层标题 |
| 20 | const { getList, setSearchParams, exportList } = methods | 20 | const { getList, setSearchParams, exportList } = methods |
| 21 | -// 导出操作 | ||
| 22 | -const handleExport = async () => { | ||
| 23 | - await exportList('操作日志.xls') | ||
| 24 | -} | ||
| 25 | // 详情 | 21 | // 详情 |
| 26 | const handleDetail = (row: OperateLogVO) => { | 22 | const handleDetail = (row: OperateLogVO) => { |
| 27 | // 设置数据 | 23 | // 设置数据 |
| @@ -41,7 +37,7 @@ getList() | @@ -41,7 +37,7 @@ getList() | ||
| 41 | type="warning" | 37 | type="warning" |
| 42 | v-hasPermi="['system:operate-log:export']" | 38 | v-hasPermi="['system:operate-log:export']" |
| 43 | :loading="tableObject.exportLoading" | 39 | :loading="tableObject.exportLoading" |
| 44 | - @click="handleExport" | 40 | + @click="exportList('操作日志.xls')" |
| 45 | > | 41 | > |
| 46 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} | 42 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} |
| 47 | </el-button> | 43 | </el-button> |
yudao-ui-admin-vue3/src/views/system/post/index.vue
| @@ -19,11 +19,6 @@ const { register, tableObject, methods } = useTable<PostVO>({ | @@ -19,11 +19,6 @@ const { register, tableObject, methods } = useTable<PostVO>({ | ||
| 19 | }) | 19 | }) |
| 20 | const { getList, setSearchParams, delList, exportList } = methods | 20 | const { getList, setSearchParams, delList, exportList } = methods |
| 21 | 21 | ||
| 22 | -// 导出操作 | ||
| 23 | -const handleExport = async () => { | ||
| 24 | - await exportList('岗位数据.xls') | ||
| 25 | -} | ||
| 26 | - | ||
| 27 | // ========== CRUD 相关 ========== | 22 | // ========== CRUD 相关 ========== |
| 28 | const actionLoading = ref(false) // 遮罩层 | 23 | const actionLoading = ref(false) // 遮罩层 |
| 29 | const actionType = ref('') // 操作按钮的类型 | 24 | const actionType = ref('') // 操作按钮的类型 |
| @@ -74,11 +69,6 @@ const submitForm = async () => { | @@ -74,11 +69,6 @@ const submitForm = async () => { | ||
| 74 | } | 69 | } |
| 75 | } | 70 | } |
| 76 | 71 | ||
| 77 | -// 删除操作 | ||
| 78 | -const handleDelete = (row: PostVO) => { | ||
| 79 | - delList(row.id, false) | ||
| 80 | -} | ||
| 81 | - | ||
| 82 | // ========== 详情相关 ========== | 72 | // ========== 详情相关 ========== |
| 83 | const detailRef = ref() // 详情 Ref | 73 | const detailRef = ref() // 详情 Ref |
| 84 | 74 | ||
| @@ -108,7 +98,7 @@ getList() | @@ -108,7 +98,7 @@ getList() | ||
| 108 | type="warning" | 98 | type="warning" |
| 109 | v-hasPermi="['system:post:export']" | 99 | v-hasPermi="['system:post:export']" |
| 110 | :loading="tableObject.exportLoading" | 100 | :loading="tableObject.exportLoading" |
| 111 | - @click="handleExport" | 101 | + @click="exportList('岗位数据.xls')" |
| 112 | > | 102 | > |
| 113 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} | 103 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} |
| 114 | </el-button> | 104 | </el-button> |
| @@ -153,7 +143,7 @@ getList() | @@ -153,7 +143,7 @@ getList() | ||
| 153 | link | 143 | link |
| 154 | type="primary" | 144 | type="primary" |
| 155 | v-hasPermi="['system:post:delete']" | 145 | v-hasPermi="['system:post:delete']" |
| 156 | - @click="handleDelete(row)" | 146 | + @click="delList(row.id, false)" |
| 157 | > | 147 | > |
| 158 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} | 148 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} |
| 159 | </el-button> | 149 | </el-button> |
yudao-ui-admin-vue3/src/views/system/role/index.vue
| @@ -83,11 +83,6 @@ const submitForm = async () => { | @@ -83,11 +83,6 @@ const submitForm = async () => { | ||
| 83 | } | 83 | } |
| 84 | } | 84 | } |
| 85 | 85 | ||
| 86 | -// 删除操作 | ||
| 87 | -const handleDelete = (row: RoleVO) => { | ||
| 88 | - delList(row.id, false) | ||
| 89 | -} | ||
| 90 | - | ||
| 91 | // ========== 详情相关 ========== | 86 | // ========== 详情相关 ========== |
| 92 | const detailRef = ref() // 详情 Ref | 87 | const detailRef = ref() // 详情 Ref |
| 93 | 88 | ||
| @@ -221,7 +216,7 @@ getList() | @@ -221,7 +216,7 @@ getList() | ||
| 221 | link | 216 | link |
| 222 | type="primary" | 217 | type="primary" |
| 223 | v-hasPermi="['system:role:delete']" | 218 | v-hasPermi="['system:role:delete']" |
| 224 | - @click="handleDelete(row)" | 219 | + @click="delList(row.id, false)" |
| 225 | > | 220 | > |
| 226 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} | 221 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} |
| 227 | </el-button> | 222 | </el-button> |
yudao-ui-admin-vue3/src/views/system/sensitiveWord/index.vue
| @@ -19,10 +19,6 @@ const { register, tableObject, methods } = useTable<SensitiveWordVO>({ | @@ -19,10 +19,6 @@ const { register, tableObject, methods } = useTable<SensitiveWordVO>({ | ||
| 19 | }) | 19 | }) |
| 20 | const { getList, setSearchParams, delList, exportList } = methods | 20 | const { getList, setSearchParams, delList, exportList } = methods |
| 21 | 21 | ||
| 22 | -// 导出操作 | ||
| 23 | -const handleExport = async () => { | ||
| 24 | - await exportList('敏感词数据.xls') | ||
| 25 | -} | ||
| 26 | // 获取标签 | 22 | // 获取标签 |
| 27 | const tagsOptions = ref() | 23 | const tagsOptions = ref() |
| 28 | const getTags = async () => { | 24 | const getTags = async () => { |
| @@ -79,11 +75,6 @@ const submitForm = async () => { | @@ -79,11 +75,6 @@ const submitForm = async () => { | ||
| 79 | } | 75 | } |
| 80 | } | 76 | } |
| 81 | 77 | ||
| 82 | -// 删除操作 | ||
| 83 | -const handleDelete = (row: SensitiveWordVO) => { | ||
| 84 | - delList(row.id, false) | ||
| 85 | -} | ||
| 86 | - | ||
| 87 | // ========== 详情相关 ========== | 78 | // ========== 详情相关 ========== |
| 88 | const detailRef = ref() // 详情 Ref | 79 | const detailRef = ref() // 详情 Ref |
| 89 | 80 | ||
| @@ -116,7 +107,7 @@ onMounted(async () => { | @@ -116,7 +107,7 @@ onMounted(async () => { | ||
| 116 | type="warning" | 107 | type="warning" |
| 117 | v-hasPermi="['system:post:export']" | 108 | v-hasPermi="['system:post:export']" |
| 118 | :loading="tableObject.exportLoading" | 109 | :loading="tableObject.exportLoading" |
| 119 | - @click="handleExport" | 110 | + @click="exportList('敏感词数据.xls')" |
| 120 | > | 111 | > |
| 121 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} | 112 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} |
| 122 | </el-button> | 113 | </el-button> |
| @@ -171,7 +162,7 @@ onMounted(async () => { | @@ -171,7 +162,7 @@ onMounted(async () => { | ||
| 171 | link | 162 | link |
| 172 | type="primary" | 163 | type="primary" |
| 173 | v-hasPermi="['system:post:delete']" | 164 | v-hasPermi="['system:post:delete']" |
| 174 | - @click="handleDelete(row)" | 165 | + @click="delList(row.id, false)" |
| 175 | > | 166 | > |
| 176 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} | 167 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} |
| 177 | </el-button> | 168 | </el-button> |
yudao-ui-admin-vue3/src/views/system/sms/smsChannel/index.vue
| @@ -68,11 +68,6 @@ const submitForm = async () => { | @@ -68,11 +68,6 @@ const submitForm = async () => { | ||
| 68 | } | 68 | } |
| 69 | } | 69 | } |
| 70 | 70 | ||
| 71 | -// 删除操作 | ||
| 72 | -const handleDelete = (row: SmsChannelVO) => { | ||
| 73 | - delList(row.id, false) | ||
| 74 | -} | ||
| 75 | - | ||
| 76 | // ========== 详情相关 ========== | 71 | // ========== 详情相关 ========== |
| 77 | const detailRef = ref() // 详情 Ref | 72 | const detailRef = ref() // 详情 Ref |
| 78 | 73 | ||
| @@ -142,7 +137,7 @@ getList() | @@ -142,7 +137,7 @@ getList() | ||
| 142 | link | 137 | link |
| 143 | type="primary" | 138 | type="primary" |
| 144 | v-hasPermi="['system:sms-channel:delete']" | 139 | v-hasPermi="['system:sms-channel:delete']" |
| 145 | - @click="handleDelete(row)" | 140 | + @click="delList(row.id, false)" |
| 146 | > | 141 | > |
| 147 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} | 142 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} |
| 148 | </el-button> | 143 | </el-button> |
yudao-ui-admin-vue3/src/views/system/sms/smsTemplate/index.vue
| @@ -68,11 +68,6 @@ const submitForm = async () => { | @@ -68,11 +68,6 @@ const submitForm = async () => { | ||
| 68 | } | 68 | } |
| 69 | } | 69 | } |
| 70 | 70 | ||
| 71 | -// 删除操作 | ||
| 72 | -const handleDelete = (row: SmsTemplateVO) => { | ||
| 73 | - delList(row.id, false) | ||
| 74 | -} | ||
| 75 | - | ||
| 76 | // ========== 详情相关 ========== | 71 | // ========== 详情相关 ========== |
| 77 | const detailRef = ref() // 详情 Ref | 72 | const detailRef = ref() // 详情 Ref |
| 78 | 73 | ||
| @@ -190,7 +185,7 @@ getList() | @@ -190,7 +185,7 @@ getList() | ||
| 190 | link | 185 | link |
| 191 | type="primary" | 186 | type="primary" |
| 192 | v-hasPermi="['system:sms-template:delete']" | 187 | v-hasPermi="['system:sms-template:delete']" |
| 193 | - @click="handleDelete(row)" | 188 | + @click="delList(row.id, false)" |
| 194 | > | 189 | > |
| 195 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} | 190 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} |
| 196 | </el-button> | 191 | </el-button> |
yudao-ui-admin-vue3/src/views/system/tenant/index.vue
| @@ -21,10 +21,6 @@ const { register, tableObject, methods } = useTable<TenantVO>({ | @@ -21,10 +21,6 @@ const { register, tableObject, methods } = useTable<TenantVO>({ | ||
| 21 | }) | 21 | }) |
| 22 | const { getList, setSearchParams, delList, exportList } = methods | 22 | const { getList, setSearchParams, delList, exportList } = methods |
| 23 | 23 | ||
| 24 | -// 导出操作 | ||
| 25 | -const handleExport = async () => { | ||
| 26 | - await exportList('租户数据.xls') | ||
| 27 | -} | ||
| 28 | // ========== 套餐 ========== | 24 | // ========== 套餐 ========== |
| 29 | const tenantPackageId = ref() // 套餐 | 25 | const tenantPackageId = ref() // 套餐 |
| 30 | const tenantPackageOptions = ref<TenantPackageVO[]>([]) //套餐列表 | 26 | const tenantPackageOptions = ref<TenantPackageVO[]>([]) //套餐列表 |
| @@ -97,11 +93,6 @@ const submitForm = async () => { | @@ -97,11 +93,6 @@ const submitForm = async () => { | ||
| 97 | } | 93 | } |
| 98 | } | 94 | } |
| 99 | 95 | ||
| 100 | -// 删除操作 | ||
| 101 | -const handleDelete = (row: TenantVO) => { | ||
| 102 | - delList(row.id, false) | ||
| 103 | -} | ||
| 104 | - | ||
| 105 | // ========== 详情相关 ========== | 96 | // ========== 详情相关 ========== |
| 106 | const detailRef = ref() // 详情 Ref | 97 | const detailRef = ref() // 详情 Ref |
| 107 | 98 | ||
| @@ -134,7 +125,7 @@ onMounted(async () => { | @@ -134,7 +125,7 @@ onMounted(async () => { | ||
| 134 | type="warning" | 125 | type="warning" |
| 135 | v-hasPermi="['system:tenant:export']" | 126 | v-hasPermi="['system:tenant:export']" |
| 136 | :loading="tableObject.exportLoading" | 127 | :loading="tableObject.exportLoading" |
| 137 | - @click="handleExport" | 128 | + @click="exportList('租户数据.xls')" |
| 138 | > | 129 | > |
| 139 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} | 130 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} |
| 140 | </el-button> | 131 | </el-button> |
| @@ -191,7 +182,7 @@ onMounted(async () => { | @@ -191,7 +182,7 @@ onMounted(async () => { | ||
| 191 | link | 182 | link |
| 192 | type="primary" | 183 | type="primary" |
| 193 | v-hasPermi="['system:tenant:delete']" | 184 | v-hasPermi="['system:tenant:delete']" |
| 194 | - @click="handleDelete(row)" | 185 | + @click="delList(row.id, false)" |
| 195 | > | 186 | > |
| 196 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} | 187 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} |
| 197 | </el-button> | 188 | </el-button> |
yudao-ui-admin-vue3/src/views/system/tenantPackage/index.vue
| @@ -101,11 +101,6 @@ const submitForm = async () => { | @@ -101,11 +101,6 @@ const submitForm = async () => { | ||
| 101 | } | 101 | } |
| 102 | } | 102 | } |
| 103 | 103 | ||
| 104 | -// 删除操作 | ||
| 105 | -const handleDelete = (row: TenantPackageVO) => { | ||
| 106 | - delList(row.id, false) | ||
| 107 | -} | ||
| 108 | - | ||
| 109 | // ========== 初始化 ========== | 104 | // ========== 初始化 ========== |
| 110 | onMounted(async () => { | 105 | onMounted(async () => { |
| 111 | await getList() | 106 | await getList() |
| @@ -149,7 +144,7 @@ onMounted(async () => { | @@ -149,7 +144,7 @@ onMounted(async () => { | ||
| 149 | <el-button link type="primary" @click="handleUpdate(row)"> | 144 | <el-button link type="primary" @click="handleUpdate(row)"> |
| 150 | <Icon icon="ep:edit" class="mr-1px" /> {{ t('action.edit') }} | 145 | <Icon icon="ep:edit" class="mr-1px" /> {{ t('action.edit') }} |
| 151 | </el-button> | 146 | </el-button> |
| 152 | - <el-button link type="primary" @click="handleDelete(row)"> | 147 | + <el-button link type="primary" @click="delList(row.id, false)"> |
| 153 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} | 148 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} |
| 154 | </el-button> | 149 | </el-button> |
| 155 | </template> | 150 | </template> |
yudao-ui-admin-vue3/src/views/system/user/index.vue
| @@ -164,15 +164,6 @@ const handleResetPwd = (row: UserVO) => { | @@ -164,15 +164,6 @@ const handleResetPwd = (row: UserVO) => { | ||
| 164 | }) | 164 | }) |
| 165 | }) | 165 | }) |
| 166 | } | 166 | } |
| 167 | -// 删除操作 | ||
| 168 | -const handleDelete = (row: UserVO) => { | ||
| 169 | - delList(row.id, false) | ||
| 170 | -} | ||
| 171 | - | ||
| 172 | -// 导出操作 | ||
| 173 | -const handleExport = async () => { | ||
| 174 | - await exportList('用户数据.xls') | ||
| 175 | -} | ||
| 176 | 167 | ||
| 177 | // ========== 详情相关 ========== | 168 | // ========== 详情相关 ========== |
| 178 | const detailRef = ref() | 169 | const detailRef = ref() |
| @@ -300,7 +291,11 @@ getList() | @@ -300,7 +291,11 @@ getList() | ||
| 300 | > | 291 | > |
| 301 | <Icon icon="ep:upload" class="mr-5px" /> {{ t('action.import') }} | 292 | <Icon icon="ep:upload" class="mr-5px" /> {{ t('action.import') }} |
| 302 | </el-button> | 293 | </el-button> |
| 303 | - <el-button type="warning" v-hasPermi="['system:user:export']" @click="handleExport"> | 294 | + <el-button |
| 295 | + type="warning" | ||
| 296 | + v-hasPermi="['system:user:export']" | ||
| 297 | + @click="exportList('用户数据.xls')" | ||
| 298 | + > | ||
| 304 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} | 299 | <Icon icon="ep:download" class="mr-5px" /> {{ t('action.export') }} |
| 305 | </el-button> | 300 | </el-button> |
| 306 | </div> | 301 | </div> |
| @@ -360,7 +355,7 @@ getList() | @@ -360,7 +355,7 @@ getList() | ||
| 360 | link | 355 | link |
| 361 | type="primary" | 356 | type="primary" |
| 362 | v-hasPermi="['system:user:delete']" | 357 | v-hasPermi="['system:user:delete']" |
| 363 | - @click="handleDelete(row)" | 358 | + @click="delList(row.id, false)" |
| 364 | > | 359 | > |
| 365 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} | 360 | <Icon icon="ep:delete" class="mr-1px" /> {{ t('action.del') }} |
| 366 | </el-button> | 361 | </el-button> |
yudao-ui-admin-vue3/vite.config.ts
| @@ -137,16 +137,19 @@ export default ({ command, mode }: ConfigEnv): UserConfig => { | @@ -137,16 +137,19 @@ export default ({ command, mode }: ConfigEnv): UserConfig => { | ||
| 137 | 'vue', | 137 | 'vue', |
| 138 | 'vue-router', | 138 | 'vue-router', |
| 139 | 'vue-types', | 139 | 'vue-types', |
| 140 | + 'vue-i18n', | ||
| 140 | 'element-plus/es/locale/lang/zh-cn', | 141 | 'element-plus/es/locale/lang/zh-cn', |
| 141 | 'element-plus/es/locale/lang/en', | 142 | 'element-plus/es/locale/lang/en', |
| 142 | '@iconify/iconify', | 143 | '@iconify/iconify', |
| 143 | '@vueuse/core', | 144 | '@vueuse/core', |
| 144 | 'axios', | 145 | 'axios', |
| 145 | 'qs', | 146 | 'qs', |
| 147 | + 'dayjs', | ||
| 146 | 'echarts', | 148 | 'echarts', |
| 147 | 'echarts-wordcloud', | 149 | 'echarts-wordcloud', |
| 148 | 'intro.js', | 150 | 'intro.js', |
| 149 | 'qrcode', | 151 | 'qrcode', |
| 152 | + 'pinia', | ||
| 150 | '@wangeditor/editor', | 153 | '@wangeditor/editor', |
| 151 | '@wangeditor/editor-for-vue' | 154 | '@wangeditor/editor-for-vue' |
| 152 | ] | 155 | ] |
yudao-ui-admin/src/views/bpm/form/index.vue
| @@ -101,10 +101,8 @@ export default { | @@ -101,10 +101,8 @@ export default { | ||
| 101 | /** 查询列表 */ | 101 | /** 查询列表 */ |
| 102 | getList() { | 102 | getList() { |
| 103 | this.loading = true; | 103 | this.loading = true; |
| 104 | - // 处理查询参数 | ||
| 105 | - let params = {...this.queryParams}; | ||
| 106 | // 执行查询 | 104 | // 执行查询 |
| 107 | - getFormPage(params).then(response => { | 105 | + getFormPage(this.queryParams).then(response => { |
| 108 | this.list = response.data.list; | 106 | this.list = response.data.list; |
| 109 | this.total = response.data.total; | 107 | this.total = response.data.total; |
| 110 | this.loading = false; | 108 | this.loading = false; |
yudao-ui-admin/src/views/bpm/model/index.vue
| @@ -121,7 +121,7 @@ | @@ -121,7 +121,7 @@ | ||
| 121 | <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body> | 121 | <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body> |
| 122 | <el-form ref="form" :model="form" :rules="rules" label-width="110px"> | 122 | <el-form ref="form" :model="form" :rules="rules" label-width="110px"> |
| 123 | <el-form-item label="流程标识" prop="key"> | 123 | <el-form-item label="流程标识" prop="key"> |
| 124 | - <el-input v-model="form.key" placeholder="请输入流标标识" style="width: 330px;" :disabled="form.id" /> | 124 | + <el-input v-model="form.key" placeholder="请输入流标标识" style="width: 330px;" :disabled="!!form.id" /> |
| 125 | <el-tooltip v-if="!form.id" class="item" effect="light" content="新建后,流程标识不可修改!" placement="top"> | 125 | <el-tooltip v-if="!form.id" class="item" effect="light" content="新建后,流程标识不可修改!" placement="top"> |
| 126 | <i style="padding-left: 5px;" class="el-icon-question" /> | 126 | <i style="padding-left: 5px;" class="el-icon-question" /> |
| 127 | </el-tooltip> | 127 | </el-tooltip> |
| @@ -130,7 +130,7 @@ | @@ -130,7 +130,7 @@ | ||
| 130 | </el-tooltip> | 130 | </el-tooltip> |
| 131 | </el-form-item> | 131 | </el-form-item> |
| 132 | <el-form-item label="流程名称" prop="name"> | 132 | <el-form-item label="流程名称" prop="name"> |
| 133 | - <el-input v-model="form.name" placeholder="请输入流程名称" :disabled="form.id" clearable /> | 133 | + <el-input v-model="form.name" placeholder="请输入流程名称" :disabled="!!form.id" clearable /> |
| 134 | </el-form-item> | 134 | </el-form-item> |
| 135 | <el-form-item v-if="form.id" label="流程分类" prop="category"> | 135 | <el-form-item v-if="form.id" label="流程分类" prop="category"> |
| 136 | <el-select v-model="form.category" placeholder="请选择流程分类" clearable style="width: 100%"> | 136 | <el-select v-model="form.category" placeholder="请选择流程分类" clearable style="width: 100%"> |
yudao-ui-admin/src/views/infra/file/index.vue
| @@ -131,7 +131,7 @@ export default { | @@ -131,7 +131,7 @@ export default { | ||
| 131 | getList() { | 131 | getList() { |
| 132 | this.loading = true; | 132 | this.loading = true; |
| 133 | // 执行查询 | 133 | // 执行查询 |
| 134 | - getFilePage(params).then(response => { | 134 | + getFilePage(this.queryParams).then(response => { |
| 135 | this.list = response.data.list; | 135 | this.list = response.data.list; |
| 136 | this.total = response.data.total; | 136 | this.total = response.data.total; |
| 137 | this.loading = false; | 137 | this.loading = false; |
yudao-ui-admin/src/views/mall/market/banner/index.vue
| @@ -165,7 +165,7 @@ export default { | @@ -165,7 +165,7 @@ export default { | ||
| 165 | getList() { | 165 | getList() { |
| 166 | this.loading = true; | 166 | this.loading = true; |
| 167 | // 执行查询 | 167 | // 执行查询 |
| 168 | - getBannerPage(params).then(response => { | 168 | + getBannerPage(this.queryParams).then(response => { |
| 169 | this.list = response.data.list; | 169 | this.list = response.data.list; |
| 170 | this.total = response.data.total; | 170 | this.total = response.data.total; |
| 171 | this.loading = false; | 171 | this.loading = false; |
yudao-ui-admin/src/views/mall/product/spu/index.vue
| @@ -571,7 +571,7 @@ | @@ -571,7 +571,7 @@ | ||
| 571 | getList() { | 571 | getList() { |
| 572 | this.loading = true; | 572 | this.loading = true; |
| 573 | // 执行查询 | 573 | // 执行查询 |
| 574 | - getSpuPage(params).then(response => { | 574 | + getSpuPage(this.queryParams).then(response => { |
| 575 | this.list = response.data.list; | 575 | this.list = response.data.list; |
| 576 | this.total = response.data.total; | 576 | this.total = response.data.total; |
| 577 | this.loading = false; | 577 | this.loading = false; |
yudao-ui-admin/src/views/system/oauth2/client/index.vue
| @@ -206,10 +206,8 @@ export default { | @@ -206,10 +206,8 @@ export default { | ||
| 206 | /** 查询列表 */ | 206 | /** 查询列表 */ |
| 207 | getList() { | 207 | getList() { |
| 208 | this.loading = true; | 208 | this.loading = true; |
| 209 | - // 处理查询参数 | ||
| 210 | - let params = {...this.queryParams}; | ||
| 211 | // 执行查询 | 209 | // 执行查询 |
| 212 | - getOAuth2ClientPage(params).then(response => { | 210 | + getOAuth2ClientPage(this.queryParams).then(response => { |
| 213 | this.list = response.data.list; | 211 | this.list = response.data.list; |
| 214 | this.total = response.data.total; | 212 | this.total = response.data.total; |
| 215 | this.loading = false; | 213 | this.loading = false; |