Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
I
ioc_sixiang_license
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
zengtianlai3
ioc_sixiang_license
Commits
e6f308ee
Commit
e6f308ee
authored
Feb 03, 2023
by
ma
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
用户列表排序
parent
35127506
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
UserServiceImpl.java
...ava/iot/sixiang/license/service/impl/UserServiceImpl.java
+1
-1
UserMapper.xml
license/src/main/resources/mapper/UserMapper.xml
+1
-1
No files found.
license/src/main/java/iot/sixiang/license/service/impl/UserServiceImpl.java
View file @
e6f308ee
...
@@ -45,7 +45,7 @@ public class UserServiceImpl extends ServiceImpl<UserMapper, User> implements Us
...
@@ -45,7 +45,7 @@ public class UserServiceImpl extends ServiceImpl<UserMapper, User> implements Us
throw
new
IotLicenseException
(
ResultCode
.
VALIDATE_FAILED
.
getCode
(),
ResultCode
.
VALIDATE_FAILED
.
getMsg
());
throw
new
IotLicenseException
(
ResultCode
.
VALIDATE_FAILED
.
getCode
(),
ResultCode
.
VALIDATE_FAILED
.
getMsg
());
}
}
List
<
UserVo
>
records
=
userMapper
.
getUserList
(
userName
,
company
,
userIds
);
List
<
UserVo
>
records
=
userMapper
.
getUserList
(
userName
,
company
,
userIds
);
records
=
records
.
stream
().
sorted
(
Comparator
.
comparing
(
UserVo:
:
getCreateTime
,
Comparator
.
reverseOrder
())).
collect
(
Collectors
.
toList
());
records
=
records
.
stream
().
sorted
(
Comparator
.
comparing
(
UserVo:
:
getCreateTime
,
Comparator
.
reverseOrder
())).
sorted
(
Comparator
.
comparing
(
UserVo:
:
getLevel
)).
collect
(
Collectors
.
toList
());
List
<
UserVo
>
result
=
new
ArrayList
<>();
List
<
UserVo
>
result
=
new
ArrayList
<>();
int
begin
=
(
pageNo
-
1
)
*
pageSize
;
int
begin
=
(
pageNo
-
1
)
*
pageSize
;
if
(
begin
>=
0
&&
records
.
size
()
>
0
)
{
if
(
begin
>=
0
&&
records
.
size
()
>
0
)
{
...
...
license/src/main/resources/mapper/UserMapper.xml
View file @
e6f308ee
...
@@ -15,7 +15,7 @@
...
@@ -15,7 +15,7 @@
</update>
</update>
<select
id=
"getUserList"
resultType=
"iot.sixiang.license.model.vo.UserVo"
>
<select
id=
"getUserList"
resultType=
"iot.sixiang.license.model.vo.UserVo"
>
SELECT user.user_id, user_name, password, company, user.create_time, user.update_time,
SELECT user.user_id, user_name, password, company, user.
level, user.
create_time, user.update_time,
COUNT(device.`device_id`) totalDevice,
COUNT(device.`device_id`) totalDevice,
COUNT(if(device.device_id is NOT NULL, if (device.`status` = 0 or device.`status` is NULL, 1, NULL), NULL))
COUNT(if(device.device_id is NOT NULL, if (device.`status` = 0 or device.`status` is NULL, 1, NULL), NULL))
unUseDevice,
unUseDevice,
...
...
Write
Preview
Markdown
is supported
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