Commit 6b8a1fab authored by tangwei's avatar tangwei

修改bug

parent 573b95c2
...@@ -133,6 +133,9 @@ ...@@ -133,6 +133,9 @@
Round(st_distance(point(a.longitude,a.latitude),point(#{par.longitude},#{par.latitude}))*111195,1) AS distance Round(st_distance(point(a.longitude,a.latitude),point(#{par.longitude},#{par.latitude}))*111195,1) AS distance
FROM cb_fire_team a FROM cb_fire_team a
where a.is_delete=0 and a.longitude is not null and a.latitude is not null where a.is_delete=0 and a.longitude is not null and a.latitude is not null
<if test='par.typeCode==null'>
and a.type_code in (116,830)
</if>
<if test='par.typeCode!=null and par.typeCode!=""'> <if test='par.typeCode!=null and par.typeCode!=""'>
and a.type_code in (#{par.typeCode}) and a.type_code in (#{par.typeCode})
</if> </if>
...@@ -147,7 +150,9 @@ ...@@ -147,7 +150,9 @@
COUNT(a.sequence_nbr) num COUNT(a.sequence_nbr) num
FROM cb_fire_team a FROM cb_fire_team a
where a.is_delete=0 and a.longitude is not null and a.latitude is not null where a.is_delete=0 and a.longitude is not null and a.latitude is not null
<if test='par.typeCode==null'>
and a.type_code in (116,830)
</if>
<if test='par.typeCode!=null and par.typeCode!=""'> <if test='par.typeCode!=null and par.typeCode!=""'>
and a.type_code in (#{par.typeCode}) and a.type_code in (#{par.typeCode})
</if> </if>
......
...@@ -496,9 +496,9 @@ public class CommandController extends BaseController { ...@@ -496,9 +496,9 @@ public class CommandController extends BaseController {
@GetMapping(value = "ZQ/list") @GetMapping(value = "ZQ/list")
@ApiOperation(httpMethod = "GET", value = "执勤实力列表分页查询", notes = "执勤实力列表分页查询") @ApiOperation(httpMethod = "GET", value = "执勤实力列表分页查询", notes = "执勤实力列表分页查询")
public ResponseModel<IPage<FireTeamZhDto>> ZQlistPage(Integer pageNum, Integer pageSize, RequestData par) { public ResponseModel<IPage<FireTeamZhDto>> ZQlistPage(Integer pageNum, Integer pageSize, RequestData par) {
if(par.getTypeCode()==null){ // if(par.getTypeCode()==null){
par.setTypeCode( AlertStageEnums.ZZZD.getCode()+","+AlertStageEnums.YLJY.getCode()); // par.setTypeCode( AlertStageEnums.ZZZD.getCode()+","+AlertStageEnums.YLJY.getCode());
} // }
Page<FireTeamZhDto> pageBean = new Page<>(pageNum, pageSize); Page<FireTeamZhDto> pageBean = new Page<>(pageNum, pageSize);
List<FireTeamZhDto> list= iFireTeamService.getFireTeamList(pageNum,pageSize,par); List<FireTeamZhDto> list= iFireTeamService.getFireTeamList(pageNum,pageSize,par);
Integer num= iFireTeamService.getFireTeamListCount(par); Integer num= iFireTeamService.getFireTeamListCount(par);
......
...@@ -330,17 +330,21 @@ public class FireTeamServiceImpl extends BaseService<FireTeamDto, FireTeam, Fire ...@@ -330,17 +330,21 @@ public class FireTeamServiceImpl extends BaseService<FireTeamDto, FireTeam, Fire
ResponseModel<List<Map<String, Object>>> result = equipFeignClient.getFireCarListAllcount(); ResponseModel<List<Map<String, Object>>> result = equipFeignClient.getFireCarListAllcount();
List<Map<String, Object>> result1 = result.getResult(); List<Map<String, Object>> result1 = result.getResult();
if(result1!=null&&result1.size()> 0){
list.forEach(fireTeamZhDto -> { list.forEach(fireTeamZhDto -> {
Long sequenceNbr = fireTeamZhDto.getSequenceNbr(); Long sequenceNbr = fireTeamZhDto.getSequenceNbr();
result1.forEach(map -> { result1.forEach(map -> {
String mapId = String.valueOf(map.get("teamId")); String mapId = String.valueOf(map.get("teamId"));
if (String.valueOf(sequenceNbr).equals(mapId)) { if (String.valueOf(sequenceNbr).equals(mapId)) {
Integer carNum = Integer.valueOf(map.get("carNum").toString()); Integer carNum = Integer.valueOf(map.get("carNum").toString());
fireTeamZhDto.setCarNum(carNum); fireTeamZhDto.setCarNum(carNum);
} }
});
}); });
}); }
/* /*
* *
* if(result1!=null&&result1.size()>0){ Map<String, Object> combineResultMap = * if(result1!=null&&result1.size()>0){ Map<String, Object> combineResultMap =
......
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