dev-cl
qsh 4 months ago
parent 518cddc93c
commit 6c035fa0d8
  1. 4
      src/config/axios/service.ts
  2. 2
      src/directives/permission/hasPermi.ts
  3. 7
      src/views/Basic/User/index.vue

@ -137,8 +137,8 @@ service.interceptors.response.use(
const code = data.code || result_code const code = data.code || result_code
// 二进制数据则直接返回 // 二进制数据则直接返回
if ( if (
response.request.responseType === 'blob' || response?.request?.responseType === 'blob' ||
response.request.responseType === 'arraybuffer' response?.request?.responseType === 'arraybuffer'
) { ) {
return response.data return response.data
} }

@ -8,7 +8,7 @@ export function hasPermi(app: App<Element>) {
const { wsCache } = useCache() const { wsCache } = useCache()
const { value } = binding const { value } = binding
const all_permission = '*:*:*' const all_permission = '*:*:*'
const permissions = wsCache.get(CACHE_KEY.USER).permissions const permissions = wsCache.get(CACHE_KEY.USER)?.permissions || []
if (value && value instanceof Array && value.length > 0) { if (value && value instanceof Array && value.length > 0) {
const permissionFlag = value const permissionFlag = value

@ -7,10 +7,10 @@
<el-col :span="20" :xs="24"> <el-col :span="20" :xs="24">
<!-- 搜索 --> <!-- 搜索 -->
<el-form :model="queryParams" ref="queryFormRef" inline label-width="68px"> <el-form :model="queryParams" ref="queryFormRef" inline label-width="68px">
<el-form-item label="登录账号" prop="username"> <el-form-item label="姓名" prop="nickname">
<el-input <el-input
v-model="queryParams.username" v-model="queryParams.nickname"
placeholder="请输入登录账号" placeholder="请输入姓名"
clearable clearable
@keyup.enter="handleQuery" @keyup.enter="handleQuery"
class="!w-240px" class="!w-240px"
@ -118,6 +118,7 @@ const queryParams = reactive({
pageNo: 1, pageNo: 1,
pageSize: 10, pageSize: 10,
username: undefined, username: undefined,
nickname: undefined,
mobile: undefined, mobile: undefined,
deptId: undefined deptId: undefined
}) })

Loading…
Cancel
Save