Merge branch 'dev' of gitee.com:yudaocode/yudao-ui-admin-vue3 into dev
Signed-off-by: puhui999 <puhui999@163.com>
This commit is contained in:
commit
60daa54d3b
6
src/types/auto-components.d.ts
vendored
6
src/types/auto-components.d.ts
vendored
@ -52,13 +52,16 @@ declare module '@vue/runtime-core' {
|
|||||||
ElForm: typeof import('element-plus/es')['ElForm']
|
ElForm: typeof import('element-plus/es')['ElForm']
|
||||||
ElFormItem: typeof import('element-plus/es')['ElFormItem']
|
ElFormItem: typeof import('element-plus/es')['ElFormItem']
|
||||||
ElIcon: typeof import('element-plus/es')['ElIcon']
|
ElIcon: typeof import('element-plus/es')['ElIcon']
|
||||||
|
ElImage: typeof import('element-plus/es')['ElImage']
|
||||||
ElImageViewer: typeof import('element-plus/es')['ElImageViewer']
|
ElImageViewer: typeof import('element-plus/es')['ElImageViewer']
|
||||||
ElInput: typeof import('element-plus/es')['ElInput']
|
ElInput: typeof import('element-plus/es')['ElInput']
|
||||||
|
ElInputNumber: typeof import('element-plus/es')['ElInputNumber']
|
||||||
ElLink: typeof import('element-plus/es')['ElLink']
|
ElLink: typeof import('element-plus/es')['ElLink']
|
||||||
ElOption: typeof import('element-plus/es')['ElOption']
|
ElOption: typeof import('element-plus/es')['ElOption']
|
||||||
ElPagination: typeof import('element-plus/es')['ElPagination']
|
ElPagination: typeof import('element-plus/es')['ElPagination']
|
||||||
ElPopover: typeof import('element-plus/es')['ElPopover']
|
ElPopover: typeof import('element-plus/es')['ElPopover']
|
||||||
ElRadio: typeof import('element-plus/es')['ElRadio']
|
ElRadio: typeof import('element-plus/es')['ElRadio']
|
||||||
|
ElRadioButton: typeof import('element-plus/es')['ElRadioButton']
|
||||||
ElRadioGroup: typeof import('element-plus/es')['ElRadioGroup']
|
ElRadioGroup: typeof import('element-plus/es')['ElRadioGroup']
|
||||||
ElRow: typeof import('element-plus/es')['ElRow']
|
ElRow: typeof import('element-plus/es')['ElRow']
|
||||||
ElScrollbar: typeof import('element-plus/es')['ElScrollbar']
|
ElScrollbar: typeof import('element-plus/es')['ElScrollbar']
|
||||||
@ -69,6 +72,9 @@ declare module '@vue/runtime-core' {
|
|||||||
ElTableColumn: typeof import('element-plus/es')['ElTableColumn']
|
ElTableColumn: typeof import('element-plus/es')['ElTableColumn']
|
||||||
ElTabPane: typeof import('element-plus/es')['ElTabPane']
|
ElTabPane: typeof import('element-plus/es')['ElTabPane']
|
||||||
ElTabs: typeof import('element-plus/es')['ElTabs']
|
ElTabs: typeof import('element-plus/es')['ElTabs']
|
||||||
|
ElTag: typeof import('element-plus/es')['ElTag']
|
||||||
|
ElTimeline: typeof import('element-plus/es')['ElTimeline']
|
||||||
|
ElTimelineItem: typeof import('element-plus/es')['ElTimelineItem']
|
||||||
ElTooltip: typeof import('element-plus/es')['ElTooltip']
|
ElTooltip: typeof import('element-plus/es')['ElTooltip']
|
||||||
ElTreeSelect: typeof import('element-plus/es')['ElTreeSelect']
|
ElTreeSelect: typeof import('element-plus/es')['ElTreeSelect']
|
||||||
ElUpload: typeof import('element-plus/es')['ElUpload']
|
ElUpload: typeof import('element-plus/es')['ElUpload']
|
||||||
|
@ -69,7 +69,6 @@ import * as TenantPackageApi from '@/api/system/tenantPackage'
|
|||||||
import * as MenuApi from '@/api/system/menu'
|
import * as MenuApi from '@/api/system/menu'
|
||||||
import { ElTree } from 'element-plus'
|
import { ElTree } from 'element-plus'
|
||||||
import { handleTree } from '@/utils/tree'
|
import { handleTree } from '@/utils/tree'
|
||||||
|
|
||||||
const { t } = useI18n() // 国际化
|
const { t } = useI18n() // 国际化
|
||||||
const message = useMessage() // 消息弹窗
|
const message = useMessage() // 消息弹窗
|
||||||
|
|
||||||
@ -92,7 +91,7 @@ const formRules = reactive({
|
|||||||
const formRef = ref() // 表单 Ref
|
const formRef = ref() // 表单 Ref
|
||||||
const menuOptions = ref<any[]>([]) // 树形结构数据
|
const menuOptions = ref<any[]>([]) // 树形结构数据
|
||||||
const menuExpand = ref(false) // 展开/折叠
|
const menuExpand = ref(false) // 展开/折叠
|
||||||
const treeRef = ref<InstanceType<typeof ElTree>>() // 树组件Ref
|
const treeRef = ref<InstanceType<typeof ElTree>>() // 树组件 Ref
|
||||||
const treeNodeAll = ref(false) // 全选/全不选
|
const treeNodeAll = ref(false) // 全选/全不选
|
||||||
|
|
||||||
/** 打开弹窗 */
|
/** 打开弹窗 */
|
||||||
@ -133,8 +132,8 @@ const submitForm = async () => {
|
|||||||
try {
|
try {
|
||||||
const data = formData.value as unknown as TenantPackageApi.TenantPackageVO
|
const data = formData.value as unknown as TenantPackageApi.TenantPackageVO
|
||||||
data.menuIds = [
|
data.menuIds = [
|
||||||
...(treeRef.value!.getCheckedKeys(false) as unknown as Array<number>), // 获得当前选中节点
|
...(treeRef.value.getCheckedKeys(false) as unknown as Array<number>), // 获得当前选中节点
|
||||||
...(treeRef.value!.getHalfCheckedKeys() as unknown as Array<number>) // 获得半选中的父节点
|
...(treeRef.value.getHalfCheckedKeys() as unknown as Array<number>) // 获得半选中的父节点
|
||||||
]
|
]
|
||||||
if (formType.value === 'create') {
|
if (formType.value === 'create') {
|
||||||
await TenantPackageApi.createTenantPackage(data)
|
await TenantPackageApi.createTenantPackage(data)
|
||||||
@ -168,17 +167,19 @@ const resetForm = () => {
|
|||||||
formRef.value?.resetFields()
|
formRef.value?.resetFields()
|
||||||
}
|
}
|
||||||
|
|
||||||
// 全选/全不选
|
/** 全选/全不选 */
|
||||||
const handleCheckedTreeNodeAll = () => {
|
const handleCheckedTreeNodeAll = () => {
|
||||||
treeRef.value!.setCheckedNodes(treeNodeAll.value ? menuOptions.value : [])
|
treeRef.value.setCheckedNodes(treeNodeAll.value ? menuOptions.value : [])
|
||||||
}
|
}
|
||||||
|
|
||||||
// 全部(展开/折叠)TODO:for循环全部展开和折叠树组件数据
|
/** 展开/折叠全部 */
|
||||||
const handleCheckedTreeExpand = () => {
|
const handleCheckedTreeExpand = () => {
|
||||||
const nodes = treeRef.value?.store.nodesMap
|
const nodes = treeRef.value?.store.nodesMap
|
||||||
for (let node in nodes) {
|
for (let node in nodes) {
|
||||||
if (nodes[node].expanded === menuExpand.value) continue
|
if (nodes[node].expanded === menuExpand.value) {
|
||||||
nodes[node].expanded = !nodes[node].expanded
|
continue
|
||||||
|
}
|
||||||
|
nodes[node].expanded = menuExpand.value
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
@ -1,231 +1,220 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="app-container">
|
<!-- 搜索工作栏 -->
|
||||||
<content-wrap>
|
<el-row :gutter="20">
|
||||||
<!-- 搜索工作栏 -->
|
<!--部门数据-->
|
||||||
<el-row :gutter="20">
|
<el-col :span="4" :xs="24">
|
||||||
<!--部门数据-->
|
<content-wrap class="h-1/1">
|
||||||
<el-col :span="4" :xs="24">
|
<UserDeptTree @node-click="handleDeptNodeClick" />
|
||||||
<UserDeptTree @node-click="handleDeptNodeClick" />
|
</content-wrap>
|
||||||
</el-col>
|
</el-col>
|
||||||
<!--用户数据-->
|
<!--用户数据-->
|
||||||
<el-col :span="20" :xs="24">
|
<el-col :span="20" :xs="24">
|
||||||
<el-form
|
<content-wrap>
|
||||||
:model="queryParams"
|
<el-form
|
||||||
ref="queryFormRef"
|
:model="queryParams"
|
||||||
:inline="true"
|
ref="queryFormRef"
|
||||||
v-show="showSearch"
|
:inline="true"
|
||||||
label-width="68px"
|
v-show="showSearch"
|
||||||
>
|
label-width="68px"
|
||||||
<el-form-item label="用户名称" prop="username">
|
>
|
||||||
<el-input
|
<el-form-item label="用户名称" prop="username">
|
||||||
v-model="queryParams.username"
|
<el-input
|
||||||
placeholder="请输入用户名称"
|
v-model="queryParams.username"
|
||||||
clearable
|
placeholder="请输入用户名称"
|
||||||
style="width: 240px"
|
clearable
|
||||||
@keyup.enter="handleQuery"
|
style="width: 240px"
|
||||||
/>
|
@keyup.enter="handleQuery"
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="手机号码" prop="mobile">
|
|
||||||
<el-input
|
|
||||||
v-model="queryParams.mobile"
|
|
||||||
placeholder="请输入手机号码"
|
|
||||||
clearable
|
|
||||||
style="width: 240px"
|
|
||||||
@keyup.enter="handleQuery"
|
|
||||||
/>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="状态" prop="status">
|
|
||||||
<el-select
|
|
||||||
v-model="queryParams.status"
|
|
||||||
placeholder="用户状态"
|
|
||||||
clearable
|
|
||||||
style="width: 240px"
|
|
||||||
>
|
|
||||||
<el-option
|
|
||||||
v-for="dict in getIntDictOptions(DICT_TYPE.COMMON_STATUS)"
|
|
||||||
:key="dict.value as number"
|
|
||||||
:label="dict.label"
|
|
||||||
:value="dict.value as number"
|
|
||||||
/>
|
|
||||||
</el-select>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="创建时间" prop="createTime">
|
|
||||||
<el-date-picker
|
|
||||||
v-model="queryParams.createTime"
|
|
||||||
style="width: 240px"
|
|
||||||
value-format="YYYY-MM-DD HH:mm:ss"
|
|
||||||
type="datetimerange"
|
|
||||||
range-separator="-"
|
|
||||||
start-placeholder="开始日期"
|
|
||||||
end-placeholder="结束日期"
|
|
||||||
/>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item>
|
|
||||||
<el-button type="primary" @click="handleQuery"
|
|
||||||
><Icon icon="ep:search" />搜索</el-button
|
|
||||||
>
|
|
||||||
<el-button @click="resetQuery"><Icon icon="ep:refresh" />重置</el-button>
|
|
||||||
</el-form-item>
|
|
||||||
</el-form>
|
|
||||||
|
|
||||||
<el-row :gutter="10" class="mb-8px">
|
|
||||||
<el-col :span="1.5">
|
|
||||||
<el-button
|
|
||||||
type="primary"
|
|
||||||
plain
|
|
||||||
size="small"
|
|
||||||
@click="handleAdd"
|
|
||||||
v-hasPermi="['system:user:create']"
|
|
||||||
><Icon icon="ep:plus" />新增</el-button
|
|
||||||
>
|
|
||||||
</el-col>
|
|
||||||
<el-col :span="1.5">
|
|
||||||
<el-button
|
|
||||||
type="info"
|
|
||||||
size="small"
|
|
||||||
@click="handleImport"
|
|
||||||
v-hasPermi="['system:user:import']"
|
|
||||||
><Icon icon="ep:upload" />导入</el-button
|
|
||||||
>
|
|
||||||
</el-col>
|
|
||||||
<el-col :span="1.5">
|
|
||||||
<el-button
|
|
||||||
type="warning"
|
|
||||||
size="small"
|
|
||||||
@click="handleExport"
|
|
||||||
:loading="exportLoading"
|
|
||||||
v-hasPermi="['system:user:export']"
|
|
||||||
><Icon icon="ep:download" />导出</el-button
|
|
||||||
>
|
|
||||||
</el-col>
|
|
||||||
</el-row>
|
|
||||||
<el-table v-loading="loading" :data="userList">
|
|
||||||
<el-table-column
|
|
||||||
label="用户编号"
|
|
||||||
align="center"
|
|
||||||
key="id"
|
|
||||||
prop="id"
|
|
||||||
v-if="columns[0].visible"
|
|
||||||
/>
|
/>
|
||||||
<el-table-column
|
</el-form-item>
|
||||||
label="用户名称"
|
<el-form-item label="手机号码" prop="mobile">
|
||||||
align="center"
|
<el-input
|
||||||
key="username"
|
v-model="queryParams.mobile"
|
||||||
prop="username"
|
placeholder="请输入手机号码"
|
||||||
v-if="columns[1].visible"
|
clearable
|
||||||
:show-overflow-tooltip="true"
|
style="width: 240px"
|
||||||
|
@keyup.enter="handleQuery"
|
||||||
/>
|
/>
|
||||||
<el-table-column
|
</el-form-item>
|
||||||
label="用户昵称"
|
<el-form-item label="状态" prop="status">
|
||||||
align="center"
|
<el-select
|
||||||
key="nickname"
|
v-model="queryParams.status"
|
||||||
prop="nickname"
|
placeholder="用户状态"
|
||||||
v-if="columns[2].visible"
|
clearable
|
||||||
:show-overflow-tooltip="true"
|
style="width: 240px"
|
||||||
/>
|
|
||||||
<el-table-column
|
|
||||||
label="部门"
|
|
||||||
align="center"
|
|
||||||
key="deptName"
|
|
||||||
prop="dept.name"
|
|
||||||
v-if="columns[3].visible"
|
|
||||||
:show-overflow-tooltip="true"
|
|
||||||
/>
|
|
||||||
<el-table-column
|
|
||||||
label="手机号码"
|
|
||||||
align="center"
|
|
||||||
key="mobile"
|
|
||||||
prop="mobile"
|
|
||||||
v-if="columns[4].visible"
|
|
||||||
width="120"
|
|
||||||
/>
|
|
||||||
<el-table-column label="状态" key="status" v-if="columns[5].visible" align="center">
|
|
||||||
<template #default="scope">
|
|
||||||
<el-switch
|
|
||||||
v-model="scope.row.status"
|
|
||||||
:active-value="0"
|
|
||||||
:inactive-value="1"
|
|
||||||
@change="handleStatusChange(scope.row)"
|
|
||||||
/>
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column
|
|
||||||
label="创建时间"
|
|
||||||
align="center"
|
|
||||||
prop="createTime"
|
|
||||||
v-if="columns[6].visible"
|
|
||||||
width="160"
|
|
||||||
>
|
>
|
||||||
<template #default="scope">
|
<el-option
|
||||||
<span>{{ parseTime(scope.row.createTime) }}</span>
|
v-for="dict in getIntDictOptions(DICT_TYPE.COMMON_STATUS)"
|
||||||
</template>
|
:key="dict.value"
|
||||||
</el-table-column>
|
:label="dict.label"
|
||||||
<el-table-column
|
:value="dict.value"
|
||||||
label="操作"
|
/>
|
||||||
align="center"
|
</el-select>
|
||||||
width="160"
|
</el-form-item>
|
||||||
class-name="small-padding fixed-width"
|
<el-form-item label="创建时间" prop="createTime">
|
||||||
|
<el-date-picker
|
||||||
|
v-model="queryParams.createTime"
|
||||||
|
style="width: 240px"
|
||||||
|
value-format="YYYY-MM-DD HH:mm:ss"
|
||||||
|
type="datetimerange"
|
||||||
|
range-separator="-"
|
||||||
|
start-placeholder="开始日期"
|
||||||
|
end-placeholder="结束日期"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item>
|
||||||
|
<el-button type="primary" @click="handleQuery"><Icon icon="ep:search" />搜索</el-button>
|
||||||
|
<el-button @click="resetQuery"><Icon icon="ep:refresh" />重置</el-button>
|
||||||
|
<el-button type="primary" plain @click="handleAdd" v-hasPermi="['system:user:create']">
|
||||||
|
<Icon icon="ep:plus" /> 新增
|
||||||
|
</el-button>
|
||||||
|
<el-button
|
||||||
|
type="info"
|
||||||
|
size="small"
|
||||||
|
@click="handleImport"
|
||||||
|
v-hasPermi="['system:user:import']"
|
||||||
>
|
>
|
||||||
<template #default="scope">
|
<Icon icon="ep:upload" /> 导入
|
||||||
<div class="flex justify-center items-center">
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
type="primary"
|
type="warning"
|
||||||
link
|
size="small"
|
||||||
@click="handleUpdate(scope.row)"
|
@click="handleExport"
|
||||||
v-hasPermi="['system:user:update']"
|
:loading="exportLoading"
|
||||||
><Icon icon="ep:edit" />修改</el-button
|
v-hasPermi="['system:user:export']"
|
||||||
>
|
>
|
||||||
<el-dropdown
|
<Icon icon="ep:download" />导出
|
||||||
@command="(command) => handleCommand(command, scope.$index, scope.row)"
|
</el-button>
|
||||||
v-hasPermi="[
|
</el-form-item>
|
||||||
'system:user:delete',
|
</el-form>
|
||||||
'system:user:update-password',
|
</content-wrap>
|
||||||
'system:permission:assign-user-role'
|
<content-wrap>
|
||||||
]"
|
<el-table v-loading="loading" :data="userList">
|
||||||
>
|
<el-table-column
|
||||||
<el-button type="primary" link><Icon icon="ep:d-arrow-right" />更多</el-button>
|
label="用户编号"
|
||||||
<template #dropdown>
|
align="center"
|
||||||
<el-dropdown-menu>
|
key="id"
|
||||||
<!-- div包住避免控制台报错:Runtime directive used on component with non-element root node -->
|
prop="id"
|
||||||
<div v-if="scope.row.id !== 1" v-hasPermi="['system:user:delete']">
|
v-if="columns[0].visible"
|
||||||
<el-dropdown-item command="handleDelete" type="text"
|
|
||||||
><Icon icon="ep:delete" />删除</el-dropdown-item
|
|
||||||
>
|
|
||||||
</div>
|
|
||||||
<div v-hasPermi="['system:user:update-password']">
|
|
||||||
<el-dropdown-item command="handleResetPwd" type="text"
|
|
||||||
><Icon icon="ep:key" />重置密码</el-dropdown-item
|
|
||||||
></div
|
|
||||||
>
|
|
||||||
<div v-hasPermi="['system:permission:assign-user-role']">
|
|
||||||
<el-dropdown-item command="handleRole" type="text"
|
|
||||||
><Icon icon="ep:circle-check" />分配角色</el-dropdown-item
|
|
||||||
></div
|
|
||||||
>
|
|
||||||
</el-dropdown-menu>
|
|
||||||
</template>
|
|
||||||
</el-dropdown>
|
|
||||||
</div>
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
</el-table>
|
|
||||||
<pagination
|
|
||||||
v-show="total > 0"
|
|
||||||
:total="total"
|
|
||||||
v-model:page="queryParams.pageNo"
|
|
||||||
v-model:limit="queryParams.pageSize"
|
|
||||||
@pagination="getList"
|
|
||||||
/>
|
/>
|
||||||
</el-col>
|
<el-table-column
|
||||||
</el-row>
|
label="用户名称"
|
||||||
</content-wrap>
|
align="center"
|
||||||
<!-- 添加或修改用户对话框 -->
|
key="username"
|
||||||
<UserForm ref="userFormRef" @success="getList" />
|
prop="username"
|
||||||
<!-- 用户导入对话框 -->
|
v-if="columns[1].visible"
|
||||||
<UserImportForm ref="userImportFormRef" @success="getList" />
|
:show-overflow-tooltip="true"
|
||||||
<!-- 分配角色 -->
|
/>
|
||||||
<UserAssignRoleForm ref="userAssignRoleFormRef" @success="getList" />
|
<el-table-column
|
||||||
</div>
|
label="用户昵称"
|
||||||
|
align="center"
|
||||||
|
key="nickname"
|
||||||
|
prop="nickname"
|
||||||
|
v-if="columns[2].visible"
|
||||||
|
:show-overflow-tooltip="true"
|
||||||
|
/>
|
||||||
|
<el-table-column
|
||||||
|
label="部门"
|
||||||
|
align="center"
|
||||||
|
key="deptName"
|
||||||
|
prop="dept.name"
|
||||||
|
v-if="columns[3].visible"
|
||||||
|
:show-overflow-tooltip="true"
|
||||||
|
/>
|
||||||
|
<el-table-column
|
||||||
|
label="手机号码"
|
||||||
|
align="center"
|
||||||
|
key="mobile"
|
||||||
|
prop="mobile"
|
||||||
|
v-if="columns[4].visible"
|
||||||
|
width="120"
|
||||||
|
/>
|
||||||
|
<el-table-column label="状态" key="status" v-if="columns[5].visible" align="center">
|
||||||
|
<template #default="scope">
|
||||||
|
<el-switch
|
||||||
|
v-model="scope.row.status"
|
||||||
|
:active-value="0"
|
||||||
|
:inactive-value="1"
|
||||||
|
@change="handleStatusChange(scope.row)"
|
||||||
|
/>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column
|
||||||
|
label="创建时间"
|
||||||
|
align="center"
|
||||||
|
prop="createTime"
|
||||||
|
v-if="columns[6].visible"
|
||||||
|
width="160"
|
||||||
|
>
|
||||||
|
<template #default="scope">
|
||||||
|
<span>{{ parseTime(scope.row.createTime) }}</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column
|
||||||
|
label="操作"
|
||||||
|
align="center"
|
||||||
|
width="160"
|
||||||
|
class-name="small-padding fixed-width"
|
||||||
|
>
|
||||||
|
<template #default="scope">
|
||||||
|
<div class="flex justify-center items-center">
|
||||||
|
<el-button
|
||||||
|
type="primary"
|
||||||
|
link
|
||||||
|
@click="handleUpdate(scope.row)"
|
||||||
|
v-hasPermi="['system:user:update']"
|
||||||
|
><Icon icon="ep:edit" />修改</el-button
|
||||||
|
>
|
||||||
|
<el-dropdown
|
||||||
|
@command="(command) => handleCommand(command, scope.$index, scope.row)"
|
||||||
|
v-hasPermi="[
|
||||||
|
'system:user:delete',
|
||||||
|
'system:user:update-password',
|
||||||
|
'system:permission:assign-user-role'
|
||||||
|
]"
|
||||||
|
>
|
||||||
|
<el-button type="primary" link><Icon icon="ep:d-arrow-right" />更多</el-button>
|
||||||
|
<template #dropdown>
|
||||||
|
<el-dropdown-menu>
|
||||||
|
<!-- div包住避免控制台报错:Runtime directive used on component with non-element root node -->
|
||||||
|
<div v-if="scope.row.id !== 1" v-hasPermi="['system:user:delete']">
|
||||||
|
<el-dropdown-item command="handleDelete" type="text"
|
||||||
|
><Icon icon="ep:delete" />删除</el-dropdown-item
|
||||||
|
>
|
||||||
|
</div>
|
||||||
|
<div v-hasPermi="['system:user:update-password']">
|
||||||
|
<el-dropdown-item command="handleResetPwd" type="text"
|
||||||
|
><Icon icon="ep:key" />重置密码</el-dropdown-item
|
||||||
|
></div
|
||||||
|
>
|
||||||
|
<div v-hasPermi="['system:permission:assign-user-role']">
|
||||||
|
<el-dropdown-item command="handleRole" type="text"
|
||||||
|
><Icon icon="ep:circle-check" />分配角色</el-dropdown-item
|
||||||
|
></div
|
||||||
|
>
|
||||||
|
</el-dropdown-menu>
|
||||||
|
</template>
|
||||||
|
</el-dropdown>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
<pagination
|
||||||
|
v-show="total > 0"
|
||||||
|
:total="total"
|
||||||
|
v-model:page="queryParams.pageNo"
|
||||||
|
v-model:limit="queryParams.pageSize"
|
||||||
|
@pagination="getList"
|
||||||
|
/>
|
||||||
|
</content-wrap>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<!-- 添加或修改用户对话框 -->
|
||||||
|
<UserForm ref="userFormRef" @success="getList" />
|
||||||
|
<!-- 用户导入对话框 -->
|
||||||
|
<UserImportForm ref="userImportFormRef" @success="getList" />
|
||||||
|
<!-- 分配角色 -->
|
||||||
|
<UserAssignRoleForm ref="userAssignRoleFormRef" @success="getList" />
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts" name="User">
|
<script setup lang="ts" name="User">
|
||||||
@ -280,7 +269,8 @@ const columns = ref([
|
|||||||
{ key: 5, label: `状态`, visible: true },
|
{ key: 5, label: `状态`, visible: true },
|
||||||
{ key: 6, label: `创建时间`, visible: true }
|
{ key: 6, label: `创建时间`, visible: true }
|
||||||
])
|
])
|
||||||
/* 查询列表 */
|
|
||||||
|
/** 查询列表 */
|
||||||
const getList = () => {
|
const getList = () => {
|
||||||
loading.value = true
|
loading.value = true
|
||||||
getUserPageApi(queryParams).then((response) => {
|
getUserPageApi(queryParams).then((response) => {
|
||||||
@ -289,6 +279,7 @@ const getList = () => {
|
|||||||
loading.value = false
|
loading.value = false
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
/** 搜索按钮操作 */
|
/** 搜索按钮操作 */
|
||||||
const handleQuery = () => {
|
const handleQuery = () => {
|
||||||
queryParams.pageNo = 1
|
queryParams.pageNo = 1
|
||||||
|
Loading…
Reference in New Issue
Block a user