Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
张雷
/
skboot-zhongye
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
构建
提交
问题看板
文件
提交
网络
比较
分支
标签
920eab55
由
张雷
编写于
2024-10-21 18:34:58 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
首页接口BUG修改
1 个父辈
6946f063
显示空白字符变更
内嵌
并排
正在显示
3 个修改的文件
包含
27 行增加
和
15 行删除
sk-module-biz/src/main/java/com/skua/modules/threedimensional/mapper/ScreenMapper.java
sk-module-biz/src/main/java/com/skua/modules/threedimensional/mapper/xml/ScreenMapper.xml
sk-module-biz/src/main/java/com/skua/modules/threedimensional/service/impl/ScreenDataServiceImpl.java
sk-module-biz/src/main/java/com/skua/modules/threedimensional/mapper/ScreenMapper.java
查看文件 @
920eab5
...
...
@@ -22,7 +22,9 @@ public interface ScreenMapper {
@Param
(
"TbstartTime"
)
String
TbstartTime
,
@Param
(
"TbendTime"
)
String
TbendTime
,
@Param
(
"timeType"
)
String
timeType
);
List
<
Map
<
String
,
Object
>>
getYhdlqs
(
@Param
(
"startDate"
)
String
startDate
,
@Param
(
"endDate"
)
String
endDate
,
@Param
(
"departIds"
)
String
departIds
);
List
<
Map
<
String
,
Object
>>
getYhdlqs
(
@Param
(
"startDate"
)
String
startDate
,
@Param
(
"endDate"
)
String
endDate
,
@Param
(
"departIds"
)
String
departIds
,
@Param
(
"dataViewName3a24"
)
String
dataViewName3a24
,
@Param
(
"dataViewName2119"
)
String
dataViewName2119
);
List
<
Map
<
String
,
Object
>>
getYhylqs
(
@Param
(
"startDate"
)
String
startDate
,
@Param
(
"endDate"
)
String
endDate
,
@Param
(
"departIds"
)
String
departIds
);
List
<
Map
<
String
,
Object
>>
getYhylqs
(
@Param
(
"startDate"
)
String
startDate
,
@Param
(
"endDate"
)
String
endDate
,
@Param
(
"departIds"
)
String
departIds
,
@Param
(
"dataViewName3a24"
)
String
dataViewName3a24
,
@Param
(
"dataViewName2119"
)
String
dataViewName2119
);
}
...
...
sk-module-biz/src/main/java/com/skua/modules/threedimensional/mapper/xml/ScreenMapper.xml
查看文件 @
920eab5
...
...
@@ -61,16 +61,16 @@
v2.clsl,
ROUND(SUM( v3.DLHJ )/v2.clsl,4) AS dsdh
FROM
view_3a24
v3
${dataViewName3a24}
v3
LEFT JOIN
( SELECT
LEFT(
time, 7) time,SUM(CSL) clsl FROM view_
2119
WHERE
time
>
= #{startDate} AND
time
<
= #{endDate}
AND depart_id in
LEFT(
v2119.time, 7) time,ROUND(SUM(v2119.CSL),4) AS clsl FROM ${dataViewName2119} v
2119
WHERE
v2119.time
>
= #{startDate} AND v2119.
time
<
= #{endDate}
AND
v2119.
depart_id in
<foreach
item=
"item"
index=
"index"
collection=
"departIds.split(',')"
open=
"("
separator=
","
close=
")"
>
'${item}'
</foreach>
GROUP BY LEFT(time, 7) ) v2
GROUP BY LEFT(
v2119.
time, 7) ) v2
ON v2.time = LEFT( v3.time, 7 )
WHERE v3.time
>
= #{startDate} AND v3.time
<
= #{endDate}
AND v3.depart_id in
...
...
@@ -90,16 +90,16 @@
+ SUM( v3.HXT ) + SUM( v3.FECL3 ) + SUM( v3.SH ) + SUM( v3.CH3COOH ) + SUM( v3.FESO4G ) + SUM( v3.FESO4Y )
+ SUM( v3.H2O2 ) ) / v2.clsl, 4 ) AS dsyh
FROM
view_3a24
v3
${dataViewName3a24}
v3
LEFT JOIN
( SELECT
LEFT(
time, 7) time,SUM(CSL) clsl FROM view_
2119
WHERE
time
>
= #{startDate} AND
time
<
= #{endDate}
AND depart_id in
LEFT(
v2119.time, 7) time,SUM(v2119.CSL) clsl FROM ${dataViewName2119} v
2119
WHERE
v2119.time
>
= #{startDate} AND v2119.
time
<
= #{endDate}
AND
v2119.
depart_id in
<foreach
item=
"item"
index=
"index"
collection=
"departIds.split(',')"
open=
"("
separator=
","
close=
")"
>
'${item}'
</foreach>
GROUP BY LEFT(time, 7) ) v2
GROUP BY LEFT(
v2119.
time, 7) ) v2
ON v2.time = LEFT( v3.time, 7 )
WHERE v3.time
>
= #{startDate} AND v3.time
<
= #{endDate}
AND v3.depart_id in
...
...
sk-module-biz/src/main/java/com/skua/modules/threedimensional/service/impl/ScreenDataServiceImpl.java
查看文件 @
920eab5
package
com
.
skua
.
modules
.
threedimensional
.
service
.
impl
;
import
com.skua.common.report.ReportViewUtil
;
import
com.skua.core.service.IFactoryInfoService
;
import
com.skua.core.util.DateUtils
;
import
com.skua.modules.flow.utils.StringUtil
;
...
...
@@ -204,20 +205,23 @@ public class ScreenDataServiceImpl implements IScreenDataService {
@Override
public
List
<
Map
<
String
,
Object
>>
factorySLQS
(
String
departId
,
String
startTime
,
String
endTime
,
String
TbstartTime
,
String
TbendTime
,
String
timeType
)
{
return
screenMapper
.
factorySLQS
(
departId
,
startTime
,
endTime
,
TbstartTime
,
TbendTime
,
timeType
);
}
@Override
public
List
<
Map
<
String
,
Object
>>
getYhdlqs
(
StatisticsParams
statisticsParams
)
{
String
view2119
=
"2119ecbf53a1d2d0708258ff67cfd9e1"
;
String
view3a24
=
"3a243d5715b9e1a3753c180872ca0df9"
;
List
<
Map
<
String
,
Object
>>
list
=
new
ArrayList
<>();
String
startDate
=
statisticsParams
.
getStartDate
();
String
endDate
=
statisticsParams
.
getEndDate
();
String
departIds
=
statisticsParams
.
getDepartIds
();
Map
<
String
,
Object
>
valueMap
=
new
HashMap
<>();
List
<
String
>
monthList
=
getMonthsBetween
(
startDate
,
endDate
);
List
<
Map
<
String
,
Object
>>
dataList
=
screenMapper
.
getYhdlqs
(
startDate
,
endDate
,
departIds
);
String
dataViewName3a24
=
ReportViewUtil
.
buildView
(
view3a24
,
"DLHJ"
,
departIds
,
startDate
,
endDate
);
String
dataViewName2119
=
ReportViewUtil
.
buildView
(
view2119
,
"CSL"
,
departIds
,
startDate
,
endDate
);
List
<
Map
<
String
,
Object
>>
dataList
=
screenMapper
.
getYhdlqs
(
startDate
,
endDate
,
departIds
,
dataViewName3a24
,
dataViewName2119
);
if
(
dataList
.
size
()>
0
){
for
(
Map
<
String
,
Object
>
vMap
:
dataList
)
{
valueMap
.
put
(
vMap
.
get
(
"time"
).
toString
(),
vMap
);
...
...
@@ -252,13 +256,19 @@ public class ScreenDataServiceImpl implements IScreenDataService {
@Override
public
List
<
Map
<
String
,
Object
>>
getYhylqs
(
StatisticsParams
statisticsParams
)
{
String
view2119
=
"2119ecbf53a1d2d0708258ff67cfd9e1"
;
String
view3a24
=
"3a243d5715b9e1a3753c180872ca0df9"
;
List
<
Map
<
String
,
Object
>>
list
=
new
ArrayList
<>();
String
startDate
=
statisticsParams
.
getStartDate
();
String
endDate
=
statisticsParams
.
getEndDate
();
String
departIds
=
statisticsParams
.
getDepartIds
();
Map
<
String
,
Object
>
valueMap
=
new
HashMap
<>();
List
<
String
>
monthList
=
getMonthsBetween
(
startDate
,
endDate
);
List
<
Map
<
String
,
Object
>>
dataList
=
screenMapper
.
getYhylqs
(
startDate
,
endDate
,
departIds
);
String
field3a24
=
"PAMRJ,SCLPAMZ,SCLPAMF,NACLO,PACGT,PACYT,PFS,FHTY,RYXNJ,"
+
"YWL,GXCLJ,CH3COONA,HXT,FECL3,SH,CH3COOH,FESO4G,FESO4Y,H2O2"
;
String
dataViewName3a24
=
ReportViewUtil
.
buildView
(
view3a24
,
field3a24
,
departIds
,
startDate
,
endDate
);
String
dataViewName2119
=
ReportViewUtil
.
buildView
(
view2119
,
"CSL"
,
departIds
,
startDate
,
endDate
);
List
<
Map
<
String
,
Object
>>
dataList
=
screenMapper
.
getYhylqs
(
startDate
,
endDate
,
departIds
,
dataViewName3a24
,
dataViewName2119
);
if
(
dataList
.
size
()>
0
){
for
(
Map
<
String
,
Object
>
vMap
:
dataList
)
{
valueMap
.
put
(
vMap
.
get
(
"time"
).
toString
(),
vMap
);
...
...
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论