Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
ethan
/
ant-admin-pro
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
Commit 43cd6632
authored
2018-02-06 14:55:07 +0800
by
ethanlamzs
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
优化显示
1 parent
4b6b865f
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
7 deletions
src/routes/devutil/schoolmgr.js
src/routes/devutil/schoolmgr.js
View file @
43cd663
...
...
@@ -222,9 +222,14 @@ export default class schoolmgr extends Component{
renderUserBelongGroupMath
=
(
departments
)
=>
(
departments
.
map
((
deparmentid
)
=>
{
const
{
groupsMap
}
=
this
.
state
;
return
<
span
key
=
{
`g_
${
deparmentid
}
`
}
>
{
groupsMap
[
deparmentid
]},
<
/span
>
;
return
<
em
key
=
{
`g_
${
deparmentid
}
`
}
><
font
size
=
"2"
color
=
"blue"
>
{
groupsMap
[
deparmentid
]},
<
/font></
em
>
;
})
);
)
//显示信息优化
renderFindUserResultBlock
=
(
item
,
content
)
=>
(
<
span
><
font
size
=
"2"
color
=
"black"
>
{
item
}:
<
/font><font size="2" color="blue">{content}</
font
>
<
/span
>
)
//显示对应查询用户的结果信息
renderFoundUserResult
(){
...
...
@@ -233,11 +238,11 @@ export default class schoolmgr extends Component{
return
(
<
div
>
<
span
><
strong
>
检索结果:
<
/strong></
span
>
<
div
>
<
span
>
uid
:
{
userFoundResult
.
userid
}
<
/span>
<br/
>
<
span
>
姓名
:
{
userFoundResult
.
name
}
<
/span>
<br/
>
<
span
>
状态
:
{
userFoundResult
.
status
==
1
?
"已关注"
:
"未关注"
}
<
/span>
<br/
>
<
span
>
角色
:
{
userFoundResult
.
position
}
<
/span>
<br/
>
<
span
>
部门
:
{
this
.
renderUserBelongGroupMath
(
userFoundResult
.
department
)}
<
/span><br/
>
{
this
.
renderFindUserResultBlock
(
"用户 uid"
,
userFoundResult
.
userid
)}
<
br
/>
{
this
.
renderFindUserResultBlock
(
"姓 名"
,
userFoundResult
.
name
)}
<
br
/>
{
this
.
renderFindUserResultBlock
(
"状 态"
,(
userFoundResult
.
status
==
1
?
"已关注"
:
"未关注"
))}
<
br
/>
{
this
.
renderFindUserResultBlock
(
"角 色"
,
userFoundResult
.
position
)}
<
br
/>
<
span
>
<
font
size
=
"2"
color
=
"black"
>
所在的部门
:
<
/font>
{this.renderUserBelongGroupMath
(
userFoundResult.department
)
}</
span
><
br
/>
<
/div
>
<
/div>
)
;
}
else
{
...
...
Write
Preview
Styling with
Markdown
is supported
Attach a file
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 post a comment