Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
B
bill-platform
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
赵啸非
bill-platform
Commits
eba6d3a8
Commit
eba6d3a8
authored
Jul 03, 2024
by
赵啸非
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加首页统计模块
parent
301e40a3
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
100 additions
and
7 deletions
+100
-7
bill-manager/src/main/java/com/mortals/xhx/module/ph/web/PhQueueStatController.java
.../com/mortals/xhx/module/ph/web/PhQueueStatController.java
+47
-1
bill-manager/src/main/java/com/mortals/xhx/module/pj/web/PjEvaluateStatController.java
...m/mortals/xhx/module/pj/web/PjEvaluateStatController.java
+53
-6
No files found.
bill-manager/src/main/java/com/mortals/xhx/module/ph/web/PhQueueStatController.java
View file @
eba6d3a8
...
...
@@ -17,6 +17,7 @@ import com.mortals.xhx.module.ph.model.PhQueueQuery;
import
com.mortals.xhx.module.ph.model.PhQueueStatEntity
;
import
com.mortals.xhx.module.ph.model.PhQueueStatQuery
;
import
com.mortals.xhx.module.ph.service.PhQueueStatService
;
import
com.mortals.xhx.module.pj.model.PjEvaluateStatEntity
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.util.ObjectUtils
;
...
...
@@ -83,10 +84,55 @@ public class PhQueueStatController extends BaseCRUDJsonBodyMappingController<PhQ
if
(
ObjectUtils
.
isEmpty
(
query
.
getSectionName
()))
query
.
setSectionName
(
""
);
if
(
ObjectUtils
.
isEmpty
(
query
.
getBusiness
()))
query
.
setBusiness
(
""
);
if
(
ObjectUtils
.
isEmpty
(
query
.
getWindowFromnum
()))
query
.
setWindowFromnum
(
""
);
addGroup
(
query
);
model
.
put
(
"siteId"
,
query
.
getSiteId
());
}
private
static
void
addGroup
(
PhQueueStatEntity
query
)
{
if
(!
ObjectUtils
.
isEmpty
(
query
.
getSiteId
()))
{
List
<
String
>
groupList
=
query
.
getGroupList
();
if
(
groupList
.
contains
(
"siteId"
))
{
groupList
.
add
(
"siteId"
);
}
}
if
(!
ObjectUtils
.
isEmpty
(
query
.
getSectionName
())
||!
ObjectUtils
.
isEmpty
(
query
.
getSectionNameList
())
||!
ObjectUtils
.
isEmpty
(
query
.
getSectionNameNotList
()))
{
List
<
String
>
groupList
=
query
.
getGroupList
();
if
(
groupList
.
contains
(
"sectionName"
))
{
groupList
.
add
(
"sectionName"
);
}
}
if
(!
ObjectUtils
.
isEmpty
(
query
.
getHallName
())
||!
ObjectUtils
.
isEmpty
(
query
.
getHallNameList
())
||!
ObjectUtils
.
isEmpty
(
query
.
getHallNameNotList
()))
{
List
<
String
>
groupList
=
query
.
getGroupList
();
if
(
groupList
.
contains
(
"hallName"
))
{
groupList
.
add
(
"hallName"
);
}
}
if
(!
ObjectUtils
.
isEmpty
(
query
.
getWindowFromnum
())
||!
ObjectUtils
.
isEmpty
(
query
.
getWindowFromnumList
())
||!
ObjectUtils
.
isEmpty
(
query
.
getWindowFromnumNotList
()))
{
List
<
String
>
groupList
=
query
.
getGroupList
();
if
(
groupList
.
contains
(
"windowFromnum"
))
{
groupList
.
add
(
"windowFromnum"
);
}
}
if
(!
ObjectUtils
.
isEmpty
(
query
.
getBusiness
())
||!
ObjectUtils
.
isEmpty
(
query
.
getBusinessList
())
||!
ObjectUtils
.
isEmpty
(
query
.
getHallNameNotList
()))
{
List
<
String
>
groupList
=
query
.
getGroupList
();
if
(
groupList
.
contains
(
"business"
))
{
groupList
.
add
(
"business"
);
}
}
}
@PostMapping
(
value
=
"/stat"
)
@UnAuth
public
Rest
<
String
>
addAttendanceRecordCustom
(
@RequestBody
PhQueueQuery
phQueueQuery
)
{
...
...
bill-manager/src/main/java/com/mortals/xhx/module/pj/web/PjEvaluateStatController.java
View file @
eba6d3a8
...
...
@@ -56,13 +56,13 @@ public class PjEvaluateStatController extends BaseCRUDJsonBodyMappingController<
//通过站点 查询存在的部门 大厅等
Object
siteId
=
model
.
get
(
"siteId"
);
if
(!
ObjectUtils
.
isEmpty
(
siteId
))
{
if
(!
ObjectUtils
.
isEmpty
(
siteId
))
{
PjEvaluateStatQuery
pjEvaluateStatQuery
=
new
PjEvaluateStatQuery
();
pjEvaluateStatQuery
.
setSiteId
((
Long
)
siteId
);
pjEvaluateStatQuery
.
setSiteId
((
Long
)
siteId
);
List
<
PjEvaluateStatEntity
>
pjEvaluateStatEntities
=
this
.
service
.
find
(
pjEvaluateStatQuery
,
context
);
Map
<
String
,
String
>
sectionNameMap
=
pjEvaluateStatEntities
.
stream
().
filter
(
f
->
!
ObjectUtils
.
isEmpty
(
f
.
getSectionName
())).
collect
(
Collectors
.
toMap
(
PjEvaluateStatEntity:
:
getSectionName
,
PjEvaluateStatEntity:
:
getSectionName
,
(
k1
,
k2
)
->
k2
));
Map
<
String
,
String
>
hallNameMap
=
pjEvaluateStatEntities
.
stream
().
filter
(
f
->
!
ObjectUtils
.
isEmpty
(
f
.
getHallName
())).
collect
(
Collectors
.
toMap
(
PjEvaluateStatEntity:
:
getHallName
,
PjEvaluateStatEntity:
:
getHallName
,
(
k1
,
k2
)
->
k2
));
Map
<
String
,
String
>
windowFromnumMap
=
pjEvaluateStatEntities
.
stream
().
filter
(
f
->
!
ObjectUtils
.
isEmpty
(
f
.
getWindowFromnum
())).
collect
(
Collectors
.
toMap
(
PjEvaluateStatEntity:
:
getWindowFromnum
,
PjEvaluateStatEntity:
:
getWindowFromnum
,
(
k1
,
k2
)
->
k2
));
Map
<
String
,
String
>
sectionNameMap
=
pjEvaluateStatEntities
.
stream
().
filter
(
f
->
!
ObjectUtils
.
isEmpty
(
f
.
getSectionName
())).
collect
(
Collectors
.
toMap
(
PjEvaluateStatEntity:
:
getSectionName
,
PjEvaluateStatEntity:
:
getSectionName
,
(
k1
,
k2
)
->
k2
));
Map
<
String
,
String
>
hallNameMap
=
pjEvaluateStatEntities
.
stream
().
filter
(
f
->
!
ObjectUtils
.
isEmpty
(
f
.
getHallName
())).
collect
(
Collectors
.
toMap
(
PjEvaluateStatEntity:
:
getHallName
,
PjEvaluateStatEntity:
:
getHallName
,
(
k1
,
k2
)
->
k2
));
Map
<
String
,
String
>
windowFromnumMap
=
pjEvaluateStatEntities
.
stream
().
filter
(
f
->
!
ObjectUtils
.
isEmpty
(
f
.
getWindowFromnum
())).
collect
(
Collectors
.
toMap
(
PjEvaluateStatEntity:
:
getWindowFromnum
,
PjEvaluateStatEntity:
:
getWindowFromnum
,
(
k1
,
k2
)
->
k2
));
this
.
addDict
(
model
,
"sectionNameList"
,
sectionNameMap
);
this
.
addDict
(
model
,
"hallNameList"
,
hallNameMap
);
...
...
@@ -83,8 +83,55 @@ public class PjEvaluateStatController extends BaseCRUDJsonBodyMappingController<
//年月日
//根据查询条件自动添加分组字段
addGroup
(
query
);
model
.
put
(
"siteId"
,
query
.
getSiteId
());
model
.
put
(
"siteId"
,
query
.
getSiteId
());
}
private
static
void
addGroup
(
PjEvaluateStatEntity
query
)
{
if
(!
ObjectUtils
.
isEmpty
(
query
.
getSiteId
()))
{
List
<
String
>
groupList
=
query
.
getGroupList
();
if
(
groupList
.
contains
(
"siteId"
))
{
groupList
.
add
(
"siteId"
);
}
}
if
(!
ObjectUtils
.
isEmpty
(
query
.
getSectionName
())
||!
ObjectUtils
.
isEmpty
(
query
.
getSectionNameList
())
||!
ObjectUtils
.
isEmpty
(
query
.
getSectionNameNotList
()))
{
List
<
String
>
groupList
=
query
.
getGroupList
();
if
(
groupList
.
contains
(
"sectionName"
))
{
groupList
.
add
(
"sectionName"
);
}
}
if
(!
ObjectUtils
.
isEmpty
(
query
.
getHallName
())
||!
ObjectUtils
.
isEmpty
(
query
.
getHallNameList
())
||!
ObjectUtils
.
isEmpty
(
query
.
getHallNameNotList
()))
{
List
<
String
>
groupList
=
query
.
getGroupList
();
if
(
groupList
.
contains
(
"hallName"
))
{
groupList
.
add
(
"hallName"
);
}
}
if
(!
ObjectUtils
.
isEmpty
(
query
.
getWindowFromnum
())
||!
ObjectUtils
.
isEmpty
(
query
.
getWindowFromnumList
())
||!
ObjectUtils
.
isEmpty
(
query
.
getWindowFromnumNotList
()))
{
List
<
String
>
groupList
=
query
.
getGroupList
();
if
(
groupList
.
contains
(
"windowFromnum"
))
{
groupList
.
add
(
"windowFromnum"
);
}
}
if
(!
ObjectUtils
.
isEmpty
(
query
.
getPjOption
())
||!
ObjectUtils
.
isEmpty
(
query
.
getPjOptionList
())
||!
ObjectUtils
.
isEmpty
(
query
.
getPjOptionNotList
()))
{
List
<
String
>
groupList
=
query
.
getGroupList
();
if
(
groupList
.
contains
(
"pjOption"
))
{
groupList
.
add
(
"pjOption"
);
}
}
}
...
...
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