Commit 74e5409d authored by chenzhao's avatar chenzhao

修改代码

parent 3aff0288
...@@ -225,6 +225,15 @@ ...@@ -225,6 +225,15 @@
cb_duty_shift ds cb_duty_shift ds
where where
d.instanceId = ps.instance_id d.instanceId = ps.instance_id
and d.deptId not in (SELECT
`cb_org_usr`.`sequence_nbr`
FROM
`cb_org_usr`
WHERE
(
( `cb_org_usr`.`biz_org_code` LIKE concat( ( SELECT `cb_org_usr`.`biz_org_code` FROM `cb_org_usr` WHERE ( `cb_org_usr`.`sequence_nbr` = 1435847345328660481 ) ), '%' ) )
AND ( `cb_org_usr`.`biz_org_type` = 'DEPARTMENT' )
))
and ps.shift_id = ds.sequence_nbr and ps.shift_id = ds.sequence_nbr
and ps.duty_date = #{dutyDate} and ps.duty_date = #{dutyDate}
<if test="shiftId != null and shiftId != ''"> <if test="shiftId != null and shiftId != ''">
......
...@@ -312,7 +312,6 @@ public class ESAlertCalledService { ...@@ -312,7 +312,6 @@ public class ESAlertCalledService {
//过滤120警情 //过滤120警情
BoolQueryBuilder qb6 = QueryBuilders.boolQuery() BoolQueryBuilder qb6 = QueryBuilders.boolQuery()
.mustNot(QueryBuilders.termQuery("alertTypeCode", "1214")); .mustNot(QueryBuilders.termQuery("alertTypeCode", "1214"));
boolMust.should(qb6);
if (!ValidationUtil.isEmpty(alertCalledVo.getAlertFormValue())){ if (!ValidationUtil.isEmpty(alertCalledVo.getAlertFormValue())){
List<AlertFormValue> alertFormValue = alertCalledVo.getAlertFormValue(); List<AlertFormValue> alertFormValue = alertCalledVo.getAlertFormValue();
...@@ -343,8 +342,9 @@ public class ESAlertCalledService { ...@@ -343,8 +342,9 @@ public class ESAlertCalledService {
*/ */
// boolMust.minimumShouldMatch(1);//至少满足一个 boolMust.minimumShouldMatch(1);//至少满足一个
boolMustAll.must(boolMust); boolMustAll.must(boolMust);
boolMustAll.must(qb6);
...@@ -456,6 +456,7 @@ public class ESAlertCalledService { ...@@ -456,6 +456,7 @@ public class ESAlertCalledService {
boolMust.minimumShouldMatch(1);//至少满足一个 boolMust.minimumShouldMatch(1);//至少满足一个
boolMustAll.must(boolMust); boolMustAll.must(boolMust);
boolMustAll.must(qb4);
...@@ -464,10 +465,9 @@ public class ESAlertCalledService { ...@@ -464,10 +465,9 @@ public class ESAlertCalledService {
// 分页 // 分页
.withPageable(PageRequest.of(current, size)) .withPageable(PageRequest.of(current, size))
// 排序 // 排序
// .withSort(SortBuilders.fieldSort("callTimeLong").order(SortOrder.DESC)) .withSort(SortBuilders.fieldSort("callTimeLong").order(SortOrder.DESC))
//过滤条件 //过滤条件
.withQuery(boolMustAll) .withQuery(boolMustAll)
.withQuery(qb4)
; ;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment