Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
jinli gu
Litemall
Commits
490ebfb0
Commit
490ebfb0
authored
Apr 14, 2019
by
Junling Bu
Browse files
fix[litemall-admin]: 管理员角色名查询失败
parent
82a4a483
Changes
2
Hide whitespace changes
Inline
Side-by-side
litemall-admin/src/views/sys/role.vue
View file @
490ebfb0
...
...
@@ -3,7 +3,7 @@
<!-- 查询和其他操作 -->
<div
class=
"filter-container"
>
<el-input
v-model=
"listQuery.
role
name"
clearable
class=
"filter-item"
style=
"width: 200px;"
placeholder=
"请输入角色名称"
/>
<el-input
v-model=
"listQuery.name"
clearable
class=
"filter-item"
style=
"width: 200px;"
placeholder=
"请输入角色名称"
/>
<el-button
v-permission=
"['GET /admin/role/list']"
class=
"filter-item"
type=
"primary"
icon=
"el-icon-search"
@
click=
"handleFilter"
>
查找
</el-button>
<el-button
v-permission=
"['POST /admin/role/create']"
class=
"filter-item"
type=
"primary"
icon=
"el-icon-edit"
@
click=
"handleCreate"
>
添加
</el-button>
</div>
...
...
litemall-db/src/main/java/org/linlinjava/litemall/db/service/LitemallRoleService.java
View file @
490ebfb0
...
...
@@ -37,12 +37,12 @@ public class LitemallRoleService {
}
public
List
<
LitemallRole
>
querySelective
(
String
roleN
ame
,
Integer
page
,
Integer
size
,
String
sort
,
String
order
)
{
public
List
<
LitemallRole
>
querySelective
(
String
n
ame
,
Integer
page
,
Integer
size
,
String
sort
,
String
order
)
{
LitemallRoleExample
example
=
new
LitemallRoleExample
();
LitemallRoleExample
.
Criteria
criteria
=
example
.
createCriteria
();
if
(!
StringUtils
.
isEmpty
(
roleN
ame
))
{
criteria
.
andName
EqualTo
(
"%"
+
roleN
ame
+
"%"
);
if
(!
StringUtils
.
isEmpty
(
n
ame
))
{
criteria
.
andName
Like
(
"%"
+
n
ame
+
"%"
);
}
criteria
.
andDeletedEqualTo
(
false
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment