Commit 4b5b5d1c authored by tianbo's avatar tianbo

Merge branch 'developer' into developer-latentDanger

# Conflicts: # amos-boot-module/amos-boot-module-api/amos-boot-module-common-api/src/main/java/com/yeejoin/amos/boot/module/common/api/feign/EquipFeignClient.java
parents a3c17844 286425b8
...@@ -18,7 +18,7 @@ public enum WorkFlowEnum { ...@@ -18,7 +18,7 @@ public enum WorkFlowEnum {
GROUPNAME("groupName","角色组的key"), GROUPNAME("groupName","角色组的key"),
NAME("name","任务节点的key"), NAME("name","任务节点的key"),
PROCESSINSTANCEID("processInstanceId",""), PROCESSINSTANCEID("processInstanceId",""),
ASSIGN("assign","角色执行人key"); ASSIGN("assignee","角色执行人key");
private String code;//对应菜单组件名称 private String code;//对应菜单组件名称
private String desc;//描述 private String desc;//描述
......
...@@ -56,7 +56,7 @@ public class WorkflowExcuteServiceImpl implements IWorkflowExcuteService { ...@@ -56,7 +56,7 @@ public class WorkflowExcuteServiceImpl implements IWorkflowExcuteService {
public Map<String, Object> checkTaskAuthMap(String processInstanceId, ReginParams userInfo) { public Map<String, Object> checkTaskAuthMap(String processInstanceId, ReginParams userInfo) {
// 获取当前登录用户的角色 // 获取当前登录用户的角色
String currentLoginUserRole = userInfo.getRole().getRoleName(); String currentLoginUserRole = userInfo.getRole().getRoleName();
String currentLoginUserId = userInfo.getUserModel().getUserId(); String currentLoginUserName = userInfo.getUserModel().getUserName();
Map<String, Object> map = new HashMap<String, Object>(); Map<String, Object> map = new HashMap<String, Object>();
map.put(WorkFlowEnum.CHECKFLAG.getCode(), false); map.put(WorkFlowEnum.CHECKFLAG.getCode(), false);
JSONObject teskObject = workflowFeignService.getTaskList(processInstanceId); JSONObject teskObject = workflowFeignService.getTaskList(processInstanceId);
...@@ -86,7 +86,7 @@ public class WorkflowExcuteServiceImpl implements IWorkflowExcuteService { ...@@ -86,7 +86,7 @@ public class WorkflowExcuteServiceImpl implements IWorkflowExcuteService {
.getString(WorkFlowEnum.ASSIGN.getCode()); .getString(WorkFlowEnum.ASSIGN.getCode());
if (StringUtils.isNotBlank(assignUser)) { if (StringUtils.isNotBlank(assignUser)) {
// 如果当前登录人与当前任务的设定人不一定,则直接返回权限校验失败 // 如果当前登录人与当前任务的设定人不一定,则直接返回权限校验失败
if (!assignUser.contains(currentLoginUserId)) { if (!assignUser.contains(currentLoginUserName)) {
return map; return map;
} }
map.put(WorkFlowEnum.TASKID.getCode(), detail.getString(WorkFlowEnum.ID.getCode())); map.put(WorkFlowEnum.TASKID.getCode(), detail.getString(WorkFlowEnum.ID.getCode()));
...@@ -144,7 +144,7 @@ public class WorkflowExcuteServiceImpl implements IWorkflowExcuteService { ...@@ -144,7 +144,7 @@ public class WorkflowExcuteServiceImpl implements IWorkflowExcuteService {
.getTaskGroupName(detail.getString(WorkFlowEnum.ID.getCode())); .getTaskGroupName(detail.getString(WorkFlowEnum.ID.getCode()));
try { try {
if (taskGroupNameObject.getJSONArray(WorkFlowEnum.DATA.getCode()) == null if (taskGroupNameObject.getJSONArray(WorkFlowEnum.DATA.getCode()) == null
&& taskGroupNameObject.getJSONArray(WorkFlowEnum.DATA.getCode()).size() < 1) { || taskGroupNameObject.getJSONArray(WorkFlowEnum.DATA.getCode()).size() < 1) {
workflowFeignService.setTaskUser(detail.getString(WorkFlowEnum.ID.getCode()), userId); workflowFeignService.setTaskUser(detail.getString(WorkFlowEnum.ID.getCode()), userId);
} }
} catch (Exception e) { } catch (Exception e) {
......
...@@ -312,7 +312,6 @@ public class TreeParser { ...@@ -312,7 +312,6 @@ public class TreeParser {
String.valueOf(NAMEMethodNameme.invoke(entity)), String.valueOf(NAMEMethodNameme.invoke(entity)),
String.valueOf(NAMEMethodNameme.invoke(entity)), parentId, String.valueOf(NAMEMethodNameme.invoke(entity)), parentId,
String.valueOf(nodeTypeMethod == null ? "0" : nodeTypeMethod.invoke(entity))); String.valueOf(nodeTypeMethod == null ? "0" : nodeTypeMethod.invoke(entity)));
menu.setIsLeaf(false);
childList.add(menu); childList.add(menu);
} }
} }
......
...@@ -57,51 +57,54 @@ public class FireExpertsDto extends BaseDto { ...@@ -57,51 +57,54 @@ public class FireExpertsDto extends BaseDto {
@ApiModelProperty(value = "民族") @ApiModelProperty(value = "民族")
private String nation; private String nation;
// @ExplicitConstraint(indexNum = 7, sourceClass = RoleNameExplicitConstraint.class, method = "getAdministrativeDivisions") //固定下拉内容
@ExcelProperty(value = "籍贯", index = 7)
@ApiModelProperty(value = "籍贯")
private String nativePlace;
@ExplicitConstraint(indexNum = 8, sourceClass = CommonExplicitConstraint.class, method = "getPoliticalOutlook") //固定下拉内容 @ExplicitConstraint(indexNum = 7, sourceClass = CommonExplicitConstraint.class, method = "getPoliticalOutlook") //固定下拉内容
@ExcelProperty(value = "政治面貌", index = 8) @ExcelProperty(value = "政治面貌", index = 7)
@ApiModelProperty(value = "政治面貌") @ApiModelProperty(value = "政治面貌")
private String politicalOutlook; private String politicalOutlook;
// @ExplicitConstraint(indexNum = 9, sourceClass = RoleNameExplicitConstraint.class, method = "getAdministrativeDivisions") //固定下拉内容 @ExplicitConstraint(indexNum = 8, sourceClass = CommonExplicitConstraint.class, method = "getCitys") //固定下拉内容
@ExcelProperty(value = "籍贯", index = 8)
@ApiModelProperty(value = "籍贯")
private String nativePlace;
@ExplicitConstraint(indexNum = 9,sourceClass = CommonExplicitConstraint.class,method ="getCitys") // @ExplicitConstraint(indexNum = 9, sourceClass = RoleNameExplicitConstraint.class, method = "getAdministrativeDivisions") //固定下拉内容
@ApiModelProperty(value = "现居住地")
@ExcelProperty(value = "现居住地", index = 9)
private String residence;
@ExcelProperty(value = "籍贯/户口所在地详细地址", index = 17) @ExcelProperty(value = "籍贯/户口所在地详细地址", index = 9)
@ApiModelProperty(value = "籍贯/户口所在地详细地址") @ApiModelProperty(value = "籍贯/户口所在地详细地址")
private String nativePlaceVal; private String nativePlaceVal;
@ExplicitConstraint(indexNum =10,sourceClass = CommonExplicitConstraint.class,method ="getCitys") @ExplicitConstraint(indexNum = 10,sourceClass = CommonExplicitConstraint.class,method ="getCitys")
@ApiModelProperty(value = "现居住地")
@ExcelProperty(value = "现居住地", index = 10) @ExcelProperty(value = "现居住地", index = 10)
private String residence;
@ExplicitConstraint(indexNum =11,sourceClass = CommonExplicitConstraint.class,method ="getCitys")
@ExcelProperty(value = "现居住地", index = 11)
@ApiModelProperty(value = "居住地详情") @ApiModelProperty(value = "居住地详情")
private String residenceDetails; private String residenceDetails;
@ExcelProperty(value = "现居住地详细地址", index = 18) @ExcelProperty(value = "现居住地详细地址", index = 12)
@ApiModelProperty(value = "现居住地详细地址") @ApiModelProperty(value = "现居住地详细地址")
private String residenceDetailVal; private String residenceDetailVal;
@ExcelProperty(value = "办公电话", index = 11) @ExcelProperty(value = "办公电话", index = 13)
@ApiModelProperty(value = "办公电话") @ApiModelProperty(value = "办公电话")
private String officePhone; private String officePhone;
@ExcelProperty(value = "移动电话", index = 12) @ExcelProperty(value = "移动电话", index = 14)
@ApiModelProperty(value = "移动电话") @ApiModelProperty(value = "移动电话")
private String mobilePhone; private String mobilePhone;
@ExplicitConstraint(type = "XLLX", indexNum = 13, sourceClass = CommonExplicitConstraint.class) //动态下拉内容 @ExplicitConstraint(type = "XLLX", indexNum = 15, sourceClass = CommonExplicitConstraint.class) //动态下拉内容
@ExcelProperty(value = "最高学历", index = 13) @ExcelProperty(value = "最高学历", index = 15)
@ApiModelProperty(value = "最高学历") @ApiModelProperty(value = "最高学历")
private String highestEducation; private String highestEducation;
@ExplicitConstraint(type = "GWMC", indexNum = 14, sourceClass = CommonExplicitConstraint.class) //动态下拉内容 @ExplicitConstraint(type = "GWMC", indexNum = 16, sourceClass = CommonExplicitConstraint.class) //动态下拉内容
@ExcelProperty(value = "岗位名称", index = 14) @ExcelProperty(value = "岗位名称", index = 16)
@ApiModelProperty(value = "岗位名称") @ApiModelProperty(value = "岗位名称")
private String jobs; private String jobs;
...@@ -109,8 +112,8 @@ public class FireExpertsDto extends BaseDto { ...@@ -109,8 +112,8 @@ public class FireExpertsDto extends BaseDto {
@ApiModelProperty(value = "岗位名称code") @ApiModelProperty(value = "岗位名称code")
private String jobsCode; private String jobsCode;
@ExplicitConstraint(type = "ZJLY", indexNum = 15, sourceClass = CommonExplicitConstraint.class) //动态下拉内容 @ExplicitConstraint(type = "ZJLY", indexNum = 17, sourceClass = CommonExplicitConstraint.class) //动态下拉内容
@ExcelProperty(value = "消防专家领域", index = 15) @ExcelProperty(value = "消防专家领域", index = 17)
@ApiModelProperty(value = "消防专家领域") @ApiModelProperty(value = "消防专家领域")
private String expert; private String expert;
...@@ -144,7 +147,7 @@ public class FireExpertsDto extends BaseDto { ...@@ -144,7 +147,7 @@ public class FireExpertsDto extends BaseDto {
@ApiModelProperty(value = "消防机构name") @ApiModelProperty(value = "消防机构name")
private Long fireTeamName; private Long fireTeamName;
@ExcelProperty(value = "备注", index = 16) @ExcelProperty(value = "备注", index = 18)
@ApiModelProperty(value = "备注") @ApiModelProperty(value = "备注")
private String note; private String note;
......
...@@ -72,4 +72,12 @@ public class OrgMenuDto { ...@@ -72,4 +72,12 @@ public class OrgMenuDto {
public OrgMenuDto() { public OrgMenuDto() {
// TODO Auto-generated constructor stub // TODO Auto-generated constructor stub
} }
public OrgMenuDto(Long key, Long value, String title, String name, List<OrgMenuDto> children) {
this.key = key;
this.value = value;
this.title = title;
this.name = name;
this.children = children;
}
} }
...@@ -306,6 +306,7 @@ public class WaterResourceDto extends BaseDto { ...@@ -306,6 +306,7 @@ public class WaterResourceDto extends BaseDto {
@ApiModelProperty("设施定义名称") @ApiModelProperty("设施定义名称")
@ExcelProperty(value = "设施定义名称", index = 41) @ExcelProperty(value = "设施定义名称", index = 41)
@ExplicitConstraint(indexNum = 41, sourceClass = CommonExplicitConstraint.class, method = "getEquipDefinition")
private String equipName; private String equipName;
@ExcelIgnore @ExcelIgnore
...@@ -313,8 +314,9 @@ public class WaterResourceDto extends BaseDto { ...@@ -313,8 +314,9 @@ public class WaterResourceDto extends BaseDto {
private Long equipCategoryId; private Long equipCategoryId;
// BUG 2935 优化项 分类从93060000 取得字典数据 by kongfm 2021-09-17 // BUG 2935 优化项 分类从93060000 取得字典数据 by kongfm 2021-09-17
@ApiModelProperty("设施分类名称") @ApiModelProperty("设施分类名称")
@ExplicitConstraint(indexNum = 42, sourceClass = CommonExplicitConstraint.class, method = "getEquipCategory") @ExcelIgnore
@ExcelProperty(value = "设施分类名称", index = 42) // @ExplicitConstraint(indexNum = 42, sourceClass = CommonExplicitConstraint.class, method = "getEquipCategory")
// @ExcelProperty(value = "设施分类名称", index = 42)
private String equipCategoryName; private String equipCategoryName;
@ApiModelProperty("设施编码") @ApiModelProperty("设施编码")
...@@ -322,15 +324,15 @@ public class WaterResourceDto extends BaseDto { ...@@ -322,15 +324,15 @@ public class WaterResourceDto extends BaseDto {
private String equipCode; private String equipCode;
@ApiModelProperty("维保周期") @ApiModelProperty("维保周期")
@ExcelProperty(value = "维保周期(月)", index = 43) @ExcelProperty(value = "维保周期(月)", index = 42)
private String maintenancePeriod; private String maintenancePeriod;
@ApiModelProperty(value = "经度") @ApiModelProperty(value = "经度")
@ExcelProperty(value = "经度", index = 44) @ExcelProperty(value = "经度", index = 43)
private Double longitude; private Double longitude;
@ApiModelProperty(value = "纬度") @ApiModelProperty(value = "纬度")
@ExcelProperty(value = "纬度", index = 45) @ExcelProperty(value = "纬度", index = 44)
private Double latitude; private Double latitude;
} }
...@@ -32,7 +32,7 @@ public class TemplateCellWriteHandlerDate implements SheetWriteHandler { ...@@ -32,7 +32,7 @@ public class TemplateCellWriteHandlerDate implements SheetWriteHandler {
/** /**
* 避免生成的导入模板下拉值获取不到 * 避免生成的导入模板下拉值获取不到
*/ */
private static final Integer LIMIT_NUMBER = 1; private static final Integer LIMIT_NUMBER = 0;
......
...@@ -223,4 +223,7 @@ public interface EquipFeignClient { ...@@ -223,4 +223,7 @@ public interface EquipFeignClient {
*/ */
@RequestMapping(value = "equipment-category/tree/{type}", method = RequestMethod.GET) @RequestMapping(value = "equipment-category/tree/{type}", method = RequestMethod.GET)
ResponseModel<List<LinkedHashMap<String, Object>>> getEquipmentCategory(@PathVariable String type); ResponseModel<List<LinkedHashMap<String, Object>>> getEquipmentCategory(@PathVariable String type);
@RequestMapping(value = "/equipment/listLike/{code}", method = RequestMethod.GET)
ResponseModel<List<LinkedHashMap<String, Object>>> listLikePage(@PathVariable String code);
} }
...@@ -84,4 +84,8 @@ public interface OrgUsrMapper extends BaseMapper<OrgUsr> { ...@@ -84,4 +84,8 @@ public interface OrgUsrMapper extends BaseMapper<OrgUsr> {
List< OrgUsrExcelDto> exportPersonToExcelByParentId(Long parentId); List< OrgUsrExcelDto> exportPersonToExcelByParentId(Long parentId);
List<OrgUsr> amosIdExist(String amosId); List<OrgUsr> amosIdExist(String amosId);
void updatelistByParentId(String codex, String code);
} }
...@@ -104,7 +104,7 @@ ...@@ -104,7 +104,7 @@
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 par.typeCode!=""'> <if test='par.typeCode!=null and par.typeCode!=""'>
and a.type_code in (116,830,114) and a.type_code in (#{par.typeCode})
</if> </if>
<if test='par.distance!=null'> <if test='par.distance!=null'>
and Round(st_distance(point(a.longitude,a.latitude),point(#{par.longitude},#{par.latitude}))*111195,1) &lt;= #{par.distance} and Round(st_distance(point(a.longitude,a.latitude),point(#{par.longitude},#{par.latitude}))*111195,1) &lt;= #{par.distance}
......
...@@ -47,94 +47,93 @@ ...@@ -47,94 +47,93 @@
Round(st_distance(point(a.longitude,a.latitude),point(#{par.longitude},#{par.latitude}))*111195,1) Round(st_distance(point(a.longitude,a.latitude),point(#{par.longitude},#{par.latitude}))*111195,1)
AS distance, AS distance,
SUM(case when csps.person_number is null then 0 else (select SUM(csps.person_number) from cb_special_position_staff csps where a.sequence_nbr = csps.company_id and csps.is_delete=0 ) as userNum,
csps.person_number end) as userNum, (select SUM(cre.vehicle_number) from cb_rescue_equipment cre where a.sequence_nbr = cre.company_id and cre.is_delete=0 ) as carNum
SUM(case when cre.vehicle_number is null then 0 else cre.vehicle_number end )as
carNum
<!-- <!--
case when csps.person_number is null then 0 else case when csps.person_number is null then 0 else
csps.person_number end as userNum, csps.person_number end as userNum,
case when cre.vehicle_number is null then 0 else cre.vehicle_number end as case when cre.vehicle_number is null then 0 else cre.vehicle_number end as
carNum--> carNum-->
FROM FROM
cb_linkage_unit a cb_linkage_unit a
LEFT JOIN cb_special_position_staff csps ON a.sequence_nbr = <!-- LEFT JOIN cb_special_position_staff csps ON a.sequence_nbr =
csps.company_id csps.company_id
LEFT JOIN cb_rescue_equipment cre on a.sequence_nbr = cre.company_id LEFT JOIN cb_rescue_equipment cre on a.sequence_nbr = cre.company_id-->
where a.is_delete=0 and a.longitude is not null and where a.is_delete=0 and a.longitude is not null and
a.latitude is not null GROUP BY a.sequence_nbr a.latitude is not null
<if test='par.distance!=null'> <if test='par.distance!=null'>
and and
Round(st_distance(point(a.longitude,a.latitude),point(#{par.longitude},#{par.latitude}))*111195,1) Round(st_distance(point(a.longitude,a.latitude),point(#{par.longitude},#{par.latitude}))*111195,1)
&lt;= &lt;=
#{par.distance} #{par.distance}
</if> </if>
ORDER BY distance limit #{pageNum},#{pageSize} ORDER BY distance limit #{pageNum},#{pageSize}
</select> </select>
<select id="listLinkageUnitZhDtoCount" resultType="Integer"> <select id="listLinkageUnitZhDtoCount" resultType="Integer">
select select
COUNT(a.sequence_nbr) num COUNT(a.sequence_nbr) num
FROM cb_linkage_unit a FROM cb_linkage_unit a
where a.longitude where a.is_delete=0 and a.longitude is not null and a.latitude is not null
is not null and a.latitude is not null <if test='par.distance!=null'>
<if test='par.distance!=null'> and
and Round(st_distance(point(a.longitude,a.latitude),point(#{par.longitude},#{par.latitude}))*111195,1)
Round(st_distance(point(a.longitude,a.latitude),point(#{par.longitude},#{par.latitude}))*111195,1) &lt;=
&lt;= #{par.distance}
#{par.distance} </if>
</if>
</select> </select>
<select id="getEmergencyLinkageUnitCodeGroupByAndCount" <select id="getEmergencyLinkageUnitCodeGroupByAndCount"
resultType="java.util.Map"> resultType="java.util.Map">
SELECT SELECT
emergency_linkage_unit_code as emergency_linkage_unit_code as
emergencyLinkageUnitCode, emergencyLinkageUnitCode,
COUNT(unit_code) AS count COUNT(unit_code) AS count
FROM FROM
cb_linkage_unit cb_linkage_unit
WHERE WHERE
is_delete = 0 is_delete = 0
GROUP BY GROUP BY
emergency_linkage_unit_code emergency_linkage_unit_code
</select> </select>
<select id="exportToExcel" <select id="exportToExcel"
resultType="com.yeejoin.amos.boot.module.common.api.dto.LinkageUnitDto"> resultType="com.yeejoin.amos.boot.module.common.api.dto.LinkageUnitDto">
select select
a.unit_name unitName, a.unit_name unitName,
a.linkage_unit_type a.linkage_unit_type
linkageUnitType, linkageUnitType,
a.address , a.address ,
a.latitude, a.latitude,
a.longitude, a.longitude,
a.agreement_start_date agreementStartDate, a.agreement_start_date agreementStartDate,
a.agreement_end_date a.agreement_end_date
agreementEndDate, agreementEndDate,
a.contact_user contactUser, a.contact_user contactUser,
a.contact_phone a.contact_phone
contactPhone, contactPhone,
b.* b.*
from cb_linkage_unit a LEFT JOIN from cb_linkage_unit a LEFT JOIN
(SELECT (SELECT
m.instance_id, m.instance_id,
max(case m.field_code when 'emergencyServiceContent' then max(case m.field_code when 'emergencyServiceContent' then
m.field_value end) emergencyServiceContent, m.field_value end) emergencyServiceContent,
max(case m.field_code when max(case m.field_code when
'fireRescueCapability' then m.field_value end) fireRescueCapability, 'fireRescueCapability' then m.field_value end) fireRescueCapability,
max(case m.field_code when 'responsibilitiesSituation' then max(case m.field_code when 'responsibilitiesSituation' then
m.field_value end) responsibilitiesSituation, m.field_value end) responsibilitiesSituation,
max(case m.field_code max(case m.field_code
when 'unitSituation' then m.field_value end) unitSituation when 'unitSituation' then m.field_value end) unitSituation
FROM FROM
cb_dynamic_form_instance m GROUP BY m.instance_id) b cb_dynamic_form_instance m GROUP BY m.instance_id) b
on on
b.instance_id=a.instance_id where a.unit_name is not null and a.is_delete=0 b.instance_id=a.instance_id where a.unit_name is not null and a.is_delete=0
</select> </select>
<!--联动单位列表按时间倒叙排列add order by clu.rec_date desc 同时处理单位根节点-1时查询全部数据问题 2021-09-08 by kongfm --> <!--联动单位列表按时间倒叙排列add order by clu.rec_date desc 同时处理单位根节点-1时查询全部数据问题 2021-09-08 by kongfm -->
......
...@@ -569,4 +569,14 @@ GROUP BY ...@@ -569,4 +569,14 @@ GROUP BY
amos_org_id = #{amosId} amos_org_id = #{amosId}
</select> </select>
<update id="updatelistByParentId">
UPDATE cb_org_usr
SET biz_org_code=replace(biz_org_code,#{code},#{codex})
WHERE biz_org_code like concat(#{code}, '%');
</update>
</mapper> </mapper>
...@@ -49,6 +49,11 @@ public interface AlertCalledMapper extends BaseMapper<AlertCalled> { ...@@ -49,6 +49,11 @@ public interface AlertCalledMapper extends BaseMapper<AlertCalled> {
String data, String data,
String lift); String lift);
int selectAllCount(Integer alertStatus,
String alertTypeCode ,
String alertSourceCode,
String startTime,
String endTime);
Integer AlertCalledcount(@Param("alertStatus")int alertStatus); Integer AlertCalledcount(@Param("alertStatus")int alertStatus);
......
...@@ -146,6 +146,28 @@ ...@@ -146,6 +146,28 @@
</where> </where>
</select> </select>
<select id="selectAllCount" resultType="int">
SELECT
COUNT(*)
FROM
jc_alert_called
<where>
is_delete = 0
<if test="alertStatus!= null ">
and alert_status = #{alertStatus}
</if>
<if test="startTime!= null and endTime != null">
and call_time between #{startTime} and #{endTime}
</if>
<if test="alertTypeCode!= null ">
and alarm_type_code = #{alertTypeCode}
</if>
<if test="alertSourceCode!= null ">
and alert_source_code = #{alertSourceCode}
</if>
</where>
</select>
<select id="AlertCalledcountTime" resultType="Integer"> <select id="AlertCalledcountTime" resultType="Integer">
......
...@@ -13,7 +13,10 @@ public enum CheckTypeSuEnum { ...@@ -13,7 +13,10 @@ public enum CheckTypeSuEnum {
*/ */
DAILY("日常检查", "1", "daily"), DAILY("日常检查", "1", "daily"),
SPECIAL_RQ("燃气专项", "2", "special"), SPECIAL_RQ("燃气专项", "2", "special"),
SPECIAL_GW("高温专项", "3", "special"); SPECIAL_GW("高温专项", "3", "special"),
SPECIAL_DQ("电气专项", "4", "special"),
SPECIAL_HD("重大活动专项", "5", "special"),
SPECIAL_BZ("重大保障专项", "6", "special");
/** /**
* 名字 * 名字
......
...@@ -12,7 +12,9 @@ public enum PlanStatusEnum { ...@@ -12,7 +12,9 @@ public enum PlanStatusEnum {
EXAMINE_TWO("二级待审核",2, 3), EXAMINE_TWO("二级待审核",2, 3),
EXAMINE_THREE("三级待审核",3, 4), EXAMINE_THREE("三级待审核",3, 4),
EXAMINE_FORMULATE("已审核/检查内容未制定",4, 5), EXAMINE_FORMULATE("已审核/检查内容未制定",4, 5),
EXAMINE_DEVELOPED("检查内容已制定/未执行",5, 5); EXAMINE_DEVELOPED("检查内容已制定/未执行",5, 6),
IN_EXECUTION("执行中",6, 7),
COMPLETED("已完成",7, 7);
/** /**
* 名称 * 名称
......
...@@ -171,6 +171,17 @@ public class Plan extends BasicEntity { ...@@ -171,6 +171,17 @@ public class Plan extends BasicEntity {
private String checkLevel; private String checkLevel;
/** /**
* 检查人单位id
*/
@Column(name="check_unit_id")
private String checkUnitId;
/**
* 检查人单位名称
*/
@Column(name="check_unit_name")
private String checkUnitName;
/**
* 备注 * 备注
*/ */
private String remark; private String remark;
...@@ -760,4 +771,20 @@ public class Plan extends BasicEntity { ...@@ -760,4 +771,20 @@ public class Plan extends BasicEntity {
public void setCheckLevel(String checkLevel) { public void setCheckLevel(String checkLevel) {
this.checkLevel = checkLevel; this.checkLevel = checkLevel;
} }
public String getCheckUnitId() {
return checkUnitId;
}
public void setCheckUnitId(String checkUnitId) {
this.checkUnitId = checkUnitId;
}
public String getCheckUnitName() {
return checkUnitName;
}
public void setCheckUnitName(String checkUnitName) {
this.checkUnitName = checkUnitName;
}
} }
\ No newline at end of file
...@@ -11,24 +11,24 @@ import lombok.Data; ...@@ -11,24 +11,24 @@ import lombok.Data;
public class AlertHandlerInfoDto { public class AlertHandlerInfoDto {
@ApiModelProperty(value = "处置流程") @ApiModelProperty(value = "处置流程")
String process; String abProcess;
@ApiModelProperty(value = "接警") @ApiModelProperty(value = "接警")
String answerThePolice; String acAnswerThePolice;
@ApiModelProperty(value = "上报") @ApiModelProperty(value = "上报")
String report; String acReport;
@ApiModelProperty(value = "派遣/通知") @ApiModelProperty(value = "派遣/通知")
String notice; String adNotice;
@ApiModelProperty(value = "到达") @ApiModelProperty(value = "到达")
String arrive; String aedArrive;
@ApiModelProperty(value = "完成") @ApiModelProperty(value = "完成")
String complete; String afeComplete;
@ApiModelProperty(value = "回访") @ApiModelProperty(value = "回访")
String returnVisit; String agReturnVisit;
} }
...@@ -54,4 +54,7 @@ public class AlertPaperInfoDto { ...@@ -54,4 +54,7 @@ public class AlertPaperInfoDto {
@ApiModelProperty(value = "停留时间") @ApiModelProperty(value = "停留时间")
private String stopTime; private String stopTime;
@ApiModelProperty(value = "状态信息")
private String alertStatus;
} }
package com.yeejoin.amos.boot.module.tzs.api.dto;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import com.yeejoin.amos.boot.biz.common.dto.BaseDto;
import lombok.Data;
import lombok.EqualsAndHashCode;
import java.util.Date;
/**
*
*
* @author litw
* @date 2021-09-28
*/
@Data
@EqualsAndHashCode(callSuper = true)
@ApiModel(value="ElevatorAlarmDto", description="")
public class ElevatorAlarmDto extends BaseDto {
private static final long serialVersionUID = 1L;
@ApiModelProperty(value = "电梯注册码")
private String registerCode;
@ApiModelProperty(value = "原始故障编号")
private String faultId;
@ApiModelProperty(value = "故障发生时间")
private Date startDate;
@ApiModelProperty(value = "故障类型")
private String type;
@ApiModelProperty(value = "处置状态。0:处置完成。1:故障发生 2:发出通知 3:处置响应 4:处置到场 5:误报")
private Integer dealStatus;
@ApiModelProperty(value = "处置时间")
private Date dealDate;
@ApiModelProperty(value = "处置人")
private Integer dealPerson;
@ApiModelProperty(value = "现场确认是否困人。0:不困人,1:困人")
private Integer isTrap;
@ApiModelProperty(value = "是否自恢复 0:否1:是")
private Integer selfrepair;
@ApiModelProperty(value = "故障发生时的总接触器吸合或是断开。0:吸合,1:断开")
private Integer dealNote;
@ApiModelProperty(value = "是否自恢复 0:否1:是")
private Integer mainContactor;
@ApiModelProperty(value = "故障发生时的运行接触器吸合或是断开。0:吸合,1:断开")
private Integer runContactor;
@ApiModelProperty(value = "故障发生时的安全回路是否断开 0:正常,1:断开")
private Integer circuit;
@ApiModelProperty(value = "故障发生时的轿厢运行状态。1:停止,2:运行")
private Integer carStatus;
@ApiModelProperty(value = "故障发生时的方向。1:无方向 2:上行 3:下行")
private Integer direction;
@ApiModelProperty(value = "故障发生时的轿厢是否在门区。1:轿厢在门区 0:轿厢在非门区")
private Integer isZone;
@ApiModelProperty(value = "故障发生时的当前物理楼层")
private Integer floor;
@ApiModelProperty(value = "故障发生时的关门到位 1:关门到位,0:无关门到位信号")
private Integer doorStatus;
@ApiModelProperty(value = "故障发生时的上极限是否动作 0:否,1:是")
private Integer upLimit;
@ApiModelProperty(value = "故障发生时的下极限是否动作 0:否,1:是")
private Integer downLimit;
@ApiModelProperty(value = "故障发生时的轿厢报警按钮是否动作 0:否,1:是")
private Integer alarm;
@ApiModelProperty(value = "累计运行小时数,保留到小数点后两位")
private Double hours;
@ApiModelProperty(value = "累计运行次数")
private Integer runCount;
}
package com.yeejoin.amos.boot.module.tzs.api.dto;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import com.yeejoin.amos.boot.biz.common.dto.BaseDto;
import lombok.Data;
import lombok.EqualsAndHashCode;
import java.util.Date;
/**
*
*
* @author litw
* @date 2021-09-28
*/
@Data
@EqualsAndHashCode(callSuper = true)
@ApiModel(value="ElevatorStatusDto", description="")
public class ElevatorStatusDto extends BaseDto {
private static final long serialVersionUID = 1L;
@ApiModelProperty(value = "电梯注册码")
private String registerCode;
@ApiModelProperty(value = "原始状态编号")
private String statusId;
@ApiModelProperty(value = "是否在线。1:是,0:否")
private Integer isOnline;
@ApiModelProperty(value = "运行数据上传时间")
private Date uploadDate;
@ApiModelProperty(value = "总接触器吸合或是断开。0:吸合,1:断开")
private Integer mainContactor;
@ApiModelProperty(value = "运行接触器吸合或是断开。0:吸合,1:断开")
private Integer runContactor;
@ApiModelProperty(value = "安全回路是否断开,0:正常,1:断开")
private Integer circuit;
@ApiModelProperty(value = "当前电梯运行模式。1:停止服务 2:正常运行 3:检修 4:消防返回 5:消防员运行 6:应急电源运行 7:地震模式 8: 未知")
private Integer serviceModel;
@ApiModelProperty(value = "轿厢运行状态。1:停止,2:运行")
private Integer liftStatus;
@ApiModelProperty(value = "轿厢运行方向。1:无方向 2:上行 3:下行")
private Integer liftDirection;
@ApiModelProperty(value = "轿厢是否在门区。1:轿厢在门区 0:轿厢在非门区")
private Integer isZone;
@ApiModelProperty(value = "运行速度")
private Integer elevatorSpeed;
@ApiModelProperty(value = "当前物理楼层")
private Integer currFloor;
@ApiModelProperty(value = "关门到位 1:关门到位,0:无关门到位信号")
private Integer doorStatus;
@ApiModelProperty(value = "上极限是否动作 0:否,1:是")
private Integer upLimit;
@ApiModelProperty(value = "下极限是否动作 0:否,1:是")
private Integer downLimit;
@ApiModelProperty(value = "轿厢报警按钮是否动作 0:否,1:是")
private Integer alarm;
@ApiModelProperty(value = "轿厢内是否有人 0:无,1:有")
private Integer personFlag;
@ApiModelProperty(value = "累计运行小时数,保留到小数点后两位")
private Double hours;
@ApiModelProperty(value = "累计运行次数")
private Integer runCount;
}
package com.yeejoin.amos.boot.module.tzs.api.dto;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
/**
* @author litw
* @date 2021-09-29.
*/
@Data
public class ElevatorStatusHandleDto {
@ApiModelProperty(value = "当前电梯运行模式。1:停止服务 2:正常运行 3:检修 4:消防返回 5:消防员运行 6:应急电源运行 7:地震模式 8: 未知")
private String serviceModel;
@ApiModelProperty(value = "轿厢运行状态。1:停止,2:运行")
private String liftStatus;
@ApiModelProperty(value = "轿厢运行方向。1:无方向 2:上行 3:下行")
private String liftDirection;
@ApiModelProperty(value = "轿厢是否在门区。1:轿厢在门区 0:轿厢在非门区")
private String isZone;
@ApiModelProperty(value = "关门到位 1:关门到位,0:无关门到位信号")
private String doorStatus;
@ApiModelProperty(value = "轿厢内是否有人 0:无,1:有")
private String personFlag;
@ApiModelProperty(value = "当前物理楼层")
private Integer currFloor;
}
package com.yeejoin.amos.boot.module.tzs.api.dto;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import java.util.Date;
/**
* @author litw
* @date 2021-09-29.
*/
@Data
@ApiModel(value="ElevatorWlInfoDto", description="电梯物联信息")
public class ElevatorWlInfoDto {
/**
*
*/
private static final long serialVersionUID = 1L;
/**
* 电梯id
*/
@ApiModelProperty(value = "电梯id")
private Long sequenceNbr;
/**
* 注册编码
*/
@ApiModelProperty(value = "注册编码")
private String registerCode;
/**
* 电梯识别码
*/
@ApiModelProperty(value = "电梯识别码")
private Integer rescueCode;
/**
* 地址
*/
@ApiModelProperty(value = "地址")
private String address;
/**
* 发生时间
*/
@ApiModelProperty(value = "发生时间")
private Date happenTime ;
/**
* 故障类型
*/
@ApiModelProperty(value = "故障类型")
private String type ;
/**
* 物联服务提供商
*/
@ApiModelProperty(value = "物联服务提供商")
private String IotServiceProvider ;
/**
* 处置状态
*/
@ApiModelProperty(value = "处置状态")
private String dealStatus ;
/**
* 设备种类
*/
@ApiModelProperty(value = "设备种类")
private String category ;
/**
* 区域
*/
@ApiModelProperty(value = "区域")
private String area ;
/**
* 设备种类临时
*/
@ApiModelProperty(value = "设备种类临时")
private String categoryName ;
int page;
int size;
}
...@@ -104,4 +104,28 @@ public class EsElevatorDto { ...@@ -104,4 +104,28 @@ public class EsElevatorDto {
@ApiModelProperty(value = "发生时间") @ApiModelProperty(value = "发生时间")
private Date happenTime ; private Date happenTime ;
/**
* 故障类型
*/
@ApiModelProperty(value = "故障类型")
private String type ;
/**
* 物联服务提供商
*/
@ApiModelProperty(value = "物联服务提供商")
private String IOTServiceProvider ;
/**
* 处置状态
*/
@ApiModelProperty(value = "处置状态")
private String status ;
/**
* 设备种类
*/
@ApiModelProperty(value = "设备种类")
private String category ;
} }
package com.yeejoin.amos.boot.module.tzs.api.entity;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.yeejoin.amos.boot.biz.common.entity.BaseEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import java.util.Date;
/**
*
*
* @author litw
* @date 2021-09-28
*/
@Data
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
@TableName("tz_elevator_alarm")
public class ElevatorAlarm extends BaseEntity {
private static final long serialVersionUID = 1L;
/**
* 电梯注册码
*/
@TableField("register_code")
private String registerCode;
/**
* 原始故障编号
*/
@TableField("fault_id")
private String faultId;
/**
* 故障发生时间
*/
@TableField("start_date")
private Date startDate;
/**
* 故障类型
*/
@TableField("type")
private String type;
/**
* 处置状态。0:处置完成。1:故障发生 2:发出通知 3:处置响应 4:处置到场 5:误报
*/
@TableField("deal_status")
private Integer dealStatus;
/**
* 处置时间
*/
@TableField("deal_date")
private Date dealDate;
/**
* 处置人
*/
@TableField("deal_person")
private Integer dealPerson;
/**
* 现场确认是否困人。0:不困人,1:困人
*/
@TableField("is_trap")
private Integer isTrap;
/**
* 是否自恢复 0:否1:是
*/
@TableField("selfrepair")
private Integer selfrepair;
/**
* 故障发生时的总接触器吸合或是断开。0:吸合,1:断开
*/
@TableField("deal_note")
private Integer dealNote;
/**
* 是否自恢复 0:否1:是
*/
@TableField("main_contactor")
private Integer mainContactor;
/**
* 故障发生时的运行接触器吸合或是断开。0:吸合,1:断开
*/
@TableField("run_contactor")
private Integer runContactor;
/**
* 故障发生时的安全回路是否断开 0:正常,1:断开
*/
@TableField("circuit")
private Integer circuit;
/**
* 故障发生时的轿厢运行状态。1:停止,2:运行
*/
@TableField("car_status")
private Integer carStatus;
/**
* 故障发生时的方向。1:无方向 2:上行 3:下行
*/
@TableField("direction")
private Integer direction;
/**
* 故障发生时的轿厢是否在门区。1:轿厢在门区 0:轿厢在非门区
*/
@TableField("is_zone")
private Integer isZone;
/**
* 故障发生时的当前物理楼层
*/
@TableField("floor")
private Integer floor;
/**
* 故障发生时的关门到位 1:关门到位,0:无关门到位信号
*/
@TableField("door_status")
private Integer doorStatus;
/**
* 故障发生时的上极限是否动作 0:否,1:是
*/
@TableField("up_limit")
private Integer upLimit;
/**
* 故障发生时的下极限是否动作 0:否,1:是
*/
@TableField("down_limit")
private Integer downLimit;
/**
* 故障发生时的轿厢报警按钮是否动作 0:否,1:是
*/
@TableField("alarm")
private Integer alarm;
/**
* 累计运行小时数,保留到小数点后两位
*/
@TableField("hours")
private Double hours;
/**
* 累计运行次数
*/
@TableField("run_count")
private Integer runCount;
}
package com.yeejoin.amos.boot.module.tzs.api.entity;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.yeejoin.amos.boot.biz.common.entity.BaseEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import java.util.Date;
/**
*
*
* @author litw
* @date 2021-09-28
*/
@Data
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
@TableName("tz_elevator_status")
public class ElevatorStatus extends BaseEntity {
private static final long serialVersionUID = 1L;
/**
* 电梯注册码
*/
@TableField("register_code")
private String registerCode;
/**
* 原始状态编号
*/
@TableField("status_id")
private String statusId;
/**
* 是否在线。1:是,0:否
*/
@TableField("is_online")
private Integer isOnline;
/**
* 运行数据上传时间
*/
@TableField("upload_date")
private Date uploadDate;
/**
* 总接触器吸合或是断开。0:吸合,1:断开
*/
@TableField("main_contactor")
private Integer mainContactor;
/**
* 运行接触器吸合或是断开。0:吸合,1:断开
*/
@TableField("run_contactor")
private Integer runContactor;
/**
* 安全回路是否断开,0:正常,1:断开
*/
@TableField("circuit")
private Integer circuit;
/**
* 当前电梯运行模式。1:停止服务 2:正常运行 3:检修 4:消防返回 5:消防员运行 6:应急电源运行 7:地震模式 8: 未知
*/
@TableField("service_model")
private Integer serviceModel;
/**
* 轿厢运行状态。1:停止,2:运行
*/
@TableField("lift_status")
private Integer liftStatus;
/**
* 轿厢运行方向。1:无方向 2:上行 3:下行
*/
@TableField("lift_direction")
private Integer liftDirection;
/**
* 轿厢是否在门区。1:轿厢在门区 0:轿厢在非门区
*/
@TableField("is_zone")
private Integer isZone;
/**
* 运行速度
*/
@TableField("elevator_speed")
private Integer elevatorSpeed;
/**
* 当前物理楼层
*/
@TableField("curr_floor")
private Integer currFloor;
/**
* 关门到位 1:关门到位,0:无关门到位信号
*/
@TableField("door_status")
private Integer doorStatus;
/**
* 上极限是否动作 0:否,1:是
*/
@TableField("up_limit")
private Integer upLimit;
/**
* 下极限是否动作 0:否,1:是
*/
@TableField("down_limit")
private Integer downLimit;
/**
* 轿厢报警按钮是否动作 0:否,1:是
*/
@TableField("alarm")
private Integer alarm;
/**
* 轿厢内是否有人 0:无,1:有
*/
@TableField("person_flag")
private Integer personFlag;
/**
* 累计运行小时数,保留到小数点后两位
*/
@TableField("hours")
private Double hours;
/**
* 累计运行次数
*/
@TableField("run_count")
private Integer runCount;
}
package com.yeejoin.amos.boot.module.tzs.api.enums;
/**
*
* <pre>
* 电梯故障处置状态枚举
* </pre>
*
* @author gwb
* @version $Id: LiftServiceModelEnum.java, v 0.1 2021年9月29日 上午9:24:15 gwb Exp $
*/
public enum LiftAlarmDealStatusEnum{
DISPOSAL_COMPLETED(0,"处置完成"),
FAULT_OCCURRENCE(1,"故障发生"),
GIVE_NOTICE(2,"发出通知"),
DISPOSAL_RESPONSE(3,"处置响应"),
DISPOSAL_SITE(4,"处置到场"),
FALSE_ALARM(5,"误报");
/**
* 编码
*/
private Integer code;
/**
* 名称
*/
private String name;
// 构造方法
private LiftAlarmDealStatusEnum(Integer code, String name) {
this.code = code;
this.name = name;
}
public Integer getCode() {
return code;
}
public String getName()
{
return name;
}
public static LiftAlarmDealStatusEnum getEnum(Integer code)
{
for (LiftAlarmDealStatusEnum liftAlarmDealStatusEnum : LiftAlarmDealStatusEnum.values())
{
if (liftAlarmDealStatusEnum.getCode().equals(code))
{
return liftAlarmDealStatusEnum;
}
}
return null;
}
}
package com.yeejoin.amos.boot.module.tzs.api.enums;
/**
*
* <pre>
* 电梯安全回路状态枚举
* </pre>
*
* @author gwb
* @version $Id: LiftCircuitStatusEnum.java, v 0.1 2021年9月29日 上午9:23:00 gwb Exp $
*/
public enum LiftBitStatusEnum{
NO(1,"否"),
YES (2,"是");
/**
* 编码
*/
private Integer code;
/**
* 名称
*/
private String name;
// 构造方法
private LiftBitStatusEnum(Integer code, String name) {
this.code = code;
this.name = name;
}
public Integer getCode() {
return code;
}
public String getName()
{
return name;
}
public static LiftBitStatusEnum getEnum(Integer code)
{
for (LiftBitStatusEnum liftBitStatusEnum : LiftBitStatusEnum.values())
{
if (liftBitStatusEnum.getCode().equals(code))
{
return liftBitStatusEnum;
}
}
return null;
}
}
package com.yeejoin.amos.boot.module.tzs.api.enums;
/**
*
* <pre>
* 电梯安全回路状态枚举
* </pre>
*
* @author gwb
* @version $Id: LiftCircuitStatusEnum.java, v 0.1 2021年9月29日 上午9:23:00 gwb Exp $
*/
public enum LiftCircuitStatusEnum{
NORMAL(0,"正常"),
BREAK (1,"断开");
/**
* 编码
*/
private Integer code;
/**
* 名称
*/
private String name;
// 构造方法
private LiftCircuitStatusEnum(Integer code, String name) {
this.code = code;
this.name = name;
}
public Integer getCode() {
return code;
}
public String getName()
{
return name;
}
public static LiftCircuitStatusEnum getEnum(Integer code)
{
for (LiftCircuitStatusEnum liftCircuitStatusEnum : LiftCircuitStatusEnum.values())
{
if (liftCircuitStatusEnum.getCode().equals(code))
{
return liftCircuitStatusEnum;
}
}
return null;
}
}
package com.yeejoin.amos.boot.module.tzs.api.enums;
/**
*
* <pre>
* 电梯接触器状态枚举
* </pre>
*
* @author gwb
* @version $Id: LiftContactorStatusEnum.java, v 0.1 2021年9月29日 上午9:08:16 gwb Exp $
*/
public enum LiftContactorStatusEnum{
PULL(0,"吸合"),
BREAK (1,"断开");
/**
* 编码
*/
private Integer code;
/**
* 名称
*/
private String name;
// 构造方法
private LiftContactorStatusEnum(Integer code, String name) {
this.code = code;
this.name = name;
}
public Integer getCode() {
return code;
}
public String getName()
{
return name;
}
public static LiftContactorStatusEnum getEnum(Integer code)
{
for (LiftContactorStatusEnum liftContactorStatusEnum : LiftContactorStatusEnum.values())
{
if (liftContactorStatusEnum.getCode().equals(code))
{
return liftContactorStatusEnum;
}
}
return null;
}
}
package com.yeejoin.amos.boot.module.tzs.api.enums;
/**
*
* <pre>
* 电梯轿厢运行方向枚举
* </pre>
*
* @author gwb
* @version $Id: LiftDirectionEnum.java, v 0.1 2021年9月29日 上午9:33:40 gwb Exp $
*/
public enum LiftDirectionEnum{
No (1,"无方向"),
Up (2,"上行"),
Down (3,"下行");
/**
* 编码
*/
private Integer code;
/**
* 名称
*/
private String name;
// 构造方法
private LiftDirectionEnum(Integer code, String name) {
this.code = code;
this.name = name;
}
public Integer getCode() {
return code;
}
public String getName()
{
return name;
}
public static LiftDirectionEnum getEnum(Integer code)
{
for (LiftDirectionEnum liftDirectionEnum : LiftDirectionEnum.values())
{
if (liftDirectionEnum.getCode().equals(code))
{
return liftDirectionEnum;
}
}
return null;
}
}
package com.yeejoin.amos.boot.module.tzs.api.enums;
/**
*
* <pre>
* 电梯关门到位枚举
* </pre>
*
* @author gwb
* @version $Id: LiftDoorStatusEnum.java, v 0.1 2021年9月29日 上午9:39:52 gwb Exp $
*/
public enum LiftDoorStatusEnum{
NOT_CLOSED (1,"无关门到位信号"),
CLOSE (2,"关门到位");
/**
* 编码
*/
private Integer code;
/**
* 名称
*/
private String name;
// 构造方法
private LiftDoorStatusEnum(Integer code, String name) {
this.code = code;
this.name = name;
}
public Integer getCode() {
return code;
}
public String getName()
{
return name;
}
public static LiftDoorStatusEnum getEnum(Integer code)
{
for (LiftDoorStatusEnum liftDoorStatusEnum : LiftDoorStatusEnum.values())
{
if (liftDoorStatusEnum.getCode().equals(code))
{
return liftDoorStatusEnum;
}
}
return null;
}
}
package com.yeejoin.amos.boot.module.tzs.api.enums;
/**
*
* <pre>
* 电梯是否在线枚举
* </pre>
*
* @author gwb
* @version $Id: IsOnlineEnum.java, v 0.1 2021年9月29日 上午9:08:16 gwb Exp $
*/
public enum LiftIsOnlineEnum{
OFF(0,"离线"),
ON(1,"在线");
/**
* 编码
*/
private Integer code;
/**
* 名称
*/
private String name;
// 构造方法
private LiftIsOnlineEnum(Integer code, String name) {
this.code = code;
this.name = name;
}
public Integer getCode() {
return code;
}
public String getName()
{
return name;
}
public static LiftIsOnlineEnum getEnum(Integer code)
{
for (LiftIsOnlineEnum liftIsOnlineEnum : LiftIsOnlineEnum.values())
{
if (liftIsOnlineEnum.getCode().equals(code))
{
return liftIsOnlineEnum;
}
}
return null;
}
}
package com.yeejoin.amos.boot.module.tzs.api.enums;
/**
*
* <pre>
* 电梯轿厢是否在门区
* </pre>
*
* @author gwb
* @version $Id: LiftIszoneEnum.java, v 0.1 2021年9月29日 上午9:35:27 gwb Exp $
*/
public enum LiftIszoneEnum{
NON_DOOR_AREA(0,"轿厢在非门区"),
DOOR_AREA (1,"轿厢在门区");
/**
* 编码
*/
private Integer code;
/**
* 名称
*/
private String name;
// 构造方法
private LiftIszoneEnum(Integer code, String name) {
this.code = code;
this.name = name;
}
public Integer getCode() {
return code;
}
public String getName()
{
return name;
}
public static LiftIszoneEnum getEnum(Integer code)
{
for (LiftIszoneEnum liftIszoneEnum : LiftIszoneEnum.values())
{
if (liftIszoneEnum.getCode().equals(code))
{
return liftIszoneEnum;
}
}
return null;
}
}
package com.yeejoin.amos.boot.module.tzs.api.enums;
/**
*
* <pre>
* 电梯运行模式枚举
* </pre>
*
* @author gwb
* @version $Id: LiftServiceModelEnum.java, v 0.1 2021年9月29日 上午9:24:15 gwb Exp $
*/
public enum LiftServiceModelEnum{
STOP_SERVICE(1,"停止服务"),
NORMAL_OPERATION(2,"正常运行"),
OVERHAUL(3,"检修"),
FIRE_RETURN(4,"消防返回"),
FIREFIGHTER_OPERATION(5,"消防员运行"),
EMERGENCY_POWER_OPERATION(6,"应急电源运行"),
SEISMIC_MODEL(7,"地震模式"),
UNKNOWN (8,"未知");
/**
* 编码
*/
private Integer code;
/**
* 名称
*/
private String name;
// 构造方法
private LiftServiceModelEnum(Integer code, String name) {
this.code = code;
this.name = name;
}
public Integer getCode() {
return code;
}
public String getName()
{
return name;
}
public static LiftServiceModelEnum getEnum(Integer code)
{
for (LiftServiceModelEnum liftCircuitStatusEnum : LiftServiceModelEnum.values())
{
if (liftCircuitStatusEnum.getCode().equals(code))
{
return liftCircuitStatusEnum;
}
}
return null;
}
}
package com.yeejoin.amos.boot.module.tzs.api.enums;
/**
*
* <pre>
* 电梯运行状态枚举
* </pre>
*
* @author gwb
* @version $Id: LiftStatusEnum.java, v 0.1 2021年9月29日 上午9:32:16 gwb Exp $
*/
public enum LiftStatusEnum{
STOP (1,"停止"),
RUN (2,"运行");
/**
* 编码
*/
private Integer code;
/**
* 名称
*/
private String name;
// 构造方法
private LiftStatusEnum(Integer code, String name) {
this.code = code;
this.name = name;
}
public Integer getCode() {
return code;
}
public String getName()
{
return name;
}
public static LiftStatusEnum getEnum(Integer code)
{
for (LiftStatusEnum liftStatusEnum : LiftStatusEnum.values())
{
if (liftStatusEnum.getCode().equals(code))
{
return liftStatusEnum;
}
}
return null;
}
}
package com.yeejoin.amos.boot.module.tzs.api.mapper;
import com.yeejoin.amos.boot.module.tzs.api.entity.ElevatorAlarm;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
/**
* Mapper 接口
*
* @author litw
* @date 2021-09-28
*/
public interface ElevatorAlarmMapper extends BaseMapper<ElevatorAlarm> {
}
package com.yeejoin.amos.boot.module.tzs.api.mapper; package com.yeejoin.amos.boot.module.tzs.api.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.yeejoin.amos.boot.module.tzs.api.dto.ElevatorWlInfoDto;
import com.yeejoin.amos.boot.module.tzs.api.entity.Elevator; import com.yeejoin.amos.boot.module.tzs.api.entity.Elevator;
import java.util.List;
/** /**
* Mapper 接口 * Mapper 接口
* *
...@@ -11,4 +14,21 @@ import com.yeejoin.amos.boot.module.tzs.api.entity.Elevator; ...@@ -11,4 +14,21 @@ import com.yeejoin.amos.boot.module.tzs.api.entity.Elevator;
*/ */
public interface ElevatorMapper extends BaseMapper<Elevator> { public interface ElevatorMapper extends BaseMapper<Elevator> {
List<ElevatorWlInfoDto> queryElevatorList(String address,
String registerCode,
Integer rescueCode,
String type,
Integer dealStatus,
Long sequenceNbr,
int current, int size);
List<ElevatorWlInfoDto> queryElevatorListDetails(String address,
String registerCode,
Integer rescueCode,
String type,
Integer dealStatus,
Long sequenceNbr
);
int queryElevatorListCount();
} }
package com.yeejoin.amos.boot.module.tzs.api.mapper;
import com.yeejoin.amos.boot.module.tzs.api.entity.ElevatorStatus;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
/**
* Mapper 接口
*
* @author litw
* @date 2021-09-28
*/
public interface ElevatorStatusMapper extends BaseMapper<ElevatorStatus> {
}
package com.yeejoin.amos.boot.module.tzs.api.service;
/**
* 接口类
*
* @author litw
* @date 2021-09-28
*/
public interface IElevatorAlarmService {
}
package com.yeejoin.amos.boot.module.tzs.api.service;
/**
* 接口类
*
* @author litw
* @date 2021-09-28
*/
public interface IElevatorStatusService {
}
...@@ -387,7 +387,7 @@ ...@@ -387,7 +387,7 @@
AND te.region_code like CONCAT(CONCAT('%',#{regionCode}),'%') AND te.region_code like CONCAT(CONCAT('%',#{regionCode}),'%')
</if> </if>
<if test="rescueTotal != null and rescueTotal != ''"> <if test="rescueTotal != null and rescueTotal != ''">
AND tzs.alert_stage_code in ('861','862') AND tzs.alert_stage_code in ('860','861','862')
</if> </if>
<if test="rescueComplete != null and rescueComplete != ''"> <if test="rescueComplete != null and rescueComplete != ''">
AND tzs.alert_stage_code in ('864','865','866') AND tzs.alert_stage_code in ('864','865','866')
...@@ -420,7 +420,7 @@ ...@@ -420,7 +420,7 @@
AND te.region_code like CONCAT(CONCAT('%',#{regionCode}),'%') AND te.region_code like CONCAT(CONCAT('%',#{regionCode}),'%')
</if> </if>
<if test="rescueTotal != null and rescueTotal != ''"> <if test="rescueTotal != null and rescueTotal != ''">
AND tzs.alert_stage_code in ('861','862') AND tzs.alert_stage_code in ('860','861','862')
</if> </if>
<if test="rescueComplete != null and rescueComplete != ''"> <if test="rescueComplete != null and rescueComplete != ''">
AND tzs.alert_stage_code in ('864','865','866') AND tzs.alert_stage_code in ('864','865','866')
......
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.yeejoin.amos.boot.module.tzs.api.mapper.ElevatorAlarmMapper">
</mapper>
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.yeejoin.amos.boot.module.tzs.api.mapper.ElevatorMapper"> <mapper namespace="com.yeejoin.amos.boot.module.tzs.api.mapper.ElevatorMapper">
<select id="queryElevatorList" resultType="com.yeejoin.amos.boot.module.tzs.api.dto.ElevatorWlInfoDto">
select
te.sequence_nbr sequenceNbr,
concat(te.province,te.city,te.district) area,
te.category,
te.register_code registerCode,
te.rescue_code rescueCode,
te.address ,
tea.start_date happenTime,
tea.type ,
case tea.deal_status
when '0' then '处置完成'
when '1' then '故障发生'
when '2' then '发出通知'
when '3' then '处置响应'
when '4' then '处置到场'
when '5' then '误报'
ELSE '' END dealStatus,
'电梯' categoryName,
'立信远大科技有限公司' IotServiceProvider
from tcb_elevator te inner join tz_elevator_alarm tea on
te.register_code = tea.register_code
where 1=1
<if test="address != null and address != ''">
and te.address like CONCAT(CONCAT('%',#{address}),'%')
</if>
<if test="registerCode != null and registerCode != ''">
and te.register_code like CONCAT(CONCAT('%',#{registerCode}),'%')
</if>
<if test="rescueCode != null and rescueCode != ''">
and te.rescue_code like CONCAT(CONCAT('%',#{rescueCode}),'%')
</if>
<if test="type != null and type != ''">
and tec.type = #{type}
</if>
<if test="dealStatus != null and dealStatus != ''">sequenceNbr
and tec.deal_status = #{dealStatus}
</if>
<if test="sequenceNbr != null and sequenceNbr != ''">
and te.sequence_nbr = #{sequenceNbr}
</if>
order by start_date DESC limit #{current},#{size}
</select>
<select id="queryElevatorListDetails" resultType="com.yeejoin.amos.boot.module.tzs.api.dto.ElevatorWlInfoDto">
select
te.sequence_nbr sequenceNbr,
concat(te.province,te.city,te.district) area,
te.category,
te.register_code registerCode,
te.rescue_code rescueCode,
te.address ,
tea.start_date happenTime,
tea.type ,
case tea.deal_status
when '0' then '处置完成'
when '1' then '故障发生'
when '2' then '发出通知'
when '3' then '处置响应'
when '4' then '处置到场'
when '5' then '误报'
ELSE '' END dealStatus,
'电梯' categoryName,
'立信远大科技有限公司' IotServiceProvider
from tcb_elevator te inner join tz_elevator_alarm tea on
te.register_code = tea.register_code
where 1=1
<if test="sequenceNbr != null and sequenceNbr != ''">
and te.sequence_nbr = #{sequenceNbr}
</if>
</select>
<select id="queryElevatorListCount" resultType="int">
select count(1) from (
select
te.sequence_nbr
from tcb_elevator te inner join tz_elevator_alarm tea on
te.register_code = tea.register_code
where 1=1
) te
</select>
</mapper> </mapper>
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.yeejoin.amos.boot.module.tzs.api.mapper.ElevatorStatusMapper">
</mapper>
...@@ -3,6 +3,7 @@ package com.yeejoin.amos.boot.module.command.biz.controller; ...@@ -3,6 +3,7 @@ package com.yeejoin.amos.boot.module.command.biz.controller;
import com.alibaba.fastjson.JSON; import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONArray; import com.alibaba.fastjson.JSONArray;
import com.alibaba.fastjson.JSONObject; import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.metadata.OrderItem; import com.baomidou.mybatisplus.core.metadata.OrderItem;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
...@@ -15,24 +16,7 @@ import com.yeejoin.amos.boot.biz.common.utils.WordConverterUtils; ...@@ -15,24 +16,7 @@ import com.yeejoin.amos.boot.biz.common.utils.WordConverterUtils;
import com.yeejoin.amos.boot.module.command.api.dao.SeismometeorologyDtoDao; import com.yeejoin.amos.boot.module.command.api.dao.SeismometeorologyDtoDao;
import com.yeejoin.amos.boot.module.command.api.dto.SeismometeorologyDto; import com.yeejoin.amos.boot.module.command.api.dto.SeismometeorologyDto;
import com.yeejoin.amos.boot.module.command.biz.service.impl.RemoteSecurityService; import com.yeejoin.amos.boot.module.command.biz.service.impl.RemoteSecurityService;
import com.yeejoin.amos.boot.module.common.api.dto.AttachmentDto; import com.yeejoin.amos.boot.module.common.api.dto.*;
import com.yeejoin.amos.boot.module.common.api.dto.CompanyDto;
import com.yeejoin.amos.boot.module.common.api.dto.FireChemicalDto;
import com.yeejoin.amos.boot.module.common.api.dto.FireExpertsDto;
import com.yeejoin.amos.boot.module.common.api.dto.FireStationDto;
import com.yeejoin.amos.boot.module.common.api.dto.FireStationzhDto;
import com.yeejoin.amos.boot.module.common.api.dto.FireTeamZhDto;
import com.yeejoin.amos.boot.module.common.api.dto.FirefightersDto;
import com.yeejoin.amos.boot.module.common.api.dto.FirefightersZhDto;
import com.yeejoin.amos.boot.module.common.api.dto.KeySiteDto;
import com.yeejoin.amos.boot.module.common.api.dto.LinkageUnitDto;
import com.yeejoin.amos.boot.module.common.api.dto.LinkageUnitZhDto;
import com.yeejoin.amos.boot.module.common.api.dto.OrgMenuDto;
import com.yeejoin.amos.boot.module.common.api.dto.OrgUsrFormDto;
import com.yeejoin.amos.boot.module.common.api.dto.OrgUsrzhDto;
import com.yeejoin.amos.boot.module.common.api.dto.OrgusrDataxDto;
import com.yeejoin.amos.boot.module.common.api.dto.RequestData;
import com.yeejoin.amos.boot.module.common.api.dto.WaterResourceZhDto;
import com.yeejoin.amos.boot.module.common.api.entity.FireTeam; import com.yeejoin.amos.boot.module.common.api.entity.FireTeam;
import com.yeejoin.amos.boot.module.common.api.feign.EquipFeignClient; import com.yeejoin.amos.boot.module.common.api.feign.EquipFeignClient;
import com.yeejoin.amos.boot.module.common.api.feign.IotFeignClient; import com.yeejoin.amos.boot.module.common.api.feign.IotFeignClient;
...@@ -90,6 +74,7 @@ import java.io.File; ...@@ -90,6 +74,7 @@ import java.io.File;
import java.io.FileInputStream; import java.io.FileInputStream;
import java.lang.reflect.Method; import java.lang.reflect.Method;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.HashMap;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
...@@ -132,7 +117,8 @@ public class CommandController extends BaseController { ...@@ -132,7 +117,8 @@ public class CommandController extends BaseController {
@Autowired @Autowired
IFirefightersService firefightersService; IFirefightersService firefightersService;
@Autowired
private IAlertFormValueService iAlertFormValueService;
@Autowired @Autowired
private IAircraftService aircraftService; private IAircraftService aircraftService;
@Autowired @Autowired
...@@ -150,7 +136,6 @@ public class CommandController extends BaseController { ...@@ -150,7 +136,6 @@ public class CommandController extends BaseController {
IKeySiteService keySiteService; IKeySiteService keySiteService;
@Autowired @Autowired
IPowerTransferCompanyService powerTransferCompanyService; IPowerTransferCompanyService powerTransferCompanyService;
@Autowired @Autowired
ISourceFileService sourceFileService; ISourceFileService sourceFileService;
...@@ -1003,14 +988,41 @@ public class CommandController extends BaseController { ...@@ -1003,14 +988,41 @@ public class CommandController extends BaseController {
AlertCalled AlertCalled=iAlertCalledService.getAlertCalledById(id); AlertCalled AlertCalled=iAlertCalledService.getAlertCalledById(id);
Long buildId=null; Long buildId=null;
String buildIdName="";
Long zdid=null;
String zdname="";
OrgusrDataxDto orgusrDataxDto=new OrgusrDataxDto(); OrgusrDataxDto orgusrDataxDto=new OrgusrDataxDto();
if(AlertCalled.getUnitInvolved()!=null&&!"".equals(AlertCalled.getUnitInvolved())) { if(AlertCalled.getUnitInvolved()!=null&&!"".equals(AlertCalled.getUnitInvolved())) {
List<OrgUsrzhDto> orgUsrzhDto= iOrgUsrService.getOrgUsrzhDto( AlertCalled.getUnitInvolved()); List<OrgUsrzhDto> orgUsrzhDto= iOrgUsrService.getOrgUsrzhDto( AlertCalled.getUnitInvolved());
if(orgUsrzhDto!=null&&orgUsrzhDto.size()>0&&orgUsrzhDto.get(0)!=null){ if(orgUsrzhDto!=null&&orgUsrzhDto.size()>0&&orgUsrzhDto.get(0)!=null){
buildId=orgUsrzhDto.get(0).getBuildId()==null?null:Long.valueOf(orgUsrzhDto.get(0).getBuildId()); buildId=orgUsrzhDto.get(0).getBuildId()==null?null:Long.valueOf(orgUsrzhDto.get(0).getBuildId());
buildIdName=orgUsrzhDto.get(0).getBuildId()==null?null:orgUsrzhDto.get(0).getBuildName();
}
}
// 警情动态表单数据
List<KeyValueLabel> listdate = new ArrayList<>();
List<AlertFormValue> list = buildId==null?null:iAlertFormValueService.getzqlist(id);
if (list != null && list.size() > 0) {
for (AlertFormValue alertFormValue : list) {
if("keySiteExcle".equals(alertFormValue.getFieldCode())&&alertFormValue.getFieldValue()!=null){
List<OrgMenuDto> list1 = new ArrayList<OrgMenuDto>();
List<OrgMenuDto> children = new ArrayList<OrgMenuDto>();
OrgMenuDto date= new OrgMenuDto( Long.valueOf(alertFormValue.getFieldValueCode()), Long.valueOf(alertFormValue.getFieldValueCode()), alertFormValue.getFieldValue(), alertFormValue.getFieldValue(),null);
children.add(date);
OrgMenuDto orgMenuDto =new OrgMenuDto();
orgMenuDto.setKey(buildId);
orgMenuDto.setValue(buildId);
orgMenuDto.setChildren(children);
orgMenuDto.setName(buildIdName);
orgMenuDto.setTitle(buildIdName);
list1.add(orgMenuDto);
return ResponseHelper.buildResponse(list1);
}
} }
} }
return ResponseHelper.buildResponse(buildId==null?null:keySiteService.getBuildAndKeyTree(buildId)); return ResponseHelper.buildResponse(buildId==null?null:keySiteService.getBuildAndKeyTree(buildId));
} }
......
...@@ -61,7 +61,7 @@ import java.util.stream.Collectors; ...@@ -61,7 +61,7 @@ import java.util.stream.Collectors;
* @date 2021-06-29 * @date 2021-06-29
*/ */
@RestController @RestController
@Api(tags = "消防水源Api") @Api(tags = "stationApi")
@RequestMapping(value = "/water-resource") @RequestMapping(value = "/water-resource")
public class WaterResourceController extends BaseController { public class WaterResourceController extends BaseController {
......
...@@ -414,6 +414,9 @@ public class OrgUsrServiceImpl extends BaseService<OrgUsrDto, OrgUsr, OrgUsrMapp ...@@ -414,6 +414,9 @@ public class OrgUsrServiceImpl extends BaseService<OrgUsrDto, OrgUsr, OrgUsrMapp
return formValue; return formValue;
} }
@Override @Override
public void saveOrgUsr(OrgUsr orgUsr, OrgUsr oriOrgUsr) throws Exception { public void saveOrgUsr(OrgUsr orgUsr, OrgUsr oriOrgUsr) throws Exception {
...@@ -649,24 +652,31 @@ public class OrgUsrServiceImpl extends BaseService<OrgUsrDto, OrgUsr, OrgUsrMapp ...@@ -649,24 +652,31 @@ public class OrgUsrServiceImpl extends BaseService<OrgUsrDto, OrgUsr, OrgUsrMapp
OrgUsr orgUsr = new OrgUsr(); OrgUsr orgUsr = new OrgUsr();
OrgUsr oriOrgUsr = getById(id); OrgUsr oriOrgUsr = getById(id);
BeanUtils.copyProperties(OrgUsrVo, orgUsr); BeanUtils.copyProperties(OrgUsrVo, orgUsr);
/*单位编辑后 code值也应做出修改 2021-09-09 陈召 开始 */ //判断是否修改所属单位
OrgUsr parent = getById(OrgUsrVo.getParentId()); if(!(oriOrgUsr.getParentId()!=null?oriOrgUsr.getParentId():"").equals(OrgUsrVo.getParentId())){
if (parent != null) {
orgUsr.setBizOrgCode(parent.getBizOrgCode() + getOrgCodeStr()); /*单位编辑后 code值也应做出修改 2021-09-09 陈召 开始 */
} OrgUsr parent = getById(OrgUsrVo.getParentId());
orgUsr.setSequenceNbr(id); if (parent != null) {
// 查询机构下的所有部门单位人员数据,进行bizOrgCode的统一修改 BUG 2880 by litw start 2021年9月16日 orgUsr.setBizOrgCode(parent.getBizOrgCode() + getOrgCodeStr());
String oriOrgCode = oriOrgUsr.getBizOrgCode(); }
Map<String, Object> columnMap = new HashMap<>(); // orgUsr.setSequenceNbr(id);
columnMap.put("bizOrgCode", oriOrgCode); // 查询机构下的所有部门单位人员数据,进行bizOrgCode的统一修改 BUG 2880 by litw start 2021年9月16日
List<OrgUsr> list = orgUsrMapper.selectAllChildrenList(columnMap); // String oriOrgCode = oriOrgUsr.getBizOrgCode();
list.stream().forEach(e -> { // Map<String, Object> columnMap = new HashMap<>();
e.setBizOrgCode(e.getBizOrgCode().replace(oriOrgCode, orgUsr.getBizOrgCode())); // columnMap.put("bizOrgCode", oriOrgCode);
}); // List<OrgUsr> list = orgUsrMapper.selectAllChildrenList(columnMap);
this.updateBatchById(list); // list.stream().forEach(e -> {
// e.setBizOrgCode(e.getBizOrgCode().replace(oriOrgCode, orgUsr.getBizOrgCode()));
// });
// this.updateBatchById(list);
// /*单位编辑后 code值也应做出修改 2021-09-09 陈召 结束 */
orgUsrMapper.updatelistByParentId(orgUsr.getBizOrgCode(),oriOrgUsr.getBizOrgCode());
}
updateById(orgUsr);
// saveOrgUsr(orgUsr, oriOrgUsr);
/*单位编辑后 code值也应做出修改 2021-09-09 陈召 结束 */
saveOrgUsr(orgUsr, oriOrgUsr);
// 保存动态表单数据 // 保存动态表单数据
updateDynamicFormInstance(orgUsr.getSequenceNbr(), OrgUsrVo.getDynamicFormValue()); updateDynamicFormInstance(orgUsr.getSequenceNbr(), OrgUsrVo.getDynamicFormValue());
/** /**
...@@ -707,11 +717,12 @@ public class OrgUsrServiceImpl extends BaseService<OrgUsrDto, OrgUsr, OrgUsrMapp ...@@ -707,11 +717,12 @@ public class OrgUsrServiceImpl extends BaseService<OrgUsrDto, OrgUsr, OrgUsrMapp
// 动态表单数据 // 动态表单数据
List<FormValue> formValue = getFormValue(id); List<FormValue> formValue = getFormValue(id);
//bug 2580 返回值改为具体名称 chenzhao 2021-09-27 start //bug 2580 返回值改为具体名称 chenzhao 2021-09-27 start
for (FormValue value : formValue) { //bug 2797 前端要求先改回code值。
/* for (FormValue value : formValue) {
if (value.getValueName() != null && !value.getValueName() .equals(" ")){ if (value.getValueName() != null && !value.getValueName() .equals(" ")){
value.setValue(value.getValueName()); value.setValue(value.getValueName());
} }
} }*/
//bug 2580 返回值改为具体名称 chenzhao 2021-09-27 end //bug 2580 返回值改为具体名称 chenzhao 2021-09-27 end
OrgUsrFormDto orgUsrFormVo = new OrgUsrFormDto(); OrgUsrFormDto orgUsrFormVo = new OrgUsrFormDto();
orgUsrFormVo.setDynamicFormAlert(formValue); orgUsrFormVo.setDynamicFormAlert(formValue);
......
package com.yeejoin.amos.boot.module.jcs.biz.controller; package com.yeejoin.amos.boot.module.jcs.biz.controller;
import java.util.Map; import com.yeejoin.amos.boot.biz.common.controller.BaseController;
import com.yeejoin.amos.boot.module.common.api.dto.ExcelDto;
import javax.servlet.http.HttpServletResponse; import com.yeejoin.amos.boot.module.jcs.api.enums.ExcelEnums;
import com.yeejoin.amos.boot.module.jcs.biz.service.impl.DataSourcesImpl;
import com.yeejoin.amos.boot.module.jcs.biz.service.impl.ExcelServiceImpl;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.PathVariable;
...@@ -19,14 +22,8 @@ import org.typroject.tyboot.core.restful.exception.instance.BadRequest; ...@@ -19,14 +22,8 @@ import org.typroject.tyboot.core.restful.exception.instance.BadRequest;
import org.typroject.tyboot.core.restful.utils.ResponseHelper; import org.typroject.tyboot.core.restful.utils.ResponseHelper;
import org.typroject.tyboot.core.restful.utils.ResponseModel; import org.typroject.tyboot.core.restful.utils.ResponseModel;
import com.yeejoin.amos.boot.biz.common.controller.BaseController; import javax.servlet.http.HttpServletResponse;
import com.yeejoin.amos.boot.module.common.api.dto.ExcelDto; import java.util.Map;
import com.yeejoin.amos.boot.module.jcs.api.enums.ExcelEnums;
import com.yeejoin.amos.boot.module.jcs.biz.service.impl.DataSourcesImpl;
import com.yeejoin.amos.boot.module.jcs.biz.service.impl.ExcelServiceImpl;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
/** /**
* 导出导入 * 导出导入
...@@ -188,9 +185,9 @@ public class ExcelController extends BaseController { ...@@ -188,9 +185,9 @@ public class ExcelController extends BaseController {
@TycloudOperation(needAuth = false, ApiLevel = UserType.AGENCY) @TycloudOperation(needAuth = false, ApiLevel = UserType.AGENCY)
@ApiOperation(value = "导出给提供设备接口") @ApiOperation(value = "导出给提供设备接口")
@PostMapping("/exportForEquipment") @GetMapping(value = "/exportForEquipment")
public ResponseModel<String[]> getFireStationFileByParams(@RequestParam(value = "type") String type, public ResponseModel<String[]> getFireStationFileByParams( String type,
@RequestParam(value = "method") String method) { String method) {
try { try {
return ResponseHelper.buildResponse(dataSources.selectList(type,method)); return ResponseHelper.buildResponse(dataSources.selectList(type,method));
} catch (Exception e) { } catch (Exception e) {
......
...@@ -118,6 +118,7 @@ public class FirestationJacketController extends BaseController { ...@@ -118,6 +118,7 @@ public class FirestationJacketController extends BaseController {
QueryWrapper<FirestationJacket> queryWrapper = new QueryWrapper<>(); QueryWrapper<FirestationJacket> queryWrapper = new QueryWrapper<>();
queryWrapper.eq("firefighters_id", sequenceNbr); queryWrapper.eq("firefighters_id", sequenceNbr);
queryWrapper.eq("is_delete", 0);
FirestationJacket firestationJacket = iFirestationJacketService.getOne(queryWrapper); FirestationJacket firestationJacket = iFirestationJacketService.getOne(queryWrapper);
if(firestationJacket!=null){ if(firestationJacket!=null){
......
...@@ -159,6 +159,9 @@ public class DataSourcesImpl implements DataSources { ...@@ -159,6 +159,9 @@ public class DataSourcesImpl implements DataSources {
case "getEquipCategory": case "getEquipCategory":
str =getEquipCategory(); str =getEquipCategory();
break; break;
case "getEquipDefinition":
str =getEquipDefinition();
break;
} }
} }
return str; return str;
...@@ -424,4 +427,23 @@ public class DataSourcesImpl implements DataSources { ...@@ -424,4 +427,23 @@ public class DataSourcesImpl implements DataSources {
} }
private String[] getEquipDefinition() {
String type = "9306";
ResponseModel<List<LinkedHashMap<String, Object>>> response = equipFeignClient.listLikePage(type);
List<LinkedHashMap<String, Object>> categoryList = response.getResult();
String[] str = null;
List<String> resultList = Lists.newArrayList();
if(categoryList!=null&&categoryList.size()>0){
categoryList.forEach(t -> {
resultList.add(t.get("name") + "@" + t.get("id")+ "@" +t.get("categoryId")+ "@" +t.get("unitName"));
});
str = resultList.toArray(new String[resultList.size()]);
}
return str;
}
} }
...@@ -831,6 +831,15 @@ if (excelDtoList != null && excelDtoList.size() > 0) { ...@@ -831,6 +831,15 @@ if (excelDtoList != null && excelDtoList.size() > 0) {
item.setEquipCategoryName(equipCategory[0]); item.setEquipCategoryName(equipCategory[0]);
item.setEquipCategoryId(Long.parseLong(equipCategory[1])); item.setEquipCategoryId(Long.parseLong(equipCategory[1]));
} }
if (item.getEquipName() != null) {
String[] equipCategory = item.getEquipName().split("@");
item.setEquipId(Long.parseLong(equipCategory[1]));
item.setEquipName(equipCategory[0]);
item.setEquipCategoryId(Long.parseLong(equipCategory[2]));
item.setEquipCategoryName(equipCategory[3]);
}
item = Bean.toPo(getCurrentInfo(), item); item = Bean.toPo(getCurrentInfo(), item);
waterResourceServiceImpl.importByExcel(item); waterResourceServiceImpl.importByExcel(item);
}); });
...@@ -1054,6 +1063,10 @@ if (excelDtoList != null && excelDtoList.size() > 0) { ...@@ -1054,6 +1063,10 @@ if (excelDtoList != null && excelDtoList.size() > 0) {
} else if (ExcelEnums.RYZB.getType().equals(excelDto.getType())) { } else if (ExcelEnums.RYZB.getType().equals(excelDto.getType())) {
data = initDutyPersonTemplate(ids); data = initDutyPersonTemplate(ids);
} }
//代码报错暂时注释掉
// else if(ExcelEnums.WXXFZB.getType().equals(excelDto.getType())){
// data = initDutyDutyFireFightingTemplate(ids);
// }
// 获取日期 // 获取日期
List<Map<String, Object>> rangeDate = dutyPersonShiftService.getBaseMapper().genRangeDate(beginDate, endDate); List<Map<String, Object>> rangeDate = dutyPersonShiftService.getBaseMapper().genRangeDate(beginDate, endDate);
List<String> dayByMonth = new ArrayList<>(); List<String> dayByMonth = new ArrayList<>();
...@@ -1061,6 +1074,29 @@ if (excelDtoList != null && excelDtoList.size() > 0) { ...@@ -1061,6 +1074,29 @@ if (excelDtoList != null && excelDtoList.size() > 0) {
exportDutyTemplate(response, excelDto.getClassUrl(), dayByMonth, excelDto, data, true); exportDutyTemplate(response, excelDto.getClassUrl(), dayByMonth, excelDto, data, true);
} }
private List<List<Object>> initDutyDutyFireFightingTemplate(String ids) {
List<List<Object>> data = new ArrayList<>();
// 根据id列表获取单位下的微型消防站集合
List<String> companyIdList = Lists.newArrayList();
if (!ValidationUtil.isEmpty(ids)) {
companyIdList = Lists.newArrayList(ids.split(","));
}
List<FirefightersDto> firefightersDtoList = fireTeamService.getFighterByTeamId(companyIdList);
if (!firefightersDtoList.isEmpty()) {
AtomicInteger row = new AtomicInteger(1);
firefightersDtoList.forEach(o -> {
ArrayList<Object> list = new ArrayList<>();
list.add(row.getAndIncrement());
list.add(o.getFireTeamName() + "@" + o.getFireTeamId());
list.add(o.getName() + "@" + o.getSequenceNbr());
list.add(o.getJobTitle() + "@" + o.getJobTitleCode());
data.add(list);
});
}
return data;
}
public void dutyInfoExport(HttpServletResponse response, String beginDate, String endDate, ExcelDto excelDto) public void dutyInfoExport(HttpServletResponse response, String beginDate, String endDate, ExcelDto excelDto)
throws ParseException { throws ParseException {
// 获取日期 // 获取日期
......
...@@ -87,7 +87,7 @@ public class HiddenDangerController extends AbstractBaseController { ...@@ -87,7 +87,7 @@ public class HiddenDangerController extends AbstractBaseController {
@RequestParam(value = "planId") Long planId, @RequestParam(value = "planId") Long planId,
@ApiParam(value = "导入数据文件", required = true) @RequestBody MultipartFile file) { @ApiParam(value = "导入数据文件", required = true) @RequestBody MultipartFile file) {
List<HiddenDangerImportDto> list = FileHelper.importExcel(file, 0, 1, HiddenDangerImportDto.class); List<HiddenDangerImportDto> list = FileHelper.importExcel(file, 0, 1, HiddenDangerImportDto.class);
iHiddenDangerService.importDanger(getSelectedOrgInfo(),planId, list); iHiddenDangerService.importDanger(getSelectedOrgInfo(), planId, list);
return ResponseHelper.buildResponse("导入成功"); return ResponseHelper.buildResponse("导入成功");
} }
...@@ -106,7 +106,7 @@ public class HiddenDangerController extends AbstractBaseController { ...@@ -106,7 +106,7 @@ public class HiddenDangerController extends AbstractBaseController {
@TycloudOperation(ApiLevel = UserType.AGENCY) @TycloudOperation(ApiLevel = UserType.AGENCY)
@ApiOperation(value = "隐患删除") @ApiOperation(value = "隐患删除")
@DeleteMapping("{latentDangerIds}") @DeleteMapping("{latentDangerIds}")
public ResponseModel deleteByIds(@ApiParam(value = "隐患ids,隐患模块主键")@PathVariable String latentDangerIds){ public ResponseModel deleteByIds(@ApiParam(value = "隐患ids,隐患模块主键") @PathVariable String latentDangerIds) {
List<Long> ids = Arrays.stream(latentDangerIds.split(",")).mapToLong(Long::parseLong).boxed().collect(Collectors.toList()); List<Long> ids = Arrays.stream(latentDangerIds.split(",")).mapToLong(Long::parseLong).boxed().collect(Collectors.toList());
Boolean b = iHiddenDangerService.deleteBatch(ids); Boolean b = iHiddenDangerService.deleteBatch(ids);
return ResponseHelper.buildResponse(b); return ResponseHelper.buildResponse(b);
......
...@@ -33,7 +33,7 @@ public class PlanAuditController extends AbstractBaseController { ...@@ -33,7 +33,7 @@ public class PlanAuditController extends AbstractBaseController {
public ResponseModel auditWorkFlow( public ResponseModel auditWorkFlow(
@ApiParam(value = "工作流流水实例", required = true) @RequestBody PlanAuditLog planAuditLog, @ApiParam(value = "工作流流水实例", required = true) @RequestBody PlanAuditLog planAuditLog,
@ApiParam(value = "当前计划状态", required = true) @RequestParam Integer status, @ApiParam(value = "当前计划状态", required = true) @RequestParam Integer status,
@ApiParam(value = "执行控制条件", required = true) @RequestParam String condition) { @ApiParam(value = "执行控制条件", required = true) @RequestParam String condition) throws Exception {
ReginParams reginParams = getSelectedOrgInfo(); ReginParams reginParams = getSelectedOrgInfo();
return ResponseHelper.buildResponse(planAuditService.auditWorkFlow(planAuditLog, status, condition, reginParams)); return ResponseHelper.buildResponse(planAuditService.auditWorkFlow(planAuditLog, status, condition, reginParams));
} }
......
...@@ -9,6 +9,7 @@ import com.yeejoin.amos.supervision.common.enums.DangerCheckTypeLevelEnum; ...@@ -9,6 +9,7 @@ import com.yeejoin.amos.supervision.common.enums.DangerCheckTypeLevelEnum;
import com.yeejoin.amos.supervision.common.enums.PlanStatusEnum; import com.yeejoin.amos.supervision.common.enums.PlanStatusEnum;
import com.yeejoin.amos.supervision.core.common.request.AddPlanRequest; import com.yeejoin.amos.supervision.core.common.request.AddPlanRequest;
import com.yeejoin.amos.supervision.core.common.response.PlanPointRespone; import com.yeejoin.amos.supervision.core.common.response.PlanPointRespone;
import com.yeejoin.amos.supervision.core.framework.PersonIdentify;
import org.slf4j.Logger; import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
...@@ -88,6 +89,7 @@ public class PlanController extends AbstractBaseController { ...@@ -88,6 +89,7 @@ public class PlanController extends AbstractBaseController {
* @return * @return
*/ */
@TycloudOperation(ApiLevel = UserType.AGENCY) @TycloudOperation(ApiLevel = UserType.AGENCY)
@PersonIdentify
@ApiOperation(value = "巡检计划新增及编辑", notes = "巡检计划新增及编辑") @ApiOperation(value = "巡检计划新增及编辑", notes = "巡检计划新增及编辑")
@RequestMapping(value = "/addPlan", produces = "application/json;charset=UTF-8", method = RequestMethod.POST) @RequestMapping(value = "/addPlan", produces = "application/json;charset=UTF-8", method = RequestMethod.POST)
public CommonResponse checkPlanAdd(@ApiParam(value = "巡检计划", required = true) @RequestBody AddPlanRequest param) { public CommonResponse checkPlanAdd(@ApiParam(value = "巡检计划", required = true) @RequestBody AddPlanRequest param) {
......
...@@ -89,15 +89,14 @@ public class RoutePointItemController extends AbstractBaseController { ...@@ -89,15 +89,14 @@ public class RoutePointItemController extends AbstractBaseController {
/** /**
* 删除巡检路线点项关系 * 删除巡检路线点项关系
* *
* @param ids
* @return CommonResponse * @return CommonResponse
*/ */
@TycloudOperation(ApiLevel = UserType.AGENCY) @TycloudOperation(ApiLevel = UserType.AGENCY)
@ApiOperation(value = "删除巡检路线点项关系", notes = "删除巡检路线点项关系") @ApiOperation(value = "删除巡检路线点项关系", notes = "删除巡检路线点项关系")
@PostMapping(value = "/deleteByIdIn", produces = "application/json;charset=UTF-8") @PostMapping(value = "/deleteByIdIn", produces = "application/json;charset=UTF-8")
public CommonResponse deleteByIdIn(@ApiParam(value = "ids", required = true) @RequestParam List<Long> ids) { public CommonResponse deleteByIdIn(@ApiParam(value = "ids", required = true) @RequestParam List<String> itemIds, @RequestParam Long planId) {
try { try {
routePointItemService.deleteByIdIn(ids); routePointItemService.deleteByIdIn(itemIds, planId);
return CommonResponseUtil.success(); return CommonResponseUtil.success();
} catch (Exception e) { } catch (Exception e) {
log.error(e.getMessage(), e); log.error(e.getMessage(), e);
......
...@@ -11,4 +11,10 @@ public interface PlanTaskDetailMapper extends BaseMapper { ...@@ -11,4 +11,10 @@ public interface PlanTaskDetailMapper extends BaseMapper {
Map findPlanTaskByTaskIdAndPointId(@Param(value="planTaskId") long planTaskId,@Param(value="pointId") long pointId); Map findPlanTaskByTaskIdAndPointId(@Param(value="planTaskId") long planTaskId,@Param(value="pointId") long pointId);
int findPlanTaskDetailByTaskId( @Param(value="planTaskId") long planTaskId); int findPlanTaskDetailByTaskId( @Param(value="planTaskId") long planTaskId);
/**
* 更新隐患信息
* @param planTaskDetailId 主键id
*/
void updateDanger(@Param(value="planTaskDetailId") long planTaskDetailId);
} }
...@@ -26,6 +26,11 @@ public interface IRoutePointItemDao extends BaseDao<RoutePointItem, Long> { ...@@ -26,6 +26,11 @@ public interface IRoutePointItemDao extends BaseDao<RoutePointItem, Long> {
@Modifying @Modifying
@Transactional @Transactional
@Query(value = "delete from p_route_point_item WHERE input_item_id in (?1) and plan_id = (?2)", nativeQuery = true)
int deleteByRoutePointItemIdAndPlanId(List<String> itemIds, Long planId);
@Modifying
@Transactional
@Query(value = "delete from p_route_point_item WHERE plan_id = ?1", nativeQuery = true) @Query(value = "delete from p_route_point_item WHERE plan_id = ?1", nativeQuery = true)
void deleteByPlanId(Long planId); void deleteByPlanId(Long planId);
} }
...@@ -1427,7 +1427,7 @@ public class CheckServiceImpl implements ICheckService { ...@@ -1427,7 +1427,7 @@ public class CheckServiceImpl implements ICheckService {
List<CheckShot> checkShots = new ArrayList<>(); List<CheckShot> checkShots = new ArrayList<>();
InputItem inputItem = inputItemDao.getOne(item.getInputItemId()); InputItem inputItem = inputItemDao.getOne(item.getInputItemId());
CheckInput checkInput = new CheckInput(); CheckInput checkInput = new CheckInput();
if (!ObjectUtils.isEmpty(item.getId())) { if (!ObjectUtils.isEmpty(item.getId()) && item.getId() != 0) {
checkInput.setId(item.getId()); checkInput.setId(item.getId());
// 更新操作,将该点下所有图片删除,其余更新 // 更新操作,将该点下所有图片删除,其余更新
checkShotDao.deleteByCheckInputId(item.getId()); checkShotDao.deleteByCheckInputId(item.getId());
...@@ -1559,6 +1559,9 @@ public class CheckServiceImpl implements ICheckService { ...@@ -1559,6 +1559,9 @@ public class CheckServiceImpl implements ICheckService {
planTaskDetailMapper.finishTaskDetail(Long.parseLong(detail.get("planTaskDetailId").toString()), recordParam.getPointId(), planTaskDetailMapper.finishTaskDetail(Long.parseLong(detail.get("planTaskDetailId").toString()), recordParam.getPointId(),
recordParam.getPlanTaskId(), mtUserSeq, userName, size, planTaskStatus); recordParam.getPlanTaskId(), mtUserSeq, userName, size, planTaskStatus);
// p_plan_task_detail更新隐患个数
planTaskDetailMapper.updateDanger(Long.parseLong(detail.get("planTaskDetailId").toString()));
// 隐患入库 // 隐患入库
if (!ObjectUtils.isEmpty(allDanger)) { if (!ObjectUtils.isEmpty(allDanger)) {
saveDanger(allDanger, planTask, check, recordParam); saveDanger(allDanger, planTask, check, recordParam);
......
...@@ -2,6 +2,7 @@ package com.yeejoin.amos.supervision.business.service.impl; ...@@ -2,6 +2,7 @@ package com.yeejoin.amos.supervision.business.service.impl;
import com.alibaba.fastjson.JSON; import com.alibaba.fastjson.JSON;
import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.toolkit.ObjectUtils;
import com.baomidou.mybatisplus.core.toolkit.Sequence; import com.baomidou.mybatisplus.core.toolkit.Sequence;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.google.common.base.Joiner; import com.google.common.base.Joiner;
...@@ -251,7 +252,10 @@ public class HiddenDangerServiceImpl implements IHiddenDangerService { ...@@ -251,7 +252,10 @@ public class HiddenDangerServiceImpl implements IHiddenDangerService {
Map<String, Object> result = new HashMap<>(32); Map<String, Object> result = new HashMap<>(32);
Optional<Plan> op = iPlanDao.findById(hiddenDangerDto.getPlanId()); Optional<Plan> op = iPlanDao.findById(hiddenDangerDto.getPlanId());
Plan plan = op.orElseThrow((() -> new RuntimeException("计划不存在"))); Plan plan = op.orElseThrow((() -> new RuntimeException("计划不存在")));
Point point = iPointDao.findById(hiddenDangerDto.getPointId()).orElseThrow(() -> new RuntimeException("单位不存在")); Point point = new Point();
if (!ObjectUtils.isEmpty(hiddenDangerDto.getPointId())) {
point = iPointDao.findById(hiddenDangerDto.getPointId()).orElseThrow(() -> new RuntimeException("单位不存在"));
}
//检查级别 //检查级别
DangerCheckTypeLevelEnum dangerCheckTypeLevelEnum = DangerCheckTypeLevelEnum.getEumByCode(plan.getCheckLevel()); DangerCheckTypeLevelEnum dangerCheckTypeLevelEnum = DangerCheckTypeLevelEnum.getEumByCode(plan.getCheckLevel());
//检查类型 //检查类型
...@@ -267,6 +271,8 @@ public class HiddenDangerServiceImpl implements IHiddenDangerService { ...@@ -267,6 +271,8 @@ public class HiddenDangerServiceImpl implements IHiddenDangerService {
result.put("bizName", hiddenDangerDto.getInputItemName()); result.put("bizName", hiddenDangerDto.getInputItemName());
result.put("accompanyingUserId", plan.getLeadPeopleIds()); result.put("accompanyingUserId", plan.getLeadPeopleIds());
result.put("accompanyingUserName", plan.getLeadPeopleNames()); result.put("accompanyingUserName", plan.getLeadPeopleNames());
result.put("checkUnitId",plan.getCheckUnitId());
result.put("checkUnitName",plan.getCheckUnitName());
this.buildCheckInfo(result, hiddenDangerDto.getCheckInputId()); this.buildCheckInfo(result, hiddenDangerDto.getCheckInputId());
return result; return result;
} }
......
package com.yeejoin.amos.supervision.business.service.impl; package com.yeejoin.amos.supervision.business.service.impl;
import com.alibaba.fastjson.JSONObject;
import com.yeejoin.amos.boot.biz.common.bo.ReginParams; import com.yeejoin.amos.boot.biz.common.bo.ReginParams;
import com.yeejoin.amos.boot.biz.common.service.IWorkflowExcuteService; import com.yeejoin.amos.boot.biz.common.service.IWorkflowExcuteService;
import com.yeejoin.amos.boot.biz.common.workflow.feign.WorkflowFeignService;
import com.yeejoin.amos.supervision.business.dao.repository.IPlanAuditDao; import com.yeejoin.amos.supervision.business.dao.repository.IPlanAuditDao;
import com.yeejoin.amos.supervision.business.dao.repository.IPlanAuditLogDao; import com.yeejoin.amos.supervision.business.dao.repository.IPlanAuditLogDao;
import com.yeejoin.amos.supervision.business.dao.repository.IPlanDao; import com.yeejoin.amos.supervision.business.dao.repository.IPlanDao;
import com.yeejoin.amos.supervision.business.service.intfc.IPlanAuditService; import com.yeejoin.amos.supervision.business.service.intfc.IPlanAuditService;
import com.yeejoin.amos.supervision.common.enums.CheckTypeSuEnum;
import com.yeejoin.amos.supervision.common.enums.DangerCheckTypeLevelEnum;
import com.yeejoin.amos.supervision.common.enums.PlanStatusEnum; import com.yeejoin.amos.supervision.common.enums.PlanStatusEnum;
import com.yeejoin.amos.supervision.common.enums.WorkFlowBranchEnum;
import com.yeejoin.amos.supervision.dao.entity.Plan;
import com.yeejoin.amos.supervision.dao.entity.PlanAudit; import com.yeejoin.amos.supervision.dao.entity.PlanAudit;
import com.yeejoin.amos.supervision.dao.entity.PlanAuditLog; import com.yeejoin.amos.supervision.dao.entity.PlanAuditLog;
import org.apache.commons.lang3.ObjectUtils; import org.apache.commons.lang3.ObjectUtils;
...@@ -16,6 +22,7 @@ import org.springframework.stereotype.Service; ...@@ -16,6 +22,7 @@ import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.annotation.Transactional;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.HashMap;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
...@@ -34,26 +41,28 @@ public class PlanAuditServiceImpl implements IPlanAuditService { ...@@ -34,26 +41,28 @@ public class PlanAuditServiceImpl implements IPlanAuditService {
@Autowired @Autowired
private IPlanDao planDao; private IPlanDao planDao;
@Autowired
WorkflowFeignService workflowFeignService;
@Override @Override
@Transactional @Transactional
public Boolean auditWorkFlow(PlanAuditLog planAuditLog, Integer status, String condition, ReginParams reginParams) { public Boolean auditWorkFlow(PlanAuditLog planAuditLog, Integer status, String condition, ReginParams reginParams) throws Exception {
PlanAudit planAudit = planAuditDao.findByPlanId(planAuditLog.getPlanId()); PlanAudit planAudit = planAuditDao.findByPlanId(planAuditLog.getPlanId());
if (ObjectUtils.isNotEmpty(planAudit)) { if (ObjectUtils.isNotEmpty(planAudit)) {
String instanceId = planAudit.getProcessInstanceId(); String instanceId = planAudit.getProcessInstanceId();
Map<String, Object> taskAuthMap = workflowExcuteService.checkTaskAuthMap(instanceId, reginParams); Map<String, Object> taskAuthMap = workflowExcuteService.checkTaskAuthMap(instanceId, reginParams);
if (taskAuthMap != null && !taskAuthMap.isEmpty()) { if (taskAuthMap != null && !taskAuthMap.isEmpty()) {
// 获取当前计划
Plan plan = planDao.getOne(planAuditLog.getPlanId());
String taskId = taskAuthMap.get("taskId") == null ? null : taskAuthMap.get("taskId").toString(); String taskId = taskAuthMap.get("taskId") == null ? null : taskAuthMap.get("taskId").toString();
String name = taskAuthMap.get("name") == null ? null : taskAuthMap.get("name").toString(); String name = taskAuthMap.get("name") == null ? null : taskAuthMap.get("name").toString();
String roleName = reginParams.getRole().getRoleName(); String roleName = reginParams.getRole().getRoleName();
boolean b = workflowExcuteService.CompleteTask(instanceId, condition, reginParams); workflowExcuteService.CompleteTask(instanceId, condition, reginParams);
ReginParams.PersonIdentity personIdentity = reginParams.getPersonIdentity(); ReginParams.PersonIdentity personIdentity = reginParams.getPersonIdentity();
workflowExcuteService.setTaskAssign(instanceId, personIdentity.getPersonSeq()); String userId = reginParams.getUserModel().getUserId();
if (b) { // 更新计划状态,指定执行人
PlanStatusEnum statusEnum = PlanStatusEnum.getEnum(status); updatePlanStatus(condition,plan,instanceId,userId);
planDao.updatePlanStatus(statusEnum != null ? statusEnum.getNextStatus() : PlanStatusEnum.DRAFT.getValue(), planAuditLog.getPlanId()); // 更新流水表
} else {
planDao.updatePlanStatus(PlanStatusEnum.DRAFT.getValue(), planAuditLog.getPlanId());
}
planAuditLog.setPlanId(planAudit.getPlanId()); planAuditLog.setPlanId(planAudit.getPlanId());
planAuditLog.setPlanAuditId(planAudit.getId()); planAuditLog.setPlanAuditId(planAudit.getId());
planAuditLog.setExcuteUserId(personIdentity.getPersonSeq()); planAuditLog.setExcuteUserId(personIdentity.getPersonSeq());
...@@ -63,12 +72,42 @@ public class PlanAuditServiceImpl implements IPlanAuditService { ...@@ -63,12 +72,42 @@ public class PlanAuditServiceImpl implements IPlanAuditService {
planAuditLog.setFlowJson(condition); planAuditLog.setFlowJson(condition);
planAuditLog.setRoleName(roleName); planAuditLog.setRoleName(roleName);
planAuditLogDao.save(planAuditLog); planAuditLogDao.save(planAuditLog);
return b; return Boolean.TRUE;
} }
} }
return Boolean.FALSE; return Boolean.FALSE;
} }
/**
* 更新计划id
* @param condition 同意0 不同意1
* @param plan 当前计划对象
*/
private void updatePlanStatus (String condition, Plan plan, String instanceId, String userId) throws Exception {
String fail = "1";
if (fail.equals(condition)) {
planDao.updatePlanStatus(PlanStatusEnum.DRAFT.getValue(), plan.getId());
} else {
//检查级别
DangerCheckTypeLevelEnum dangerCheckTypeLevelEnum = DangerCheckTypeLevelEnum.getEumByCode(plan.getCheckLevel());
//检查类型
CheckTypeSuEnum checkTypeSuEnum = CheckTypeSuEnum.getEumByCode(plan.getCheckTypeId());
String branch = PlanServiceImpl.workFlowExcuteBranch(dangerCheckTypeLevelEnum.getCondition(), checkTypeSuEnum.getCondition());
if (branch.equals(WorkFlowBranchEnum.DAILY.getWorkFlowBranch())) {
if (PlanStatusEnum.EXAMINE_THREE.getValue() == plan.getStatus()) {
workflowExcuteService.setTaskAssign(instanceId, plan.getLeadPeopleIds());
}
PlanStatusEnum statusEnum = PlanStatusEnum.getEnum(plan.getStatus());
planDao.updatePlanStatus(statusEnum != null ? statusEnum.getNextStatus() : PlanStatusEnum.DRAFT.getValue(), plan.getId());
} else {
if (PlanStatusEnum.EXAMINE_ONE.getValue() == plan.getStatus()) {
workflowExcuteService.setTaskAssign(instanceId, plan.getLeadPeopleIds());
}
planDao.updatePlanStatus(PlanStatusEnum.EXAMINE_FORMULATE.getValue(), plan.getId());
}
}
}
@Override @Override
public List<PlanAuditLog> listByPlanId(Long planId) { public List<PlanAuditLog> listByPlanId(Long planId) {
Sort.Order idOrder = new Sort.Order(Sort.Direction.ASC, "createDate"); Sort.Order idOrder = new Sort.Order(Sort.Direction.ASC, "createDate");
......
...@@ -31,6 +31,8 @@ import org.springframework.stereotype.Service; ...@@ -31,6 +31,8 @@ import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.annotation.Transactional;
import org.springframework.util.ObjectUtils; import org.springframework.util.ObjectUtils;
import java.time.format.DateTimeFormatter;
import java.time.temporal.TemporalAccessor;
import java.util.*; import java.util.*;
import java.util.stream.Collectors; import java.util.stream.Collectors;
...@@ -94,12 +96,17 @@ public class PlanServiceImpl implements IPlanService { ...@@ -94,12 +96,17 @@ public class PlanServiceImpl implements IPlanService {
Set<String> distinctUserIds = new HashSet<>(Arrays.asList(temp)); Set<String> distinctUserIds = new HashSet<>(Arrays.asList(temp));
List<AgencyUserModel> userModels = remoteSecurityService.listUserByUserIds(Joiner.on(",").join(distinctUserIds)); List<AgencyUserModel> userModels = remoteSecurityService.listUserByUserIds(Joiner.on(",").join(distinctUserIds));
Map<String, String> userIdNameMap = userModels.stream().collect(Collectors.toMap(AgencyUserModel::getUserId, AgencyUserModel::getRealName)); Map<String, String> userIdNameMap = userModels.stream().collect(Collectors.toMap(AgencyUserModel::getUserId, AgencyUserModel::getRealName));
DateTimeFormatter dateTimeFormatter = DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss");
content.forEach(c -> { content.forEach(c -> {
this.buildUserName(c, "createBy", userIdNameMap); this.buildUserName(c, "createBy", userIdNameMap);
if (c.containsKey("status")) { if (c.containsKey("status")) {
String finishStatusDesc = PlanStatusEnum.getName(Integer.parseInt(c.get("status").toString())); String finishStatusDesc = PlanStatusEnum.getName(Integer.parseInt(c.get("status").toString()));
c.put("statusDesc", finishStatusDesc); c.put("statusDesc", finishStatusDesc);
} }
if (c.containsKey("createDate")) {
String createTime = dateTimeFormatter.format((TemporalAccessor) c.get("createDate"));
c.put("createDateStr", createTime);
}
}); });
return new PageImpl<>(content, param, total); return new PageImpl<>(content, param, total);
} }
...@@ -193,7 +200,7 @@ public class PlanServiceImpl implements IPlanService { ...@@ -193,7 +200,7 @@ public class PlanServiceImpl implements IPlanService {
planAuditLog.setFlowTaskName("发起审核"); planAuditLog.setFlowTaskName("发起审核");
planAuditLog.setExcuteUserId(param.getCreateBy()); planAuditLog.setExcuteUserId(param.getCreateBy());
planAuditLog.setExcuteUserName(personIdentity.getPersonName()); planAuditLog.setExcuteUserName(personIdentity.getPersonName());
planAuditLog.setExcuteState(1); planAuditLog.setExcuteState(0);
planAuditLog.setRoleName(reginParams.getRole().getRoleName()); planAuditLog.setRoleName(reginParams.getRole().getRoleName());
planAuditLogDao.save(planAuditLog); planAuditLogDao.save(planAuditLog);
} }
......
package com.yeejoin.amos.supervision.business.service.impl; package com.yeejoin.amos.supervision.business.service.impl;
import com.baomidou.mybatisplus.core.toolkit.ObjectUtils;
import com.google.common.collect.Lists; import com.google.common.collect.Lists;
import com.yeejoin.amos.supervision.business.dao.mapper.InputItemMapper; import com.yeejoin.amos.supervision.business.dao.mapper.InputItemMapper;
import com.yeejoin.amos.supervision.business.dao.mapper.RoutePointItemMapper; import com.yeejoin.amos.supervision.business.dao.mapper.RoutePointItemMapper;
...@@ -88,9 +89,9 @@ public class RoutePointItemServiceImpl implements IRoutePointItemService { ...@@ -88,9 +89,9 @@ public class RoutePointItemServiceImpl implements IRoutePointItemService {
} }
@Override @Override
public Integer deleteByIdIn(List<Long> ids) { public Integer deleteByIdIn(List<String> itemIds, Long planId) {
if (CollectionUtils.isNotEmpty(ids)) { if (CollectionUtils.isNotEmpty(itemIds) && ObjectUtils.isNotEmpty(planId)) {
return routePointItemDao.deleteByRoutePointItemId(ids); return routePointItemDao.deleteByRoutePointItemIdAndPlanId(itemIds, planId);
} }
return 0; return 0;
} }
......
...@@ -6,7 +6,7 @@ import com.yeejoin.amos.supervision.dao.entity.PlanAuditLog; ...@@ -6,7 +6,7 @@ import com.yeejoin.amos.supervision.dao.entity.PlanAuditLog;
import java.util.List; import java.util.List;
public interface IPlanAuditService { public interface IPlanAuditService {
Boolean auditWorkFlow(PlanAuditLog planAuditLog, Integer status, String condition, ReginParams reginParams); Boolean auditWorkFlow(PlanAuditLog planAuditLog, Integer status, String condition, ReginParams reginParams) throws Exception;
/** /**
* 查询指定计划的审批日志 * 查询指定计划的审批日志
......
...@@ -14,5 +14,5 @@ public interface IRoutePointItemService { ...@@ -14,5 +14,5 @@ public interface IRoutePointItemService {
Page<RoutePointItemVo> queryPage(InputItemPageParam criterias); Page<RoutePointItemVo> queryPage(InputItemPageParam criterias);
Integer deleteByIdIn(List<Long> ids); Integer deleteByIdIn(List<String> itemIds, Long planId);
} }
package com.yeejoin.amos.boot.module.tzs.biz.controller; package com.yeejoin.amos.boot.module.tzs.biz.controller;
import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper; import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
...@@ -36,7 +37,11 @@ import com.yeejoin.amos.feign.privilege.model.AgencyUserModel; ...@@ -36,7 +37,11 @@ import com.yeejoin.amos.feign.privilege.model.AgencyUserModel;
import io.swagger.annotations.Api; import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiOperation;
import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.StringUtils;
import org.eclipse.paho.client.mqttv3.MqttException;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.PostMapping;
...@@ -44,6 +49,7 @@ import org.springframework.web.bind.annotation.RequestBody; ...@@ -44,6 +49,7 @@ import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam; import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController; import org.springframework.web.bind.annotation.RestController;
import org.typroject.tyboot.component.emq.EmqKeeper;
import org.typroject.tyboot.core.foundation.enumeration.UserType; import org.typroject.tyboot.core.foundation.enumeration.UserType;
import org.typroject.tyboot.core.foundation.utils.ValidationUtil; import org.typroject.tyboot.core.foundation.utils.ValidationUtil;
import org.typroject.tyboot.core.restful.doc.TycloudOperation; import org.typroject.tyboot.core.restful.doc.TycloudOperation;
...@@ -52,6 +58,7 @@ import org.typroject.tyboot.core.restful.utils.ResponseHelper; ...@@ -52,6 +58,7 @@ import org.typroject.tyboot.core.restful.utils.ResponseHelper;
import org.typroject.tyboot.core.restful.utils.ResponseModel; import org.typroject.tyboot.core.restful.utils.ResponseModel;
import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpServletResponse;
import java.io.UnsupportedEncodingException;
import java.text.ParseException; import java.text.ParseException;
import java.util.Date; import java.util.Date;
import java.util.LinkedHashMap; import java.util.LinkedHashMap;
...@@ -69,6 +76,8 @@ import java.util.Map; ...@@ -69,6 +76,8 @@ import java.util.Map;
@RequestMapping(value = "/alert-called") @RequestMapping(value = "/alert-called")
public class AlertCalledController extends BaseController { public class AlertCalledController extends BaseController {
private final Logger logger = LoggerFactory.getLogger(AlertCalledController.class);
@Autowired @Autowired
RedisUtils redisUtils; RedisUtils redisUtils;
...@@ -96,6 +105,15 @@ public class AlertCalledController extends BaseController { ...@@ -96,6 +105,15 @@ public class AlertCalledController extends BaseController {
@Autowired @Autowired
ElevatorServiceImpl elevatorService; ElevatorServiceImpl elevatorService;
@Autowired
private EmqKeeper emqKeeper;
@Value("${mqtt.topic.alertReport.push}")
private String alertReportpushTopic;
@Value("${mqtt.topic.alertInfo.push}")
private String alertInfopushTopic;
/** /**
* 新增警情接警填报记录 * 新增警情接警填报记录
* *
...@@ -111,6 +129,27 @@ public class AlertCalledController extends BaseController { ...@@ -111,6 +129,27 @@ public class AlertCalledController extends BaseController {
} }
ReginParams reginParams = getSelectedOrgInfo(); ReginParams reginParams = getSelectedOrgInfo();
alertCalledObjsDto = iAlertCalledService.createAlertCalled(alertCalledObjsDto, reginParams.getUserModel()); alertCalledObjsDto = iAlertCalledService.createAlertCalled(alertCalledObjsDto, reginParams.getUserModel());
// 坐席接警后,辅屏由常态化切换为处置态
AgencyUserModel user =getUserInfo();
JSONObject jsonObject = new JSONObject();
jsonObject.put("userId",user.getUserId());
jsonObject.put("alertId",String.valueOf(alertCalledObjsDto.getAlertCalledDto().getSequenceNbr()));
JSONObject jsonObject1 = new JSONObject();
jsonObject.put("alertId",String.valueOf(alertCalledObjsDto.getAlertCalledDto().getSequenceNbr()));
try {
emqKeeper.getMqttClient().publish(alertReportpushTopic, jsonObject.toString().getBytes("UTF-8"), 1, false);
// 跑马灯消息提醒
if(null != alertCalledObjsDto.getAlertCalledDto().getFatherAlert()) {
emqKeeper.getMqttClient().publish(alertInfopushTopic, jsonObject1.toString().getBytes("UTF-8"), 1, false);
}
} catch (MqttException e) {
logger.error("mqtt发送失败" +jsonObject );
} catch (UnsupportedEncodingException e) {
logger.error("mqtt发送失败" +jsonObject );
}
return ResponseHelper.buildResponse(alertCalledObjsDto.getAlertCalledDto()); return ResponseHelper.buildResponse(alertCalledObjsDto.getAlertCalledDto());
} }
...@@ -188,6 +227,7 @@ public class AlertCalledController extends BaseController { ...@@ -188,6 +227,7 @@ public class AlertCalledController extends BaseController {
alertPaperInfoDto.setAlarmTypeCode(alertCalled.getAlarmTypeCode()); alertPaperInfoDto.setAlarmTypeCode(alertCalled.getAlarmTypeCode());
alertPaperInfoDto.setRegionCode(elevator.getRegionCode()); alertPaperInfoDto.setRegionCode(elevator.getRegionCode());
alertPaperInfoDto.setRescueCode(elevator.getRescueCode()); alertPaperInfoDto.setRescueCode(elevator.getRescueCode());
alertPaperInfoDto.setAlertStatus(alertCalled.getAlertStage());
return ResponseHelper.buildResponse(alertPaperInfoDto); return ResponseHelper.buildResponse(alertPaperInfoDto);
} }
...@@ -359,6 +399,8 @@ public class AlertCalledController extends BaseController { ...@@ -359,6 +399,8 @@ public class AlertCalledController extends BaseController {
pageBean = new Page<>(Integer.parseInt(pageNum), Integer.parseInt(pageSize)); pageBean = new Page<>(Integer.parseInt(pageNum), Integer.parseInt(pageSize));
} }
page = iAlertCalledService.page(pageBean, alertCalledQueryWrapper); page = iAlertCalledService.page(pageBean, alertCalledQueryWrapper);
int num= iAlertCalledService.count(alertCalledQueryWrapper);
pageBean.setTotal(num);
IPage<AlertCalledDto> calledVoIPage = AlertBeanDtoVoUtils.alertCalledIPageDto(page); IPage<AlertCalledDto> calledVoIPage = AlertBeanDtoVoUtils.alertCalledIPageDto(page);
return ResponseHelper.buildResponse(calledVoIPage); return ResponseHelper.buildResponse(calledVoIPage);
} }
......
package com.yeejoin.amos.boot.module.tzs.biz.controller;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.yeejoin.amos.boot.biz.common.controller.BaseController;
import com.yeejoin.amos.boot.module.tzs.api.dto.ElevatorAlarmDto;
import com.yeejoin.amos.boot.module.tzs.api.entity.ElevatorAlarm;
import com.yeejoin.amos.boot.module.tzs.biz.service.impl.ElevatorAlarmServiceImpl;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.PutMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
import org.typroject.tyboot.core.foundation.enumeration.UserType;
import org.typroject.tyboot.core.foundation.utils.Bean;
import org.typroject.tyboot.core.restful.doc.TycloudOperation;
import org.typroject.tyboot.core.restful.utils.ResponseHelper;
import org.typroject.tyboot.core.restful.utils.ResponseModel;
import javax.servlet.http.HttpServletRequest;
import java.util.List;
/**
*
*
* @author litw
* @date 2021-09-28
*/
@RestController
@Api(tags = "Api")
@RequestMapping(value = "/elevator-alarm")
public class ElevatorAlarmController extends BaseController {
@Autowired
ElevatorAlarmServiceImpl elevatorAlarmServiceImpl;
/**
* 新增
*
* @return
*/
@TycloudOperation(ApiLevel = UserType.AGENCY)
@PostMapping(value = "/save")
@ApiOperation(httpMethod = "POST", value = "新增", notes = "新增")
public ResponseModel<ElevatorAlarmDto> save(@RequestBody ElevatorAlarmDto model) {
model = elevatorAlarmServiceImpl.createWithModel(model);
return ResponseHelper.buildResponse(model);
}
/**
* 根据sequenceNbr更新
*
* @param sequenceNbr 主键
* @return
*/
@TycloudOperation(ApiLevel = UserType.AGENCY)
@PutMapping(value = "/{sequenceNbr}")
@ApiOperation(httpMethod = "PUT", value = "根据sequenceNbr更新", notes = "根据sequenceNbr更新")
public ResponseModel<ElevatorAlarmDto> updateBySequenceNbrElevatorAlarm(@RequestBody ElevatorAlarmDto model,@PathVariable(value = "sequenceNbr") Long sequenceNbr) {
model.setSequenceNbr(sequenceNbr);
return ResponseHelper.buildResponse(elevatorAlarmServiceImpl.updateWithModel(model));
}
/**
* 根据sequenceNbr删除
*
* @param sequenceNbr 主键
* @return
*/
@TycloudOperation(ApiLevel = UserType.AGENCY)
@DeleteMapping(value = "/{sequenceNbr}")
@ApiOperation(httpMethod = "DELETE", value = "根据sequenceNbr删除", notes = "根据sequenceNbr删除")
public ResponseModel<Boolean> deleteBySequenceNbr(HttpServletRequest request, @PathVariable(value = "sequenceNbr") Long sequenceNbr){
return ResponseHelper.buildResponse(elevatorAlarmServiceImpl.removeById(sequenceNbr));
}
/**
* 根据sequenceNbr查询
*
* @param sequenceNbr 主键
* @return
*/
@TycloudOperation(ApiLevel = UserType.AGENCY)
@GetMapping(value = "/{sequenceNbr}")
@ApiOperation(httpMethod = "GET",value = "根据sequenceNbr查询单个", notes = "根据sequenceNbr查询单个")
public ResponseModel<ElevatorAlarmDto> selectOne(@PathVariable Long sequenceNbr) {
return ResponseHelper.buildResponse(elevatorAlarmServiceImpl.queryBySeq(sequenceNbr));
}
/**
* 列表分页查询
*
* @param current 当前页
* @param current 每页大小
* @return
*/
@TycloudOperation(ApiLevel = UserType.AGENCY)
@GetMapping(value = "/page")
@ApiOperation(httpMethod = "GET",value = "分页查询", notes = "分页查询")
public ResponseModel<Page<ElevatorAlarmDto>> queryForPage(@RequestParam(value = "current") int current,@RequestParam
(value = "size") int size) {
Page<ElevatorAlarmDto> page = new Page<ElevatorAlarmDto>();
page.setCurrent(current);
page.setSize(size);
return ResponseHelper.buildResponse(elevatorAlarmServiceImpl.queryForElevatorAlarmPage(page));
}
/**
* 列表全部数据查询
*
* @return
*/
@TycloudOperation(ApiLevel = UserType.AGENCY)
@ApiOperation(httpMethod = "GET",value = "列表全部数据查询", notes = "列表全部数据查询")
@GetMapping(value = "/list")
public ResponseModel<List<ElevatorAlarmDto>> selectForList() {
return ResponseHelper.buildResponse(elevatorAlarmServiceImpl.queryForElevatorAlarmList());
}
/**
* 根据电梯注册码查询物联信息
*
* @param registerCode 主键
* @return
*/
@TycloudOperation(ApiLevel = UserType.AGENCY)
@GetMapping(value = "/getElevatorStatus")
@ApiOperation(httpMethod = "GET",value = "根据电梯注册码查询物联信息", notes = "根据电梯注册码查询物联信息")
public ResponseModel<ElevatorAlarmDto> selectOne(@RequestParam String registerCode) {
LambdaQueryWrapper<ElevatorAlarm> queryWrapper = new LambdaQueryWrapper<>();
queryWrapper.eq(ElevatorAlarm::getRegisterCode,registerCode);
queryWrapper.orderByDesc(ElevatorAlarm::getStartDate);
List<ElevatorAlarm> elevatorStatus = elevatorAlarmServiceImpl.list(queryWrapper);
if(null != elevatorStatus && elevatorStatus.size() > 0) {
ElevatorAlarmDto dto = new ElevatorAlarmDto();
Bean.toPo(elevatorStatus.get(0),dto);
return ResponseHelper.buildResponse(dto);
}
return ResponseHelper.buildResponse(null);
}
}
...@@ -4,7 +4,6 @@ import com.alibaba.fastjson.JSONObject; ...@@ -4,7 +4,6 @@ import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.yeejoin.amos.boot.biz.common.bo.ReginParams;
import com.yeejoin.amos.boot.biz.common.controller.BaseController; import com.yeejoin.amos.boot.biz.common.controller.BaseController;
import com.yeejoin.amos.boot.biz.common.feign.AmosFeignService; import com.yeejoin.amos.boot.biz.common.feign.AmosFeignService;
import com.yeejoin.amos.boot.biz.common.utils.NameUtils; import com.yeejoin.amos.boot.biz.common.utils.NameUtils;
...@@ -14,8 +13,8 @@ import com.yeejoin.amos.boot.module.tzs.api.dto.ElevatorInfoDto; ...@@ -14,8 +13,8 @@ import com.yeejoin.amos.boot.module.tzs.api.dto.ElevatorInfoDto;
import com.yeejoin.amos.boot.module.tzs.api.dto.ElevatorMaintenanceInfoDto; import com.yeejoin.amos.boot.module.tzs.api.dto.ElevatorMaintenanceInfoDto;
import com.yeejoin.amos.boot.module.tzs.api.dto.ElevatorNewDto; import com.yeejoin.amos.boot.module.tzs.api.dto.ElevatorNewDto;
import com.yeejoin.amos.boot.module.tzs.api.dto.ElevatorTestInfoDto; import com.yeejoin.amos.boot.module.tzs.api.dto.ElevatorTestInfoDto;
import com.yeejoin.amos.boot.module.tzs.api.dto.ElevatorWlInfoDto;
import com.yeejoin.amos.boot.module.tzs.api.dto.EsElevatorDto; import com.yeejoin.amos.boot.module.tzs.api.dto.EsElevatorDto;
import com.yeejoin.amos.boot.module.tzs.api.entity.DispatchTask;
import com.yeejoin.amos.boot.module.tzs.api.entity.Elevator; import com.yeejoin.amos.boot.module.tzs.api.entity.Elevator;
import com.yeejoin.amos.boot.module.tzs.api.entity.MaintainInfo; import com.yeejoin.amos.boot.module.tzs.api.entity.MaintainInfo;
import com.yeejoin.amos.boot.module.tzs.api.entity.TestInfo; import com.yeejoin.amos.boot.module.tzs.api.entity.TestInfo;
...@@ -370,7 +369,7 @@ public class ElevatorController extends BaseController { ...@@ -370,7 +369,7 @@ public class ElevatorController extends BaseController {
public void init() { public void init() {
IPage<Elevator> elevatorPage = new Page<>(); IPage<Elevator> elevatorPage = new Page<>();
Integer count = elevatorService.count(); Integer count = elevatorService.count();
for(int i = 0; i <= 2 ; i ++ ) { for(int i = 0; i <= 3 ; i ++ ) {
elevatorPage.setCurrent(i); elevatorPage.setCurrent(i);
elevatorPage.setSize(500); elevatorPage.setSize(500);
elevatorPage = elevatorService.page(elevatorPage); elevatorPage = elevatorService.page(elevatorPage);
...@@ -433,5 +432,46 @@ public class ElevatorController extends BaseController { ...@@ -433,5 +432,46 @@ public class ElevatorController extends BaseController {
} }
/**
* 查询电梯物联信息
*
* @param elevatorDto 查询参数
* @return 查询结果
*/
@TycloudOperation(ApiLevel = UserType.AGENCY)
@RequestMapping(value = "/query_elevator_list_wl", method = RequestMethod.GET)
@ApiOperation(httpMethod = "GET", value = "查询电梯信息", notes = "查询电梯信息")
public ResponseModel<IPage<ElevatorWlInfoDto>> queryElevatorList(
ElevatorWlInfoDto elevatorDto){
IPage<ElevatorWlInfoDto> iPage = new Page<>();
iPage.setCurrent((elevatorDto.getPage()-1)*elevatorDto.getSize());
iPage.setSize(elevatorDto.getSize());
iPage.setRecords( elevatorService.queryElevatorList(elevatorDto));
iPage.setTotal(elevatorService.queryElevatorListCount());
return ResponseHelper.buildResponse(iPage);
}
/**
* 查询电梯物联信息详情
*
* @param elevatorDto 查询参数
* @return 查询结果
*/
@TycloudOperation(ApiLevel = UserType.AGENCY)
@RequestMapping(value = "/query_elevator_list_wl_details", method = RequestMethod.POST)
@ApiOperation(httpMethod = "POST", value = "查询电梯信息", notes = "查询电梯信息")
public ResponseModel<ElevatorWlInfoDto> queryElevato(
@RequestBody ElevatorWlInfoDto elevatorDto){
if(null == elevatorDto.getSequenceNbr()) {
throw new BadRequest("参数错误");
}
List<ElevatorWlInfoDto> page = elevatorService.queryElevatorListDetails(elevatorDto);
if(page.size()>0) {
return ResponseHelper.buildResponse(page.get(0));
}
return ResponseHelper.buildResponse(null);
}
} }
package com.yeejoin.amos.boot.module.tzs.biz.controller;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.yeejoin.amos.boot.biz.common.controller.BaseController;
import com.yeejoin.amos.boot.module.tzs.api.dto.ElevatorStatusHandleDto;
import com.yeejoin.amos.boot.module.tzs.api.entity.ElevatorStatus;
import com.yeejoin.amos.boot.module.tzs.api.enums.LiftBitStatusEnum;
import com.yeejoin.amos.boot.module.tzs.api.enums.LiftDirectionEnum;
import com.yeejoin.amos.boot.module.tzs.api.enums.LiftDoorStatusEnum;
import com.yeejoin.amos.boot.module.tzs.api.enums.LiftIszoneEnum;
import com.yeejoin.amos.boot.module.tzs.api.enums.LiftServiceModelEnum;
import com.yeejoin.amos.boot.module.tzs.api.enums.LiftStatusEnum;
import com.yeejoin.amos.boot.module.tzs.biz.service.impl.ElevatorStatusServiceImpl;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
import org.typroject.tyboot.core.foundation.enumeration.UserType;
import org.typroject.tyboot.core.restful.doc.TycloudOperation;
import org.typroject.tyboot.core.restful.utils.ResponseHelper;
import org.typroject.tyboot.core.restful.utils.ResponseModel;
import java.util.List;
/**
*
*
* @author litw
* @date 2021-09-28
*/
@RestController
@Api(tags = "物联电梯状态Api")
@RequestMapping(value = "/elevator-status")
public class ElevatorStatusController extends BaseController {
@Autowired
ElevatorStatusServiceImpl elevatorStatusServiceImpl;
/**
* 根据电梯注册码查询物联信息
*
* @param registerCode 主键
* @return
*/
@TycloudOperation(ApiLevel = UserType.AGENCY)
@GetMapping(value = "/getElevatorStatus")
@ApiOperation(httpMethod = "GET",value = "根据电梯注册码查询物联信息", notes = "根据电梯注册码查询物联信息")
public ResponseModel<ElevatorStatusHandleDto> selectOne(@RequestParam String registerCode) {
LambdaQueryWrapper<ElevatorStatus> queryWrapper = new LambdaQueryWrapper<>();
queryWrapper.eq(ElevatorStatus::getRegisterCode,registerCode);
queryWrapper.orderByDesc(ElevatorStatus::getUploadDate);
List<ElevatorStatus> elevatorStatus = elevatorStatusServiceImpl.list(queryWrapper);
if(null != elevatorStatus && elevatorStatus.size() > 0) {
ElevatorStatus el = elevatorStatus.get(0);
ElevatorStatusHandleDto dto = new ElevatorStatusHandleDto();
dto.setDoorStatus(LiftDoorStatusEnum.getEnum(el.getDoorStatus()).getName());
dto.setIsZone(LiftIszoneEnum.getEnum(el.getIsZone()).getName());
dto.setLiftDirection(LiftDirectionEnum.getEnum(el.getLiftDirection()).getName());
dto.setPersonFlag(LiftBitStatusEnum.getEnum(el.getPersonFlag()).getName());
dto.setServiceModel(LiftServiceModelEnum.getEnum(el.getServiceModel()).getName());
dto.setCurrFloor(el.getCurrFloor());
dto.setLiftStatus(LiftStatusEnum.getEnum(el.getLiftStatus()).getName());
return ResponseHelper.buildResponse(dto);
}
return ResponseHelper.buildResponse(null);
}
}
...@@ -46,6 +46,7 @@ import org.typroject.tyboot.core.restful.exception.instance.BadRequest; ...@@ -46,6 +46,7 @@ import org.typroject.tyboot.core.restful.exception.instance.BadRequest;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.Date; import java.util.Date;
import java.util.HashMap; import java.util.HashMap;
import java.util.LinkedHashMap;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
import java.util.stream.Collectors; import java.util.stream.Collectors;
...@@ -263,16 +264,16 @@ public class AlertCalledServiceImpl extends BaseService<AlertCalledDto,AlertCall ...@@ -263,16 +264,16 @@ public class AlertCalledServiceImpl extends BaseService<AlertCalledDto,AlertCall
@Override @Override
public AlertHandlerDto getHandlerInfo(String alertId) { public AlertHandlerDto getHandlerInfo(String alertId) {
AlertHandlerDto alertHandlerDto = new AlertHandlerDto(); AlertHandlerDto alertHandlerDto = new AlertHandlerDto();
Map<String,Date> map = new HashMap<>(); LinkedHashMap<String,Date> map = new LinkedHashMap<>();
List<AlertHandlerInfoDto> list = new ArrayList<>(); List<AlertHandlerInfoDto> list = new ArrayList<>();
AlertHandlerInfoDto alertHandlerInfoDtoHead = new AlertHandlerInfoDto(); AlertHandlerInfoDto alertHandlerInfoDtoHead = new AlertHandlerInfoDto();
alertHandlerInfoDtoHead.setProcess("处置流程"); alertHandlerInfoDtoHead.setAbProcess("处置流程");
alertHandlerInfoDtoHead.setAnswerThePolice("接警"); alertHandlerInfoDtoHead.setAcAnswerThePolice("接警");
alertHandlerInfoDtoHead.setReport("上报"); alertHandlerInfoDtoHead.setAcReport("上报");
alertHandlerInfoDtoHead.setNotice("派遣/通知"); alertHandlerInfoDtoHead.setAdNotice("派遣/通知");
alertHandlerInfoDtoHead.setArrive("到达"); alertHandlerInfoDtoHead.setAedArrive("到达");
alertHandlerInfoDtoHead.setComplete("完成"); alertHandlerInfoDtoHead.setAfeComplete("完成");
alertHandlerInfoDtoHead.setReturnVisit("回访"); alertHandlerInfoDtoHead.setAgReturnVisit("回访");
list.add(alertHandlerInfoDtoHead); list.add(alertHandlerInfoDtoHead);
AlertCalled called = this.getById(Long.valueOf(alertId)); AlertCalled called = this.getById(Long.valueOf(alertId));
...@@ -280,8 +281,8 @@ public class AlertCalledServiceImpl extends BaseService<AlertCalledDto,AlertCall ...@@ -280,8 +281,8 @@ public class AlertCalledServiceImpl extends BaseService<AlertCalledDto,AlertCall
if(null == called) { if(null == called) {
throw new BadRequest("警情不存在"); throw new BadRequest("警情不存在");
} }
map.put("answerThePolice",called.getCallTime()); map.put("acAnswerThePolice",called.getCallTime());
map.put("report",called.getRecDate()); map.put("acReport",called.getRecDate());
LambdaQueryWrapper<DispatchPaper> queryWrapper = new LambdaQueryWrapper(); LambdaQueryWrapper<DispatchPaper> queryWrapper = new LambdaQueryWrapper();
queryWrapper.eq(DispatchPaper::getAlertId,Long.valueOf(alertId)); queryWrapper.eq(DispatchPaper::getAlertId,Long.valueOf(alertId));
...@@ -300,9 +301,9 @@ public class AlertCalledServiceImpl extends BaseService<AlertCalledDto,AlertCall ...@@ -300,9 +301,9 @@ public class AlertCalledServiceImpl extends BaseService<AlertCalledDto,AlertCall
if(null != dispatchTask &&dispatchTask.size() > 0 ) { if(null != dispatchTask &&dispatchTask.size() > 0 ) {
List<DispatchTask> taskList = dispatchTask.stream().filter(e->e.getOrgType().equals(s)).collect(Collectors.toList()); List<DispatchTask> taskList = dispatchTask.stream().filter(e->e.getOrgType().equals(s)).collect(Collectors.toList());
if(taskList.size() > 0) { if(taskList.size() > 0) {
map.put("notice",called.getRecDate()); map.put("adNotice",called.getRecDate());
map.put("arrive",dispatchTask.get(0).getArriveTime()); map.put("aedArrive",dispatchTask.get(0).getArriveTime());
map.put("complete",dispatchTask.get(0).getSaveTime()); map.put("afeComplete",dispatchTask.get(0).getSaveTime());
dataInit(alertHandlerInfoDto,s,"", "","已派遣", dataInit(alertHandlerInfoDto,s,"", "","已派遣",
dispatchTask.get(0).getArriveTime() == null ? "" : "已到达" ,dispatchTask.get(0).getSaveTime() == null ? "" : "已完成", dispatchTask.get(0).getArriveTime() == null ? "" : "已到达" ,dispatchTask.get(0).getSaveTime() == null ? "" : "已完成",
dispatchPaper.getFeedbackTime() != null || dispatchPaper.getFeedbackFinishTime() != null ? "已回访" : ""); dispatchPaper.getFeedbackTime() != null || dispatchPaper.getFeedbackFinishTime() != null ? "已回访" : "");
...@@ -312,7 +313,7 @@ public class AlertCalledServiceImpl extends BaseService<AlertCalledDto,AlertCall ...@@ -312,7 +313,7 @@ public class AlertCalledServiceImpl extends BaseService<AlertCalledDto,AlertCall
} }
list.add(alertHandlerInfoDto); list.add(alertHandlerInfoDto);
} }
map.put("returnVisit",dispatchPaper.getFeedbackTime()); map.put("agReturnVisit",dispatchPaper.getFeedbackTime());
} else { } else {
for(String s:str) { for(String s:str) {
AlertHandlerInfoDto alertHandlerInfoDto = new AlertHandlerInfoDto(); AlertHandlerInfoDto alertHandlerInfoDto = new AlertHandlerInfoDto();
...@@ -329,18 +330,20 @@ public class AlertCalledServiceImpl extends BaseService<AlertCalledDto,AlertCall ...@@ -329,18 +330,20 @@ public class AlertCalledServiceImpl extends BaseService<AlertCalledDto,AlertCall
public Object getCalledInfo() { public Object getCalledInfo() {
LambdaQueryWrapper<AlertCalled> queryWrapper = new LambdaQueryWrapper(); LambdaQueryWrapper<AlertCalled> queryWrapper = new LambdaQueryWrapper();
queryWrapper.eq(AlertCalled::getAlertStageCode,"860"); queryWrapper.eq(AlertCalled::getAlertStageCode,"860");
queryWrapper.ge(AlertCalled::getCallTime,DateUtils.stampToDate(System.currentTimeMillis(),DateUtils.DATE_PATTERN));
queryWrapper.le(AlertCalled::getCallTime,DateUtils.stampToDate(DateUtils.dateAddDays(new Date(),1).getTime(),DateUtils.DATE_PATTERN));
Object list = this.list(queryWrapper); Object list = this.list(queryWrapper);
return list; return list;
} }
private void dataInit(AlertHandlerInfoDto alertHandlerInfoDto, String process,String answerThePolice, String report, String notice, String arrive, String complete,String returnVisit) { private void dataInit(AlertHandlerInfoDto alertHandlerInfoDto, String process,String answerThePolice, String report, String notice, String arrive, String complete,String returnVisit) {
alertHandlerInfoDto.setProcess(process); alertHandlerInfoDto.setAbProcess(process);
alertHandlerInfoDto.setAnswerThePolice(answerThePolice); alertHandlerInfoDto.setAcAnswerThePolice(answerThePolice);
alertHandlerInfoDto.setReport(report); alertHandlerInfoDto.setAcReport(report);
alertHandlerInfoDto.setNotice(notice); alertHandlerInfoDto.setAdNotice(notice);
alertHandlerInfoDto.setArrive(arrive); alertHandlerInfoDto.setAedArrive(arrive);
alertHandlerInfoDto.setComplete(complete); alertHandlerInfoDto.setAfeComplete(complete);
alertHandlerInfoDto.setReturnVisit(returnVisit); alertHandlerInfoDto.setAgReturnVisit(returnVisit);
} }
......
package com.yeejoin.amos.boot.module.tzs.biz.service.impl; package com.yeejoin.amos.boot.module.tzs.biz.service.impl;
import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper; import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
...@@ -37,17 +38,23 @@ import com.yeejoin.amos.boot.module.tzs.api.service.IDispatchTaskService; ...@@ -37,17 +38,23 @@ import com.yeejoin.amos.boot.module.tzs.api.service.IDispatchTaskService;
import com.yeejoin.amos.boot.module.tzs.api.service.IMaintenanceUnitService; import com.yeejoin.amos.boot.module.tzs.api.service.IMaintenanceUnitService;
import com.yeejoin.amos.boot.module.tzs.api.service.IRescueStationService; import com.yeejoin.amos.boot.module.tzs.api.service.IRescueStationService;
import com.yeejoin.amos.boot.module.tzs.api.service.IUseUnitService; import com.yeejoin.amos.boot.module.tzs.api.service.IUseUnitService;
import com.yeejoin.amos.boot.module.tzs.biz.controller.WechatController;
import com.yeejoin.amos.boot.module.tzs.biz.utils.BeanDtoVoUtils; import com.yeejoin.amos.boot.module.tzs.biz.utils.BeanDtoVoUtils;
import com.yeejoin.amos.feign.privilege.model.AgencyUserModel; import com.yeejoin.amos.feign.privilege.model.AgencyUserModel;
import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.StringUtils;
import org.eclipse.paho.client.mqttv3.MqttException;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value; import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.annotation.Transactional;
import org.typroject.tyboot.component.emq.EmqKeeper;
import org.typroject.tyboot.core.rdbms.service.BaseService; import org.typroject.tyboot.core.rdbms.service.BaseService;
import org.typroject.tyboot.core.restful.exception.instance.BadRequest; import org.typroject.tyboot.core.restful.exception.instance.BadRequest;
import org.typroject.tyboot.core.restful.utils.ResponseHelper; import org.typroject.tyboot.core.restful.utils.ResponseHelper;
import java.io.UnsupportedEncodingException;
import java.text.SimpleDateFormat; import java.text.SimpleDateFormat;
import java.util.Date; import java.util.Date;
import java.util.HashMap; import java.util.HashMap;
...@@ -63,7 +70,7 @@ import java.util.Map; ...@@ -63,7 +70,7 @@ import java.util.Map;
@Service @Service
public class DispatchTaskServiceImpl extends BaseService<DispatchTaskDto,DispatchTask,DispatchTaskMapper> implements IDispatchTaskService { public class DispatchTaskServiceImpl extends BaseService<DispatchTaskDto,DispatchTask,DispatchTaskMapper> implements IDispatchTaskService {
private final Logger logger = LoggerFactory.getLogger(DispatchTaskServiceImpl.class);
@Autowired @Autowired
DispatchPaperServiceImpl dispatchPaperServiceImpl; DispatchPaperServiceImpl dispatchPaperServiceImpl;
...@@ -106,6 +113,9 @@ public class DispatchTaskServiceImpl extends BaseService<DispatchTaskDto,Dispatc ...@@ -106,6 +113,9 @@ public class DispatchTaskServiceImpl extends BaseService<DispatchTaskDto,Dispatc
@Autowired @Autowired
WechatServiceImpl wechatService; WechatServiceImpl wechatService;
@Autowired
private EmqKeeper emqKeeper;
@Value("${tzs.wechat.tempId.kr}") @Value("${tzs.wechat.tempId.kr}")
private String KRJY_TEMPID; private String KRJY_TEMPID;
...@@ -124,6 +134,10 @@ public class DispatchTaskServiceImpl extends BaseService<DispatchTaskDto,Dispatc ...@@ -124,6 +134,10 @@ public class DispatchTaskServiceImpl extends BaseService<DispatchTaskDto,Dispatc
@Value("${tzs.wechat.url.ts}") @Value("${tzs.wechat.url.ts}")
private String TS_URL; private String TS_URL;
@Value("${mqtt.topic.task.newtask}")
private String newTaskTopic;
/** /**
* 分页查询 * 分页查询
*/ */
...@@ -606,6 +620,17 @@ public class DispatchTaskServiceImpl extends BaseService<DispatchTaskDto,Dispatc ...@@ -606,6 +620,17 @@ public class DispatchTaskServiceImpl extends BaseService<DispatchTaskDto,Dispatc
WechatMessageDto dto = this.getWechatMessageDtoByDispatchTaskDto(dispatchTaskDto); WechatMessageDto dto = this.getWechatMessageDtoByDispatchTaskDto(dispatchTaskDto);
wechatService.sendWechatModelMessage(temp.getOpenId() , dto); wechatService.sendWechatModelMessage(temp.getOpenId() , dto);
} }
// mqtt 通知新派遣
JSONObject jsonObject = new JSONObject();
jsonObject.put("taskId",dispatchTaskDto.getSequenceNbr());
try {
emqKeeper.getMqttClient().publish(newTaskTopic, jsonObject.toString().getBytes("UTF-8"), 1, false);
} catch (MqttException e) {
logger.error("mqtt发送失败" +jsonObject );
} catch (UnsupportedEncodingException e) {
logger.error("mqtt发送失败" +jsonObject );
}
} }
return flag; return flag;
} }
......
...@@ -46,6 +46,12 @@ public class ESElevatorServiceImpl { ...@@ -46,6 +46,12 @@ public class ESElevatorServiceImpl {
@Autowired @Autowired
AlertCalledServiceImpl iAlertCalledService; AlertCalledServiceImpl iAlertCalledService;
@Autowired
ElevatorServiceImpl elevatorService;
@Autowired
ElevatorAlarmServiceImpl elevatorAlarmServiceImpl;
@Value("${alertcall.es.synchrony.time}") @Value("${alertcall.es.synchrony.time}")
private Long time; private Long time;
...@@ -103,28 +109,32 @@ public class ESElevatorServiceImpl { ...@@ -103,28 +109,32 @@ public class ESElevatorServiceImpl {
if(!ValidationUtil.isEmpty(alarmTypeCode)) { if(!ValidationUtil.isEmpty(alarmTypeCode)) {
queryWrapper.eq(AlertCalled::getAlarmTypeCode,alarmTypeCode); queryWrapper.eq(AlertCalled::getAlarmTypeCode,alarmTypeCode);
} }
AlertCalled alertCalled = null;
List<AlertCalled> alertCalleds = null;
if(!ValidationUtil.isEmpty(alertId)) { if(!ValidationUtil.isEmpty(alertId)) {
AlertCalled alertCalled = iAlertCalledService.getById(elevatorDto.getAlertId()); alertCalled = iAlertCalledService.getById(elevatorDto.getAlertId());
BoolQueryBuilder qb4 = QueryBuilders.boolQuery(); BoolQueryBuilder qb4 = QueryBuilders.boolQuery();
qb4.must(QueryBuilders.termQuery("sequenceNbr", alertCalled.getEquipmentId())); qb4.must(QueryBuilders.termQuery("sequenceNbr", alertCalled.getEquipmentId()));
boolMust.must(qb4); boolMust.must(qb4);
} } else {
if(!ValidationUtil.isEmpty(elevatorDto.getAlarmTypeCode())) {
if(elevatorDto.getIsToday() != null && elevatorDto.getIsToday()) {
queryWrapper.ge(AlertCalled::getCallTime, DateUtils.stampToDate(System.currentTimeMillis(),DateUtils.DATE_PATTERN));
queryWrapper.le(AlertCalled::getCallTime, DateUtils.stampToDate(DateUtils.dateAddDays(new Date(),1).getTime(),DateUtils.DATE_PATTERN));
}
if(elevatorDto.getIsToday() != null && elevatorDto.getIsToday()) { alertCalleds = iAlertCalledService.list(queryWrapper);
queryWrapper.ge(AlertCalled::getCallTime, DateUtils.stampToDate(System.currentTimeMillis(),DateUtils.DATE_PATTERN)); List<Long> stringList = new ArrayList<>();
queryWrapper.le(AlertCalled::getCallTime, DateUtils.stampToDate(DateUtils.dateAddDays(new Date(),1).getTime(),DateUtils.DATE_PATTERN)); for (AlertCalled al: alertCalleds
) {
stringList.add(al.getEquipmentId());
}
List<Long> listL = stringList.stream().distinct().collect(Collectors.toList());
qb0.should(QueryBuilders.termsQuery("sequenceNbr", listL.toArray()));
boolMust.must(qb0);
}
} }
List<AlertCalled> alertCalleds = iAlertCalledService.list(queryWrapper);
List<Long> stringList = new ArrayList<>();
for (AlertCalled al: alertCalleds
) {
stringList.add(al.getEquipmentId());
}
List<Long> listL = stringList.stream().distinct().collect(Collectors.toList());
qb0.should(QueryBuilders.termsQuery("sequenceNbr", listL.toArray()));
boolMust.must(qb0);
if(!ValidationUtil.isEmpty(address)) { if(!ValidationUtil.isEmpty(address)) {
BoolQueryBuilder boolMustAddress = QueryBuilders.boolQuery(); BoolQueryBuilder boolMustAddress = QueryBuilders.boolQuery();
...@@ -158,16 +168,21 @@ public class ESElevatorServiceImpl { ...@@ -158,16 +168,21 @@ public class ESElevatorServiceImpl {
{ {
JSONObject jsonObject = (JSONObject) JSONObject.toJSON(searchHit.getContent()); JSONObject jsonObject = (JSONObject) JSONObject.toJSON(searchHit.getContent());
EsElevatorDto esElevatorDto =JSONObject.toJavaObject(jsonObject, EsElevatorDto.class); EsElevatorDto esElevatorDto =JSONObject.toJavaObject(jsonObject, EsElevatorDto.class);
for (AlertCalled al: alertCalleds
) { if(null != alertCalleds) {
if(al.getEquipmentId().equals(esElevatorDto.getSequenceNbr())) { for (AlertCalled al: alertCalleds
esElevatorDto.setHappenTime(al.getCallTime()); ) {
esElevatorDto.setAlertId(String.valueOf(al.getSequenceNbr())); if(al.getEquipmentId().equals(esElevatorDto.getSequenceNbr())) {
esElevatorDto.setAlarmTypeCode(al.getAlarmTypeCode()); esElevatorDto.setHappenTime(al.getCallTime());
break; esElevatorDto.setAlertId(String.valueOf(al.getSequenceNbr()));
} esElevatorDto.setAlarmTypeCode(al.getAlarmTypeCode());
list.add(esElevatorDto);
break;
}
}
} else {
list.add(esElevatorDto);
} }
list.add(esElevatorDto);
} }
} }
catch (Exception e) catch (Exception e)
...@@ -176,4 +191,5 @@ public class ESElevatorServiceImpl { ...@@ -176,4 +191,5 @@ public class ESElevatorServiceImpl {
} }
return list; return list;
} }
} }
package com.yeejoin.amos.boot.module.tzs.biz.service.impl;
import com.yeejoin.amos.boot.module.tzs.api.entity.ElevatorAlarm;
import com.yeejoin.amos.boot.module.tzs.api.mapper.ElevatorAlarmMapper;
import com.yeejoin.amos.boot.module.tzs.api.service.IElevatorAlarmService;
import com.yeejoin.amos.boot.module.tzs.api.dto.ElevatorAlarmDto;
import org.typroject.tyboot.core.rdbms.service.BaseService;
import org.springframework.stereotype.Service;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import java.util.List;
/**
* 服务实现类
*
* @author litw
* @date 2021-09-28
*/
@Service
public class ElevatorAlarmServiceImpl extends BaseService<ElevatorAlarmDto,ElevatorAlarm,ElevatorAlarmMapper> implements IElevatorAlarmService {
/**
* 分页查询
*/
public Page<ElevatorAlarmDto> queryForElevatorAlarmPage(Page<ElevatorAlarmDto> page) {
return this.queryForPage(page, null, false);
}
/**
* 列表查询 示例
*/
public List<ElevatorAlarmDto> queryForElevatorAlarmList() {
return this.queryForList("" , false);
}
}
\ No newline at end of file
package com.yeejoin.amos.boot.module.tzs.biz.service.impl; package com.yeejoin.amos.boot.module.tzs.biz.service.impl;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper; import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
import com.google.common.collect.Lists; import com.google.common.collect.Lists;
import com.yeejoin.amos.boot.module.common.biz.service.impl.SourceFileServiceImpl; import com.yeejoin.amos.boot.module.common.biz.service.impl.SourceFileServiceImpl;
import com.yeejoin.amos.boot.module.tzs.api.dto.AlertCalledDto; import com.yeejoin.amos.boot.module.tzs.api.dto.AlertCalledDto;
import com.yeejoin.amos.boot.module.tzs.api.dto.ElevatorDto; import com.yeejoin.amos.boot.module.tzs.api.dto.ElevatorDto;
import com.yeejoin.amos.boot.module.tzs.api.dto.ElevatorWlInfoDto;
import com.yeejoin.amos.boot.module.tzs.api.entity.Elevator; import com.yeejoin.amos.boot.module.tzs.api.entity.Elevator;
import com.yeejoin.amos.boot.module.tzs.api.mapper.ElevatorMapper; import com.yeejoin.amos.boot.module.tzs.api.mapper.ElevatorMapper;
import com.yeejoin.amos.boot.module.tzs.api.service.IElevatorService; import com.yeejoin.amos.boot.module.tzs.api.service.IElevatorService;
...@@ -33,6 +33,9 @@ public class ElevatorServiceImpl extends BaseService<ElevatorDto, Elevator, Elev ...@@ -33,6 +33,9 @@ public class ElevatorServiceImpl extends BaseService<ElevatorDto, Elevator, Elev
@Autowired @Autowired
AlertCalledServiceImpl alertCalledServiceImpl; AlertCalledServiceImpl alertCalledServiceImpl;
@Autowired
ElevatorMapper elevatorMapper;
/** /**
* 保存电梯信息 * 保存电梯信息
* *
...@@ -109,4 +112,23 @@ public class ElevatorServiceImpl extends BaseService<ElevatorDto, Elevator, Elev ...@@ -109,4 +112,23 @@ public class ElevatorServiceImpl extends BaseService<ElevatorDto, Elevator, Elev
throw new BadRequest("设备未找到"); throw new BadRequest("设备未找到");
return elevator; return elevator;
} }
public List<ElevatorWlInfoDto> queryElevatorList(ElevatorWlInfoDto esElevatorDto) {
return elevatorMapper.queryElevatorList(esElevatorDto.getAddress(),
esElevatorDto.getRegisterCode(),esElevatorDto.getRescueCode(),
esElevatorDto.getType(), !ValidationUtil.isEmpty(esElevatorDto.getDealStatus()) ? Integer.parseInt(esElevatorDto.getDealStatus()) :null
, esElevatorDto.getSequenceNbr(),(esElevatorDto.getPage()-1)*esElevatorDto.getSize(), esElevatorDto.getSize());
}
public List<ElevatorWlInfoDto> queryElevatorListDetails(ElevatorWlInfoDto esElevatorDto) {
return elevatorMapper.queryElevatorListDetails(esElevatorDto.getAddress(),
esElevatorDto.getRegisterCode(),esElevatorDto.getRescueCode(),
esElevatorDto.getType(), esElevatorDto.getDealStatus() != null ? Integer.parseInt(esElevatorDto.getDealStatus()) :null
, esElevatorDto.getSequenceNbr());
}
public int queryElevatorListCount() {
return elevatorMapper.queryElevatorListCount();
}
} }
package com.yeejoin.amos.boot.module.tzs.biz.service.impl;
import com.yeejoin.amos.boot.module.tzs.api.entity.ElevatorStatus;
import com.yeejoin.amos.boot.module.tzs.api.mapper.ElevatorStatusMapper;
import com.yeejoin.amos.boot.module.tzs.api.service.IElevatorStatusService;
import com.yeejoin.amos.boot.module.tzs.api.dto.ElevatorStatusDto;
import org.typroject.tyboot.core.rdbms.service.BaseService;
import org.springframework.stereotype.Service;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import java.util.List;
/**
* 服务实现类
*
* @author litw
* @date 2021-09-28
*/
@Service
public class ElevatorStatusServiceImpl extends BaseService<ElevatorStatusDto,ElevatorStatus,ElevatorStatusMapper> implements IElevatorStatusService {
/**
* 分页查询
*/
public Page<ElevatorStatusDto> queryForElevatorStatusPage(Page<ElevatorStatusDto> page) {
return this.queryForPage(page, null, false);
}
/**
* 列表查询 示例
*/
public List<ElevatorStatusDto> queryForElevatorStatusList() {
return this.queryForList("" , false);
}
}
\ No newline at end of file
package com.yeejoin.amos.boot.module.tzs.biz.service.impl; package com.yeejoin.amos.boot.module.tzs.biz.service.impl;
import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.yeejoin.amos.boot.biz.common.utils.DateUtils; import com.yeejoin.amos.boot.biz.common.utils.DateUtils;
import com.yeejoin.amos.boot.biz.common.utils.RedisUtils; import com.yeejoin.amos.boot.biz.common.utils.RedisUtils;
...@@ -19,12 +20,18 @@ import com.yeejoin.amos.boot.module.tzs.api.enums.TzsCommonParam; ...@@ -19,12 +20,18 @@ import com.yeejoin.amos.boot.module.tzs.api.enums.TzsCommonParam;
import com.yeejoin.amos.boot.module.tzs.api.mapper.RepairConsultMapper; import com.yeejoin.amos.boot.module.tzs.api.mapper.RepairConsultMapper;
import com.yeejoin.amos.boot.module.tzs.api.service.IRepairConsultService; import com.yeejoin.amos.boot.module.tzs.api.service.IRepairConsultService;
import com.yeejoin.amos.feign.privilege.model.AgencyUserModel; import com.yeejoin.amos.feign.privilege.model.AgencyUserModel;
import org.eclipse.paho.client.mqttv3.MqttException;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.annotation.Transactional;
import org.typroject.tyboot.component.emq.EmqKeeper;
import org.typroject.tyboot.core.rdbms.service.BaseService; import org.typroject.tyboot.core.rdbms.service.BaseService;
import org.typroject.tyboot.core.restful.exception.instance.BadRequest; import org.typroject.tyboot.core.restful.exception.instance.BadRequest;
import java.io.UnsupportedEncodingException;
import java.util.HashMap; import java.util.HashMap;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
...@@ -38,6 +45,7 @@ import java.util.Map; ...@@ -38,6 +45,7 @@ import java.util.Map;
@Service @Service
public class RepairConsultServiceImpl extends BaseService<RepairConsultDto,RepairConsult,RepairConsultMapper> implements IRepairConsultService { public class RepairConsultServiceImpl extends BaseService<RepairConsultDto,RepairConsult,RepairConsultMapper> implements IRepairConsultService {
private final Logger logger = LoggerFactory.getLogger(RepairConsultServiceImpl.class);
@Autowired @Autowired
TemplateServiceImpl templateServiceImpl; TemplateServiceImpl templateServiceImpl;
...@@ -56,6 +64,15 @@ public class RepairConsultServiceImpl extends BaseService<RepairConsultDto,Repai ...@@ -56,6 +64,15 @@ public class RepairConsultServiceImpl extends BaseService<RepairConsultDto,Repai
@Autowired @Autowired
RescueProcessServiceImpl rescueProcessServiceImpl; RescueProcessServiceImpl rescueProcessServiceImpl;
@Autowired
private EmqKeeper emqKeeper;
@Value("${mqtt.topic.alertHeart.push}")
private String alertHeartpushTopic;
@Value("${mqtt.topic.alertMatrix.push}")
private String alertMatrixpushTopic;
/** /**
* 记录处置日志同时修改案件的状态 * 记录处置日志同时修改案件的状态
* @param alertId * @param alertId
...@@ -250,6 +267,19 @@ public class RepairConsultServiceImpl extends BaseService<RepairConsultDto,Repai ...@@ -250,6 +267,19 @@ public class RepairConsultServiceImpl extends BaseService<RepairConsultDto,Repai
if(flag) { if(flag) {
// 记录处置记录后修改 案件状态 // 记录处置记录后修改 案件状态
alertCalledServiceImpl.updateAlertStage(alertCalledVo,CZHJ); alertCalledServiceImpl.updateAlertStage(alertCalledVo,CZHJ);
// 警情伤亡消息 矩阵 消息
JSONObject jsonObject = new JSONObject();
jsonObject.put("alertId",String.valueOf(alertCalledVo.getSequenceNbr()));
try {
emqKeeper.getMqttClient().publish(alertHeartpushTopic, jsonObject.toString().getBytes("UTF-8"), 1, false);
emqKeeper.getMqttClient().publish(alertMatrixpushTopic, jsonObject.toString().getBytes("UTF-8"), 1, false);
} catch (MqttException e) {
logger.error("mqtt发送失败" +jsonObject );
} catch (UnsupportedEncodingException e) {
logger.error("mqtt发送失败" +jsonObject );
}
} }
return flag; return flag;
} }
......
...@@ -180,6 +180,7 @@ ...@@ -180,6 +180,7 @@
p.name taskName, p.name taskName,
p.check_type_name checkTypeName, p.check_type_name checkTypeName,
P.check_type_id checkTypeId, P.check_type_id checkTypeId,
p.id planId,
pt.status, pt.status,
pt.user_id userId, pt.user_id userId,
date_format( date_format(
......
...@@ -18,4 +18,17 @@ ...@@ -18,4 +18,17 @@
where pp.id = #{pointId} where pp.id = #{pointId}
and pt.id = #{planTaskId} and pt.id = #{planTaskId}
</select> </select>
<update id="updateDanger">
UPDATE p_plan_task_detail pptd,
(SELECT SUM(pci.safety_danger_num) saf, SUM(pci.major_danger_num) maj, ptd.id FROM p_check_input pci
LEFT JOIN p_check pc ON pc.id = pci.check_id
LEFT JOIN p_plan_task_detail ptd ON ptd.id = pc.plan_task_detail_id
WHERE ptd.id = #{planTaskDetailId}) a
set
pptd.safety_danger_num = a.saf,
pptd.major_danger_num = a.maj
WHERE
pptd.id = a.id
</update>
</mapper> </mapper>
\ No newline at end of file
...@@ -1168,8 +1168,8 @@ ...@@ -1168,8 +1168,8 @@
LEFT JOIN p_check_input pci ON pci.route_point_item_id = ppi.id LEFT JOIN p_check_input pci ON pci.route_point_item_id = ppi.id
LEFT JOIN p_check_shot pcs ON pci.id = pcs.check_input_id LEFT JOIN p_check_shot pcs ON pci.id = pcs.check_input_id
WHERE WHERE
prp.route_id = #{routeId} AND pii.is_delete = 0 prp.route_id = #{routeId} AND prp.point_id = #{pointId} AND pii.is_delete = 0 AND
AND pci.input_value is NULL OR pci.input_value <![CDATA[<>]]> 'pass' ( pci.input_value is NULL OR pci.input_value <![CDATA[<>]]> 'pass')
GROUP BY ppi.id GROUP BY ppi.id
</select> </select>
......
...@@ -48,13 +48,18 @@ ...@@ -48,13 +48,18 @@
SELECT SELECT
COUNT(1) COUNT(1)
FROM FROM
(SELECT
COUNT(1)
FROM
p_route_point_item pi p_route_point_item pi
LEFT JOIN p_input_item i ON i.id = pi.input_item_id LEFT JOIN p_input_item i ON i.id = pi.input_item_id
<where> <where>
<if test="name!=null"> and i.name like concat(concat("%",#{name}),"%")</if> <if test="name!=null"> and i.name like concat(concat("%",#{name}),"%")</if>
<if test="planId!=null"> and pi.plan_id = #{planId} </if> <if test="planId!=null"> and pi.plan_id = #{planId} </if>
<!-- <if test="orgCode!=null"> and i.org_Code = #{orgCode}</if>--> <!-- <if test="orgCode!=null"> and i.org_Code = #{orgCode}</if>-->
</where> </where>
GROUP BY i.id
) a
</select> </select>
<!--查询 --> <!--查询 -->
<select id="queryPage" resultType="com.yeejoin.amos.supervision.business.vo.RoutePointItemVo"> <select id="queryPage" resultType="com.yeejoin.amos.supervision.business.vo.RoutePointItemVo">
...@@ -75,6 +80,7 @@ ...@@ -75,6 +80,7 @@
<if test="planId!=null"> and pi.plan_id = #{planId} </if> <if test="planId!=null"> and pi.plan_id = #{planId} </if>
<!-- <if test="orgCode!=null"> and i.org_Code = #{orgCode}</if>--> <!-- <if test="orgCode!=null"> and i.org_Code = #{orgCode}</if>-->
</where> </where>
GROUP BY i.id
<choose> <choose>
<when test="pageSize==-1"></when> <when test="pageSize==-1"></when>
<when test="pageSize!=-1">limit #{offset},#{pageSize}</when> <when test="pageSize!=-1">limit #{offset},#{pageSize}</when>
......
...@@ -55,11 +55,20 @@ tzs.wechat.ticketurl=https://api.weixin.qq.com/cgi-bin/ticket/getticket?access_t ...@@ -55,11 +55,20 @@ tzs.wechat.ticketurl=https://api.weixin.qq.com/cgi-bin/ticket/getticket?access_t
tzs.wechat.tempId.kr=Hlu43OOCVTESzOtkP4we1AUZJoPfquZl2_DEn6U66Z4 tzs.wechat.tempId.kr=Hlu43OOCVTESzOtkP4we1AUZJoPfquZl2_DEn6U66Z4
tzs.wechat.url.kr=tzs.yeeamos.com/persondetail.html tzs.wechat.url.kr=tzs.yeeamos.com/persondetail.html
tzs.wechat.tempId.wx=rags-expfNSBB-h2WenuBI2c6pCEndH4uwTtOqlHqDM tzs.wechat.tempId.wx=rags-expfNSBB-h2WenuBI2c6pCEndH4uwTtOqlHqDM
tzs.wechat.url.wx=tzs.yeeamos.com/persondetail.html tzs.wechat.url.wx=tzs.yeeamos.com/repairPersondetail.html
tzs.wechat.tempId.ts=SLjmNJoCNLC3FBcYzWzR-u3el0kqXf8WMTmzw8dAQm4 tzs.wechat.tempId.ts=SLjmNJoCNLC3FBcYzWzR-u3el0kqXf8WMTmzw8dAQm4
tzs.wechat.url.ts=tzs.yeeamos.com/persondetail.html tzs.wechat.url.ts=tzs.yeeamos.com/persondetail.html
mqtt.topic.task.newtask=tzs-task-newtask
mqtt.topic.task.personinfo=tzs-task-personinfo mqtt.topic.task.personinfo=tzs-task-personinfo
mqtt.topic.elevator.push=/tzs/tcb_elevator mqtt.topic.elevator.push=/tzs/tcb_elevator
\ No newline at end of file
mqtt.topic.alertInfo.push=/tzs/tcb_alertInfo
mqtt.topic.alertReport.push=/tzs/tcb_alertReport
mqtt.topic.alertHeart.push=/tzs/tcb_alertHeart
mqtt.topic.alertMatrix.push=/tzs/tcb_alertMatrix
\ No newline at end of file
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