Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
amos-boot-biz
Project
Project
Details
Activity
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
项目统一框架
amos-boot-biz
Commits
737fbd0f
Commit
737fbd0f
authored
Aug 19, 2024
by
麻笑宇
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改大屏总揽办结率去掉已完成筛选
parent
55e31488
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
7 deletions
+16
-7
CommonMapper.xml
...-module-jg-api/src/main/resources/mapper/CommonMapper.xml
+0
-0
JGDPStatisticsServiceImpl.java
...statistcs/biz/service/impl/JGDPStatisticsServiceImpl.java
+16
-7
No files found.
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/resources/mapper/CommonMapper.xml
View file @
737fbd0f
This diff is collapsed.
Click to expand it.
amos-boot-system-tzs/amos-boot-module-statistics/amos-boot-module-statistics-biz/src/main/java/com/yeejoin/amos/boot/module/statistcs/biz/service/impl/JGDPStatisticsServiceImpl.java
View file @
737fbd0f
...
@@ -631,14 +631,25 @@ public class JGDPStatisticsServiceImpl {
...
@@ -631,14 +631,25 @@ public class JGDPStatisticsServiceImpl {
this
.
setDefaultFilter
(
dpFilterParamDto
);
this
.
setDefaultFilter
(
dpFilterParamDto
);
result
.
put
(
"xdata"
,
Arrays
.
asList
(
"安装告知"
,
"监督检验"
,
"使用登记"
,
"定期检验"
,
"变更登记"
,
"注销报废"
));
result
.
put
(
"xdata"
,
Arrays
.
asList
(
"安装告知"
,
"监督检验"
,
"使用登记"
,
"定期检验"
,
"变更登记"
,
"注销报废"
));
List
<
Long
>
ydata
=
this
.
countBizFinishedNum
(
dpFilterParamDto
);
List
<
Long
>
ydata
=
this
.
countBizFinishedNum
(
dpFilterParamDto
);
Long
allFinishedCount
=
ydata
.
stream
().
mapToLong
(
e
->
e
).
sum
();
Long
allFinishedCount
=
this
.
calEveryAll
(
dpFilterParamDto
,
ydata
)
.
stream
().
mapToLong
(
e
->
e
).
sum
();
result
.
put
(
"ydata"
,
ydata
);
result
.
put
(
"ydata"
,
this
.
calEveryAll
(
dpFilterParamDto
,
ydata
)
);
result
.
put
(
"allCount"
,
allFinishedCount
);
result
.
put
(
"allCount"
,
allFinishedCount
);
result
.
put
(
"percentData"
,
this
.
calEveryPercent
(
dpFilterParamDto
,
ydata
));
result
.
put
(
"percentData"
,
this
.
calEveryPercent
(
dpFilterParamDto
,
ydata
));
result
.
put
(
"completionRate"
,
this
.
calPercentForBizCycleData
(
dpFilterParamDto
,
allFinishedCount
));
result
.
put
(
"completionRate"
,
this
.
calPercentForBizCycleData
(
dpFilterParamDto
,
allFinishedCount
));
return
result
;
return
result
;
}
}
private
List
<
Long
>
calEveryAll
(
DPFilterParamDto
dpFilterParamDto
,
List
<
Long
>
everyFinished
)
{
List
<
Long
>
everyInFlow
=
countBizDataInFlowing
(
dpFilterParamDto
);
List
<
Long
>
allArray
=
new
ArrayList
<>();
for
(
int
i
=
0
;
i
<
everyInFlow
.
size
();
i
++)
{
Long
flowIng
=
everyInFlow
.
get
(
i
);
Long
finished
=
everyFinished
.
get
(
i
);
allArray
.
add
(
flowIng
+
finished
);
}
return
allArray
;
}
private
List
<
String
>
calEveryPercent
(
DPFilterParamDto
dpFilterParamDto
,
List
<
Long
>
everyFinished
)
{
private
List
<
String
>
calEveryPercent
(
DPFilterParamDto
dpFilterParamDto
,
List
<
Long
>
everyFinished
)
{
List
<
Long
>
everyInFlow
=
countBizDataInFlowing
(
dpFilterParamDto
);
List
<
Long
>
everyInFlow
=
countBizDataInFlowing
(
dpFilterParamDto
);
List
<
String
>
percentArray
=
new
ArrayList
<>();
List
<
String
>
percentArray
=
new
ArrayList
<>();
...
@@ -650,8 +661,7 @@ public class JGDPStatisticsServiceImpl {
...
@@ -650,8 +661,7 @@ public class JGDPStatisticsServiceImpl {
BigDecimal
all
=
flowIngBig
.
add
(
finishedBig
);
BigDecimal
all
=
flowIngBig
.
add
(
finishedBig
);
if
(
all
.
compareTo
(
BigDecimal
.
ZERO
)
>
0
)
{
if
(
all
.
compareTo
(
BigDecimal
.
ZERO
)
>
0
)
{
BigDecimal
percent
=
finishedBig
.
divide
(
all
,
2
,
RoundingMode
.
HALF_UP
);
BigDecimal
percent
=
finishedBig
.
divide
(
all
,
2
,
RoundingMode
.
HALF_UP
);
BigDecimal
percentX100
=
percent
.
multiply
(
new
BigDecimal
(
"100"
)).
setScale
(
0
,
RoundingMode
.
HALF_UP
);
percentArray
.
add
(
percent
.
toPlainString
());
percentArray
.
add
(
percentX100
.
toPlainString
());
}
else
{
}
else
{
percentArray
.
add
(
"0"
);
percentArray
.
add
(
"0"
);
}
}
...
@@ -1562,12 +1572,11 @@ public class JGDPStatisticsServiceImpl {
...
@@ -1562,12 +1572,11 @@ public class JGDPStatisticsServiceImpl {
BigDecimal
all
=
everyNum
.
add
(
finishedNum
);
BigDecimal
all
=
everyNum
.
add
(
finishedNum
);
if
(
all
.
compareTo
(
BigDecimal
.
ZERO
)
>
0
)
{
if
(
all
.
compareTo
(
BigDecimal
.
ZERO
)
>
0
)
{
BigDecimal
percent
=
finishedNum
.
divide
(
all
,
2
,
RoundingMode
.
HALF_UP
);
BigDecimal
percent
=
finishedNum
.
divide
(
all
,
2
,
RoundingMode
.
HALF_UP
);
BigDecimal
percentX100
=
percent
.
multiply
(
new
BigDecimal
(
"100"
)).
setScale
(
0
,
RoundingMode
.
HALF_UP
);
itemResult
.
put
(
"percentData"
,
percent
.
toPlainString
());
itemResult
.
put
(
"percentData"
,
percentX100
.
toPlainString
());
}
else
{
}
else
{
itemResult
.
put
(
"percentData"
,
"0"
);
itemResult
.
put
(
"percentData"
,
"0"
);
}
}
itemResult
.
put
(
"finishedNum"
,
finishedNum
);
itemResult
.
put
(
"finishedNum"
,
all
);
return
itemResult
;
return
itemResult
;
}).
collect
(
Collectors
.
toList
());
}).
collect
(
Collectors
.
toList
());
...
...
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