Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
D
dataease
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
njgzx
dataease
Commits
da60029e
Unverified
提交
da60029e
authored
11月 01, 2021
作者:
fit2cloud-chenyw
提交者:
GitHub
11月 01, 2021
浏览文件
操作
浏览文件
下载
差异文件
Merge pull request #1089 from dataease/pr@v1.4@feat_hide_role_org
feat: 开源版用户列表隐藏角色和组织
上级
3a671b21
fe340458
隐藏空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
18 行增加
和
7 行删除
+18
-7
form.vue
frontend/src/views/system/user/form.vue
+10
-3
index.vue
frontend/src/views/system/user/index.vue
+8
-4
没有找到文件。
frontend/src/views/system/user/form.vue
浏览文件 @
da60029e
...
...
@@ -32,7 +32,7 @@
<el-radio
:label=
"0"
>
{{
$t
(
'commons.disable'
)
}}
</el-radio>
</el-radio-group>
</el-form-item>
<el-form-item
:label=
"$t('commons.organization')"
prop=
"deptId"
>
<el-form-item
v-show=
"isPluginLoaded"
:label=
"$t('commons.organization')"
prop=
"deptId"
>
<treeselect
ref=
"deptTreeSelect"
v-model=
"form.deptId"
...
...
@@ -43,7 +43,7 @@
@
open=
"filterData"
/>
</el-form-item>
<el-form-item
:label=
"$t('commons.role')"
prop=
"roleIds"
>
<el-form-item
v-show=
"isPluginLoaded"
:label=
"$t('commons.role')"
prop=
"roleIds"
>
<el-select
ref=
"roleSelect"
v-model=
"form.roleIds"
...
...
@@ -76,6 +76,7 @@ import LayoutContent from '@/components/business/LayoutContent'
import
{
PHONE_REGEX
}
from
'@/utils/validate'
import
{
getDeptTree
,
treeByDeptId
}
from
'@/api/system/dept'
import
{
addUser
,
editUser
,
allRoles
}
from
'@/api/system/user'
import
{
pluginLoaded
}
from
'@/api/user'
export
default
{
components
:
{
LayoutContent
},
...
...
@@ -155,7 +156,8 @@ export default {
roles
:
[],
roleDatas
:
[],
userRoles
:
[],
formType
:
'add'
formType
:
'add'
,
isPluginLoaded
:
false
}
},
...
...
@@ -174,6 +176,11 @@ export default {
destroyed
()
{
this
.
unBindKey
()
},
beforeCreate
()
{
pluginLoaded
().
then
(
res
=>
{
this
.
isPluginLoaded
=
res
.
success
&&
res
.
data
})
},
methods
:
{
entryKey
(
event
)
{
const
keyCode
=
event
.
keyCode
...
...
frontend/src/views/system/user/index.vue
浏览文件 @
da60029e
...
...
@@ -27,12 +27,12 @@
</el-table-column>
<el-table-column
:show-overflow-tooltip=
"true"
prop=
"email"
:label=
"$t('commons.email')"
/>
<el-table-column
:show-overflow-tooltip=
"true"
prop=
"dept"
sortable=
"custom"
:label=
"$t('commons.organization')"
>
<el-table-column
v-if=
"isPluginLoaded"
:show-overflow-tooltip=
"true"
prop=
"dept"
sortable=
"custom"
:label=
"$t('commons.organization')"
>
<
template
slot-scope=
"scope"
>
<div>
{{
scope
.
row
.
dept
&&
scope
.
row
.
dept
.
deptName
}}
</div>
</
template
>
</el-table-column>
<el-table-column
prop=
"roles"
:label=
"$t('commons.role')"
>
<el-table-column
v-if=
"isPluginLoaded"
prop=
"roles"
:label=
"$t('commons.role')"
>
<
template
slot-scope=
"scope"
>
<div
v-if=
"scope.row.roles && scope.row.roles.length
<
=
2
"
>
<div
v-for=
"role in scope.row.roles"
:key=
"role.roleId"
>
{{
role
.
roleName
}}
</div>
...
...
@@ -174,7 +174,7 @@ import { PHONE_REGEX } from '@/utils/validate'
import
{
LOAD_CHILDREN_OPTIONS
,
LOAD_ROOT_OPTIONS
}
from
'@riophae/vue-treeselect'
import
Treeselect
from
'@riophae/vue-treeselect'
import
'@riophae/vue-treeselect/dist/vue-treeselect.css'
import
{
ldapStatus
}
from
'@/api/user'
import
{
ldapStatus
,
pluginLoaded
}
from
'@/api/user'
import
{
userLists
,
addUser
,
editUser
,
delUser
,
editPassword
,
editStatus
,
allRoles
}
from
'@/api/system/user'
import
{
getDeptTree
,
treeByDeptId
}
from
'@/api/system/dept'
...
...
@@ -306,7 +306,8 @@ export default {
},
orderConditions
:
[],
last_condition
:
null
,
openLdap
:
false
openLdap
:
false
,
isPluginLoaded
:
false
}
},
mounted
()
{
...
...
@@ -317,6 +318,9 @@ export default {
ldapStatus
().
then
(
res
=>
{
this
.
openLdap
=
res
.
success
&&
res
.
data
})
pluginLoaded
().
then
(
res
=>
{
this
.
isPluginLoaded
=
res
.
success
&&
res
.
data
})
},
methods
:
{
sortChange
({
column
,
prop
,
order
})
{
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论