67
67
style =" width : 120px "
68
68
@change =" search_type_change"
69
69
>
70
- <el-option :label =" $t('views.login.loginForm.username.label')" value =" username" />
71
- <el-option :label =" $t('views.userManage.userForm.nick_name.label')" value =" nick_name" />
72
- <el-option :label =" $t('common.status.label')" value =" is_active" />
73
- <el-option
74
- :label =" $t('views.userManage.source.label')"
75
- value =" source"
76
- />
70
+ <el-option :label =" $t('views.login.loginForm.username.label')" value =" username" />
71
+ <el-option :label =" $t('views.userManage.userForm.nick_name.label')" value =" nick_name" />
72
+ <el-option :label =" $t('common.status.label')" value =" is_active" />
73
+ <el-option :label =" $t('views.userManage.source.label')" value =" source" />
77
74
</el-select >
78
75
<el-input
79
76
v-if =" search_type === 'username'"
96
93
clearable
97
94
style =" width : 220px "
98
95
>
99
- <el-option :label =" $t('common.status.enabled')" :value =" true" />
100
- <el-option :label =" $t('common.status.disabled')" :value =" false" />
96
+ <el-option :label =" $t('common.status.enabled')" :value =" true" />
97
+ <el-option :label =" $t('common.status.disabled')" :value =" false" />
101
98
</el-select >
102
99
<el-select
103
100
v-else-if =" search_type === 'source'"
107
104
clearable
108
105
:placeholder =" $t('common.inputPlaceholder')"
109
106
>
110
- <el-option :label =" $t('views.userManage.source.local')" value =" LOCAL" />
111
- <el-option label =" CAS" value =" CAS" />
112
- <el-option label =" LDAP" value =" LDAP" />
113
- <el-option label =" OIDC" value =" OIDC" />
114
- <el-option label =" OAuth2" value =" OAuth2" />
115
- <el-option :label =" $t('views.userManage.source.wecom')" value =" wecom" />
116
- <el-option :label =" $t('views.userManage.source.lark')" value =" lark" />
117
- <el-option :label =" $t('views.userManage.source.dingtalk')" value =" dingtalk" />
107
+ <el-option :label =" $t('views.userManage.source.local')" value =" LOCAL" />
108
+ <el-option label =" CAS" value =" CAS" />
109
+ <el-option label =" LDAP" value =" LDAP" />
110
+ <el-option label =" OIDC" value =" OIDC" />
111
+ <el-option label =" OAuth2" value =" OAuth2" />
112
+ <el-option :label =" $t('views.userManage.source.wecom')" value =" wecom" />
113
+ <el-option :label =" $t('views.userManage.source.lark')" value =" lark" />
114
+ <el-option :label =" $t('views.userManage.source.dingtalk')" value =" dingtalk" />
118
115
</el-select >
119
116
</div >
120
117
</div >
129
126
@sort-change =" handleSortChange"
130
127
:maxTableHeight =" 270"
131
128
>
132
- <el-table-column type =" selection" width =" 55" />
129
+ <el-table-column type =" selection" width =" 55" />
133
130
<el-table-column
134
131
prop =" nick_name"
135
132
:label =" $t('views.userManage.userForm.nick_name.label')"
146
143
<template #default =" { row } " >
147
144
<div v-if =" row.is_active" class =" flex align-center" >
148
145
<el-icon class =" color-success mr-8" style =" font-size : 16px " >
149
- <SuccessFilled />
146
+ <SuccessFilled />
150
147
</el-icon >
151
148
<span class =" color-secondary" >
152
149
{{ $t('common.status.enabled') }}
186
183
min-width =" 150"
187
184
>
188
185
<template #default =" { row } " >
189
- <TagGroup :tags =" row.user_group_names" />
186
+ <TagGroup :tags =" row.user_group_names" />
190
187
</template >
191
188
</el-table-column >
192
189
<el-table-column prop =" source" :label =" $t('views.userManage.source.label')" >
233
230
"
234
231
/>
235
232
</span >
236
- <el-divider direction =" vertical" />
233
+ <el-divider direction =" vertical" />
237
234
<span class =" mr-8" >
238
235
<el-button
239
236
type =" primary"
274
271
)
275
272
"
276
273
>
277
- <el-icon >
278
- <Lock />
279
- </el-icon >
274
+ <AppIcon iconName =" app-key" ></AppIcon >
280
275
</el-button >
281
276
</span >
282
277
<span >
316
311
ref =" UserDrawerRef"
317
312
@refresh =" refresh"
318
313
/>
319
- <UserPwdDialog ref =" UserPwdDialogRef" @refresh =" refresh" />
314
+ <UserPwdDialog ref =" UserPwdDialogRef" @refresh =" refresh" />
320
315
<SetUserGroupsDialog
321
316
:optionLoading =" optionLoading"
322
317
:chatGroupList =" chatGroupList"
323
318
ref =" setUserGroupsRef"
324
319
@refresh =" refresh"
325
320
/>
326
- <SyncUsersDialog ref =" syncUsersDialogRef" @refresh =" refresh" />
321
+ <SyncUsersDialog ref =" syncUsersDialogRef" @refresh =" refresh" />
327
322
</div >
328
323
</template >
329
324
330
325
<script lang="ts" setup>
331
- import {onMounted , ref , reactive } from ' vue'
326
+ import { onMounted , ref , reactive } from ' vue'
332
327
import UserDrawer from ' ./component/UserDrawer.vue'
333
328
import UserPwdDialog from ' ./component/UserPwdDialog.vue'
334
329
import SetUserGroupsDialog from ' ./component/SetUserGroupsDialog.vue'
335
330
import SyncUsersDialog from ' ./component/SyncUsersDialog.vue'
336
331
import userManageApi from ' @/api/system/chat-user'
337
- import {datetimeFormat } from ' @/utils/time'
338
- import {MsgSuccess , MsgConfirm } from ' @/utils/message'
339
- import {t } from ' @/locales'
340
- import type {ChatUserItem } from ' @/api/type/systemChatUser'
332
+ import { datetimeFormat } from ' @/utils/time'
333
+ import { MsgSuccess , MsgConfirm } from ' @/utils/message'
334
+ import { t } from ' @/locales'
335
+ import type { ChatUserItem } from ' @/api/type/systemChatUser'
341
336
import SystemGroupApi from ' @/api/system/user-group'
342
- import type {ListItem } from ' @/api/type/common'
343
- import {PermissionConst , RoleConst } from ' @/utils/permission/data'
344
- import {ComplexPermission } from ' @/utils/permission/type'
345
- import {hasPermission } from ' @/utils/permission'
346
- import {loadPermissionApi } from ' @/utils/dynamics-api/permission-api.ts'
337
+ import type { ListItem } from ' @/api/type/common'
338
+ import { PermissionConst , RoleConst } from ' @/utils/permission/data'
339
+ import { ComplexPermission } from ' @/utils/permission/type'
340
+ import { hasPermission } from ' @/utils/permission'
341
+ import { loadPermissionApi } from ' @/utils/dynamics-api/permission-api.ts'
347
342
348
343
const search_type = ref (' username' )
349
344
const search_form = ref <{
@@ -358,7 +353,7 @@ const search_form = ref<{
358
353
is_active: null ,
359
354
})
360
355
const search_type_change = () => {
361
- search_form .value = {username: ' ' , nick_name: ' ' , source: ' ' , is_active: null }
356
+ search_form .value = { username: ' ' , nick_name: ' ' , source: ' ' , is_active: null }
362
357
}
363
358
364
359
const loading = ref (false )
@@ -393,7 +388,7 @@ function getList() {
393
388
394
389
const orderBy = ref <string >(' ' )
395
390
396
- function handleSortChange({prop , order }: { prop: string ; order: string }) {
391
+ function handleSortChange({ prop , order }: { prop: string ; order: string }) {
397
392
orderBy .value = order === ' ascending' ? prop : ` -${prop } `
398
393
getList ()
399
394
}
@@ -448,8 +443,7 @@ function deleteUserManage(row: ChatUserItem) {
448
443
getList ()
449
444
})
450
445
})
451
- .catch (() => {
452
- })
446
+ .catch (() => {})
453
447
}
454
448
455
449
const UserPwdDialogRef = ref ()
@@ -480,7 +474,7 @@ async function getChatGroupList() {
480
474
}
481
475
482
476
function handleBatchDelete() {
483
- MsgConfirm (t (' views.chatUser.batchDeleteUser' , {count: multipleSelection .value .length }), ' ' , {
477
+ MsgConfirm (t (' views.chatUser.batchDeleteUser' , { count: multipleSelection .value .length }), ' ' , {
484
478
confirmButtonText: t (' common.confirm' ),
485
479
confirmButtonClass: ' danger' ,
486
480
})
@@ -495,8 +489,7 @@ function handleBatchDelete() {
495
489
await getList ()
496
490
})
497
491
})
498
- .catch (() => {
499
- })
492
+ .catch (() => {})
500
493
}
501
494
502
495
const setUserGroupsRef = ref <InstanceType <typeof SetUserGroupsDialog >>()
0 commit comments