Merge branch 'master' into docker_package
This commit is contained in:
commit
23b16f1c3e
|
@ -17,7 +17,7 @@ public interface CameraOrgenizationMapper extends BaseDao<CameraOrganization> {
|
|||
@Select("select * from t_camera_organization where parent_id = #{parentId}")
|
||||
List<CameraOrganization> selectSubOrganization(@Param("parentId") String parentId);
|
||||
|
||||
@Select("select *,0 AS channelCount from t_camera_organization02 where parent_id = #{parentId}")
|
||||
@Select("select * channelCount from t_camera_organization02 where parent_id = #{parentId}")
|
||||
List<Map> selectSubOrganizationMap(@Param("parentId") String parentId);
|
||||
|
||||
void batchSaveOrgenization(List<Map> list);
|
||||
|
|
|
@ -1097,16 +1097,8 @@ public class MonitorService {
|
|||
if (parentId == null){
|
||||
parentId = "";
|
||||
}
|
||||
List<Map> organs = cameraOrgenMapper.selectSubOrganizationMap(parentId);//查询某个区域下的所有地区
|
||||
if(organs.size() > 0){
|
||||
for(int i=0;i< organs.size();i++){
|
||||
String path = organs.get(i).get("path").toString();
|
||||
List<Map> organs = cameraOrgenMapper.selectSubOrganizationMap(parentId);
|
||||
|
||||
Integer count = cameraChannelMapper.selectChannelCounts(path);
|
||||
organs.get(i).put("channelCount",count);
|
||||
|
||||
};
|
||||
}
|
||||
return organs;
|
||||
}
|
||||
|
||||
|
|
|
@ -96,8 +96,13 @@ public class TAbilityApplicationController {
|
|||
PageData<TAbilityApplicationDTO> page = tAbilityApplicationService.page(params);
|
||||
List<TAbilityApplicationDTO> list =
|
||||
page.getList().stream().map(index -> {
|
||||
Integer inStanceId =
|
||||
jdbcTemplate.queryForObject(String.format("SELECT DISTINCT instance_id FROM t_ability_application WHERE apply_flag = '%s' LIMIT 1", index.getApplyFlag()), Integer.class);
|
||||
if (inStanceId == null) {
|
||||
return index;
|
||||
}
|
||||
List<TAbilityApplicationDTO> dtos =
|
||||
tAbilityApplicationService.getByInstanceId(index.getInstanceId());
|
||||
tAbilityApplicationService.getByInstanceId(inStanceId + "");
|
||||
if (!dtos.isEmpty()) {
|
||||
dtos.stream()
|
||||
.limit(1l)
|
||||
|
|
|
@ -32,12 +32,10 @@ public class TAbilityApplicationServiceImpl extends CrudServiceImpl<TAbilityAppl
|
|||
params.keySet().stream().filter(index -> null != params.get(index)).forEach(index -> {
|
||||
switch (index) { //
|
||||
case "abilityprocess_v2":
|
||||
wrapper.select("DISTINCT apply_flag,instance_id,apply_number");
|
||||
wrapper.select("DISTINCT apply_flag,apply_number");
|
||||
wrapper.isNotNull(Boolean.valueOf(params.get("abilityprocess_v2").toString()), "apply_flag")
|
||||
.isNotNull(Boolean.valueOf(params.get("abilityprocess_v2").toString()), "instance_id")
|
||||
.isNotNull(Boolean.valueOf(params.get("abilityprocess_v2").toString()), "apply_number");
|
||||
wrapper.groupBy(Boolean.valueOf(params.get("abilityprocess_v2").toString()), "apply_flag")
|
||||
.groupBy(Boolean.valueOf(params.get("abilityprocess_v2").toString()), "instance_id")
|
||||
.groupBy(Boolean.valueOf(params.get("abilityprocess_v2").toString()), "apply_number");
|
||||
wrapper.orderByDesc("apply_number"); // 流程排序
|
||||
break;
|
||||
|
|
|
@ -4,11 +4,11 @@
|
|||
<insert id="batchSaveOrgenization" parameterType="java.util.List">
|
||||
|
||||
INSERT INTO t_camera_organization02 (
|
||||
id,name,parent_id,sort,subCount,is_parent,path
|
||||
id,name,parent_id,sort,subCount,path
|
||||
) VALUES
|
||||
<foreach collection="list" item="item" separator="," >
|
||||
(
|
||||
#{item.id},#{item.name},#{item.parentId},#{item.sort},#{item.subCount},case when #{item.isParent} = true then 1 else 0 end,#{item.name}
|
||||
#{item.id},#{item.name},#{item.parentId},#{item.sort},#{item.subCount},#{item.name}
|
||||
)
|
||||
</foreach>
|
||||
</insert>
|
||||
|
|
Loading…
Reference in New Issue