|
@ -12,27 +12,27 @@ |
|
|
<el-form class="-mb-15px" :model="queryParams" ref="queryFormRef" :inline="true" label-width="68px"> |
|
|
<el-form class="-mb-15px" :model="queryParams" ref="queryFormRef" :inline="true" label-width="68px"> |
|
|
<el-form-item label="用户名称" prop="username"> |
|
|
<el-form-item label="用户名称" prop="username"> |
|
|
<el-input v-model="queryParams.username" placeholder="请输入用户名称" clearable @keyup.enter="handleQuery" |
|
|
<el-input v-model="queryParams.username" placeholder="请输入用户名称" clearable @keyup.enter="handleQuery" |
|
|
class="!w-240px" /> |
|
|
class="!w-240px" /> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item label="手机号码" prop="mobile"> |
|
|
<el-form-item label="手机号码" prop="mobile"> |
|
|
<el-input v-model="queryParams.mobile" placeholder="请输入手机号码" clearable @keyup.enter="handleQuery" |
|
|
<el-input v-model="queryParams.mobile" placeholder="请输入手机号码" clearable @keyup.enter="handleQuery" |
|
|
class="!w-240px" /> |
|
|
class="!w-240px" /> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item label="状态" prop="status"> |
|
|
<el-form-item label="状态" prop="status"> |
|
|
<el-select v-model="queryParams.status" placeholder="用户状态" clearable class="!w-240px"> |
|
|
<el-select v-model="queryParams.status" placeholder="用户状态" clearable class="!w-240px"> |
|
|
<el-option v-for="dict in getIntDictOptions(DICT_TYPE.COMMON_STATUS)" :key="dict.value" :label="dict.label" |
|
|
<el-option v-for="dict in getIntDictOptions(DICT_TYPE.COMMON_STATUS)" :key="dict.value" :label="dict.label" |
|
|
:value="dict.value" /> |
|
|
:value="dict.value" /> |
|
|
</el-select> |
|
|
</el-select> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item label="创建时间" prop="createTime"> |
|
|
<el-form-item label="创建时间" prop="createTime"> |
|
|
<el-date-picker v-model="queryParams.createTime" value-format="YYYY-MM-DD HH:mm:ss" type="datetimerange" |
|
|
<el-date-picker v-model="queryParams.createTime" value-format="YYYY-MM-DD HH:mm:ss" type="datetimerange" |
|
|
start-placeholder="开始日期" end-placeholder="结束日期" class="!w-240px" /> |
|
|
start-placeholder="开始日期" end-placeholder="结束日期" class="!w-240px" /> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item> |
|
|
<el-form-item> |
|
|
<el-form-item label="用户昵称" prop="nickeName"> |
|
|
<el-form-item label="用户昵称" prop="nickeName"> |
|
|
<el-input v-model="queryParams.nickeName" placeholder="请输入用户昵称" clearable @keyup.enter="handleQuery" |
|
|
<el-input v-model="queryParams.nickeName" placeholder="请输入用户昵称" clearable @keyup.enter="handleQuery" |
|
|
class="!w-240px" /> |
|
|
class="!w-240px" /> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-button type="info" plain @click="handleQuery"> |
|
|
<el-button type="info" plain @click="handleQuery"> |
|
|
<Icon icon="ep:search" />搜索 |
|
|
<Icon icon="ep:search" />搜索 |
|
|
</el-button> |
|
|
</el-button> |
|
@ -61,7 +61,7 @@ |
|
|
<el-table-column label="状态" align="center" key="status"> |
|
|
<el-table-column label="状态" align="center" key="status"> |
|
|
<template #default="scope"> |
|
|
<template #default="scope"> |
|
|
<el-switch v-model="scope.row.status" :active-value="0" :inactive-value="1" |
|
|
<el-switch v-model="scope.row.status" :active-value="0" :inactive-value="1" |
|
|
@change="handleStatusChange(scope.row)" /> |
|
|
@change="handleStatusChange(scope.row)" /> |
|
|
</template> |
|
|
</template> |
|
|
</el-table-column> |
|
|
</el-table-column> |
|
|
<el-table-column label="创建时间" align="center" prop="createTime" :formatter="dateFormatter" width="180" /> |
|
|
<el-table-column label="创建时间" align="center" prop="createTime" :formatter="dateFormatter" width="180" /> |
|
@ -69,18 +69,18 @@ |
|
|
<template #default="scope"> |
|
|
<template #default="scope"> |
|
|
<div class="flex items-center justify-center"> |
|
|
<div class="flex items-center justify-center"> |
|
|
<el-button type="primary" link @click="openForm('update', scope.row.id)" |
|
|
<el-button type="primary" link @click="openForm('update', scope.row.id)" |
|
|
v-hasPermi="['system:user:update']"> |
|
|
v-hasPermi="['system:user:update']"> |
|
|
<Icon icon="ep:edit" />修改 |
|
|
<Icon icon="ep:edit" />修改 |
|
|
</el-button> |
|
|
</el-button> |
|
|
<el-button type="primary" link @click="handleResetPwd(scope.row)" |
|
|
<el-button type="primary" link @click="handleResetPwd(scope.row)" |
|
|
v-hasPermi="['system:user:update-password']"> |
|
|
v-hasPermi="['system:user:update-password']"> |
|
|
<Icon icon="ep:key" />重置密码 |
|
|
<Icon icon="ep:key" />重置密码 |
|
|
</el-button> |
|
|
</el-button> |
|
|
<el-button type="primary" link @click="handleRole(scope.row)" |
|
|
<el-button type="primary" link @click="handleRole(scope.row)" |
|
|
v-hasPermi="['system:permission:assign-user-role']"> |
|
|
v-hasPermi="['system:permission:assign-user-role']"> |
|
|
<Icon icon="ep:circle-check" />分配角色 |
|
|
<Icon icon="ep:circle-check" />分配角色 |
|
|
</el-button> |
|
|
</el-button> |
|
|
<el-button type="primary" link @click="handleFree(scope.row.id)"> |
|
|
<el-button type="primary" link @click="handleFree(scope.row.id)" v-hasPermi="['system:user:update-password']" v-if="userStore.getUser.userType=='MASTER'"> |
|
|
<Icon icon="ep:edit" />解冻 |
|
|
<Icon icon="ep:edit" />解冻 |
|
|
</el-button> |
|
|
</el-button> |
|
|
<el-button type="danger" link @click="handleDelete(scope.row.id)" v-hasPermi="['system:user:delete']"> |
|
|
<el-button type="danger" link @click="handleDelete(scope.row.id)" v-hasPermi="['system:user:delete']"> |
|
@ -91,15 +91,15 @@ |
|
|
</el-table-column> |
|
|
</el-table-column> |
|
|
</el-table> |
|
|
</el-table> |
|
|
<Pagination :total="total" v-model:page="queryParams.pageNo" v-model:limit="queryParams.pageSize" |
|
|
<Pagination :total="total" v-model:page="queryParams.pageNo" v-model:limit="queryParams.pageSize" |
|
|
@pagination="getList" /> |
|
|
@pagination="getList" /> |
|
|
</ContentWrap> |
|
|
</ContentWrap> |
|
|
</el-col> |
|
|
</el-col> |
|
|
</el-row> |
|
|
</el-row> |
|
|
|
|
|
|
|
|
<!-- 添加或修改用户对话框 --> |
|
|
<!-- 添加或修改用户对话框 --> |
|
|
<UserForm ref="formRef" @success="getList" /> |
|
|
<UserForm ref="formRef" @success="getList" /> |
|
|
<!-- 导入 --> |
|
|
<!-- 导入 --> |
|
|
<ImportForm ref="importFormRef" url="/system/user/import" :updateIsDisable='true' :coverIsDisable='true' :mode='2' :importTemplateData="importTemplateData" @success="importSuccess" /> |
|
|
<ImportForm ref="importFormRef" url="/system/user/import" :updateIsDisable='true' :coverIsDisable='true' :mode='2' :importTemplateData="importTemplateData" @success="importSuccess" /> |
|
|
|
|
|
|
|
|
<!-- 分配角色 --> |
|
|
<!-- 分配角色 --> |
|
|
<UserAssignRoleForm ref="assignRoleFormRef" @success="getList" /> |
|
|
<UserAssignRoleForm ref="assignRoleFormRef" @success="getList" /> |
|
@ -116,6 +116,9 @@ import UserImportForm from './UserImportForm.vue' |
|
|
import ImportForm from '@/components/ImportForm/src/ImportForm.vue' |
|
|
import ImportForm from '@/components/ImportForm/src/ImportForm.vue' |
|
|
import UserAssignRoleForm from './UserAssignRoleForm.vue' |
|
|
import UserAssignRoleForm from './UserAssignRoleForm.vue' |
|
|
import DeptTree from './DeptTree.vue' |
|
|
import DeptTree from './DeptTree.vue' |
|
|
|
|
|
|
|
|
|
|
|
import { useUserStore } from '@/store/modules/user' |
|
|
|
|
|
const userStore = useUserStore() |
|
|
import { usePageLoading } from '@/hooks/web/usePageLoading' |
|
|
import { usePageLoading } from '@/hooks/web/usePageLoading' |
|
|
const { loadStart, loadDone } = usePageLoading() |
|
|
const { loadStart, loadDone } = usePageLoading() |
|
|
defineOptions({ name: 'SystemUser' }) |
|
|
defineOptions({ name: 'SystemUser' }) |
|
|