Commit dbe0081b authored by 麻笑宇's avatar 麻笑宇

Merge remote-tracking branch 'origin/develop_tzs_register_to_0715' into…

Merge remote-tracking branch 'origin/develop_tzs_register_to_0715' into develop_tzs_register_to_0715
parents 023cb216 4b4afe68
...@@ -307,5 +307,16 @@ public class JgInstallationNoticeDto extends BaseDto { ...@@ -307,5 +307,16 @@ public class JgInstallationNoticeDto extends BaseDto {
@ApiModelProperty(value = "作废日期") @ApiModelProperty(value = "作废日期")
private Date cancelDate; private Date cancelDate;
/**
* 冗余设备类别
*/
private String equCategoryCode;
/**
* 工程装置
*/
private String projectContraption;
/**
* 冗余设备种类
*/
private String equListCode;
} }
...@@ -471,4 +471,20 @@ public class JgInstallationNotice extends BaseEntity { ...@@ -471,4 +471,20 @@ public class JgInstallationNotice extends BaseEntity {
*/ */
@TableField("cancel_user_id") @TableField("cancel_user_id")
private String cancelUserId; private String cancelUserId;
/**
* 冗余设备类别
*/
@TableField("equ_category_code")
private String equCategoryCode;
/**
* 工程装置
*/
@TableField("project_contraption")
private String projectContraption;
/**
* 冗余设备种类
*/
@TableField("equ_list_code")
private String equListCode;
} }
...@@ -34,4 +34,21 @@ public class JgInstallationNoticeEq extends BaseEntity { ...@@ -34,4 +34,21 @@ public class JgInstallationNoticeEq extends BaseEntity {
@TableField("equ_id") @TableField("equ_id")
private String equId; private String equId;
/**
* 告知单编号
*/
@TableField("inform_number")
private String informNumber;
/**
* 设备类别
*/
@TableField("equ_category_code")
private String equCategoryCode;
/**
* 设备种类
*/
@TableField("equ_list_code")
private String equListCode;
} }
...@@ -84,4 +84,6 @@ public interface IJgInstallationNoticeService extends IService<JgInstallationNot ...@@ -84,4 +84,6 @@ public interface IJgInstallationNoticeService extends IService<JgInstallationNot
* @return JgInstallationNoticeDto * @return JgInstallationNoticeDto
*/ */
JgInstallationNotice cancelApplication(Long sequenceNbr, String cancelReason); JgInstallationNotice cancelApplication(Long sequenceNbr, String cancelReason);
Boolean historyDataRepair();
} }
...@@ -24,23 +24,14 @@ ...@@ -24,23 +24,14 @@
isn.next_execute_ids AS nextExecuteIds, isn.next_execute_ids AS nextExecuteIds,
isn.instance_status AS instanceStatus, isn.instance_status AS instanceStatus,
DATE_FORMAT(isn.handle_date,'%Y-%m-%d') AS handleDate, DATE_FORMAT(isn.handle_date,'%Y-%m-%d') AS handleDate,
other.CODE96333 AS code96333,
(select name from tz_equipment_category ec WHERE ec.code = ri.equ_category) AS equList,
isn.notice_report_url AS noticeReportUrl, isn.notice_report_url AS noticeReportUrl,
isn.create_user_id as createUserId, isn.create_user_id as createUserId,
isn.next_task_id AS nextTaskId, isn.next_task_id AS nextTaskId,
isn.next_execute_user_ids as nextExecuteUserIds, isn.next_execute_user_ids as nextExecuteUserIds,
ri.EQU_CODE AS equCode, (SELECT name from tz_equipment_category where code = isn.equ_list_code) AS equListName,
(select name from tz_equipment_category ec WHERE ec.code = ri.EQU_DEFINE) AS equDefine, (SELECT name from tz_equipment_category where code = isn.equ_category_code) AS equList,
(SELECT name from tz_equipment_category where code = ri.EQU_LIST) AS equListName,
concat(ibjui."PROVINCE_NAME", '', ibjui."CITY_NAME", '', ibjui."COUNTY_NAME", '', ibjui."STREET_NAME") as equAddress,
ibjui."ADDRESS" as detailedAddress,
isn.cancel_reason as cancelReason isn.cancel_reason as cancelReason
FROM tzs_jg_installation_notice isn FROM tzs_jg_installation_notice isn
LEFT JOIN tzs_jg_installation_notice_eq insEq on insEq.equip_transfer_id = isn.sequence_nbr
LEFT JOIN idx_biz_jg_use_info ibjui on insEq.equ_id = ibjui.RECORD
LEFT JOIN idx_biz_jg_register_info ri ON ri.record = insEq.equ_id
LEFT JOIN idx_biz_jg_other_info other on other.RECORD = insEq.equ_id
<where> <where>
isn.is_delete = false isn.is_delete = false
<if test="param != null "> <if test="param != null ">
...@@ -65,28 +56,11 @@ ...@@ -65,28 +56,11 @@
<if test="param.supervisoryCode != null and param.supervisoryCode != ''"> <if test="param.supervisoryCode != null and param.supervisoryCode != ''">
AND isn."supervisory_code" LIKE concat('%',#{param.supervisoryCode},'%') AND isn."supervisory_code" LIKE concat('%',#{param.supervisoryCode},'%')
</if> </if>
<if test="param.code96333 != null and param.code96333 != ''">
AND other."CODE96333" LIKE concat('%',#{param.code96333},'%')
</if>
<if test="param.equCode != null and param.equCode != ''">
AND ri."EQU_CODE" LIKE concat('%',#{param.equCode},'%')
</if>
<if test="param.equList != null and param.equList != ''"> <if test="param.equList != null and param.equList != ''">
AND ri."EQU_LIST" = #{param.equList} AND isn."equ_list_code" = #{param.equList}
</if> </if>
<if test="param.equipCategory != null and param.equipCategory != ''"> <if test="param.equipCategory != null and param.equipCategory != ''">
AND ri."equ_category" = #{param.equipCategory} AND isn."equ_category_code" = #{param.equipCategory}
</if>
<if test="param.equDefine != null and param.equDefine != ''">
AND ri."EQU_DEFINE" = #{param.equDefine}
</if>
<if test="param.equAddress != null and param.equAddress != ''">
AND (
ibjui."PROVINCE_NAME" LIKE CONCAT('%', #{param.equAddress}, '%')
OR ibjui."CITY_NAME" LIKE CONCAT('%', #{param.equAddress}, '%')
OR ibjui."COUNTY_NAME" LIKE CONCAT('%', #{param.equAddress}, '%')
OR ibjui."STREET_NAME" LIKE CONCAT('%', #{param.equAddress}, '%')
)
</if> </if>
<if test="param.useUnitCreditCode != null and param.useUnitCreditCode != ''"> <if test="param.useUnitCreditCode != null and param.useUnitCreditCode != ''">
AND isn.use_unit_credit_code = #{param.useUnitCreditCode} AND isn.use_unit_credit_code = #{param.useUnitCreditCode}
...@@ -129,7 +103,7 @@ ...@@ -129,7 +103,7 @@
isn.install_leader_name AS installLeaderName, isn.install_leader_name AS installLeaderName,
isn.install_leader_phone AS installLeaderPhone, isn.install_leader_phone AS installLeaderPhone,
isn.use_unit_name AS useUnitName, isn.use_unit_name AS useUnitName,
isn.inform_number AS informNumber,
isn.other_accessories AS otherAccessories, isn.other_accessories AS otherAccessories,
tec2.name AS equCategory, tec2.name AS equCategory,
tec1.name AS equList, tec1.name AS equList,
...@@ -168,6 +142,7 @@ ...@@ -168,6 +142,7 @@
useUnit.address as useUnitLeaderAddress, useUnit.address as useUnitLeaderAddress,
re.equ_id as equId, re.equ_id as equId,
installUnit.address installUnitAddress, installUnit.address installUnitAddress,
re.inform_number informNumber,
(select idi.INSPECT_REPORT from idx_biz_jg_inspection_detection_info idi Where idi.record = re.equ_id ORDER BY idi.INSPECT_DATE desc LIMIT 1) as inspectReport (select idi.INSPECT_REPORT from idx_biz_jg_inspection_detection_info idi Where idi.record = re.equ_id ORDER BY idi.INSPECT_DATE desc LIMIT 1) as inspectReport
FROM FROM
tzs_jg_installation_notice isn tzs_jg_installation_notice isn
...@@ -181,7 +156,7 @@ ...@@ -181,7 +156,7 @@
LEFT JOIN amos_tzs_biz.tz_equipment_category tec1 ON ri."EQU_LIST"::text = tec1.code::text LEFT JOIN amos_tzs_biz.tz_equipment_category tec1 ON ri."EQU_LIST"::text = tec1.code::text
LEFT JOIN amos_tzs_biz.tz_equipment_category tec2 ON ri."EQU_DEFINE"::text = tec2.code::text LEFT JOIN amos_tzs_biz.tz_equipment_category tec2 ON ri."EQU_DEFINE"::text = tec2.code::text
WHERE WHERE
isn.sequence_nbr = #{sequenceNbr} re.sequence_nbr = #{sequenceNbr}
LIMIT 1 LIMIT 1
</select> </select>
<select id="queryForFlowingEquipList" resultType="com.yeejoin.amos.boot.module.jg.api.dto.CompanyEquipCountDto"> <select id="queryForFlowingEquipList" resultType="com.yeejoin.amos.boot.module.jg.api.dto.CompanyEquipCountDto">
......
...@@ -17,6 +17,7 @@ import io.swagger.annotations.ApiParam; ...@@ -17,6 +17,7 @@ import io.swagger.annotations.ApiParam;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
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.restful.doc.TycloudOperation; import org.typroject.tyboot.core.restful.doc.TycloudOperation;
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;
...@@ -66,7 +67,7 @@ public class JgInstallationNoticeController extends BaseController { ...@@ -66,7 +67,7 @@ public class JgInstallationNoticeController extends BaseController {
@ApiOperation(httpMethod = "PUT", value = "根据sequenceNbr更新安装告知", notes = "根据sequenceNbr更新安装告知") @ApiOperation(httpMethod = "PUT", value = "根据sequenceNbr更新安装告知", notes = "根据sequenceNbr更新安装告知")
public ResponseModel<JgInstallationNoticeDto> updateBySequenceNbrJgInstallationNotice(@RequestParam String submitType, @RequestBody Map<String, Object> model, @RequestParam(value = "op", required = false) String op) { public ResponseModel<JgInstallationNoticeDto> updateBySequenceNbrJgInstallationNotice(@RequestParam String submitType, @RequestBody Map<String, Object> model, @RequestParam(value = "op", required = false) String op) {
JgInstallationNoticeDto installationInfo = BeanUtil.mapToBean(((LinkedHashMap) model.get("installationInfo")), JgInstallationNoticeDto.class, true); JgInstallationNoticeDto installationInfo = BeanUtil.mapToBean(((LinkedHashMap) model.get("installationInfo")), JgInstallationNoticeDto.class, true);
installationInfo.setEquList(((LinkedHashMap<?, ?>) model.get("installationInfo")).get("equListDesc").toString()); // installationInfo.setEquList(((LinkedHashMap<?, ?>) model.get("installationInfo")).get("equListDesc").toString());
if (Objects.isNull(installationInfo)) { if (Objects.isNull(installationInfo)) {
throw new IllegalArgumentException("参数installationInfo不能为空"); throw new IllegalArgumentException("参数installationInfo不能为空");
} }
...@@ -169,4 +170,12 @@ public class JgInstallationNoticeController extends BaseController { ...@@ -169,4 +170,12 @@ public class JgInstallationNoticeController extends BaseController {
} }
@TycloudOperation(ApiLevel = UserType.AGENCY)
@ApiOperation(httpMethod = "GET", value = "安装告知历史数据修复", notes = "安装告知历史数据修复")
@GetMapping(value = "/historyDataRepair")
public ResponseModel<Boolean> historyDataRepair() {
return ResponseHelper.buildResponse(iJgInstallationNoticeService.historyDataRepair());
}
} }
...@@ -1886,7 +1886,7 @@ ...@@ -1886,7 +1886,7 @@
</w:r> </w:r>
</w:p> </w:p>
</w:tc> </w:tc>
<#if installLicenseNoList?size == 0> <#if equipList.installLicenseNoList?size == 0>
<w:tc> <w:tc>
<w:tcPr> <w:tcPr>
<w:tcW w:w="809" w:type="pct"/> <w:tcW w:w="809" w:type="pct"/>
...@@ -1931,7 +1931,7 @@ ...@@ -1931,7 +1931,7 @@
</w:p> </w:p>
</w:tc> </w:tc>
</#if> </#if>
<#if installLicenseNoList?size == 1> <#if equipList.installLicenseNoList?size == 1>
<w:tc> <w:tc>
<w:tcPr> <w:tcPr>
<w:tcW w:w="809" w:type="pct"/> <w:tcW w:w="809" w:type="pct"/>
...@@ -1978,7 +1978,7 @@ ...@@ -1978,7 +1978,7 @@
</w:p> </w:p>
</w:tc> </w:tc>
</#if> </#if>
<#if installLicenseNoList?size == 2> <#if equipList.installLicenseNoList?size == 2>
<w:tc> <w:tc>
<w:tcPr> <w:tcPr>
<w:tcW w:w="809" w:type="pct"/> <w:tcW w:w="809" w:type="pct"/>
...@@ -2095,7 +2095,7 @@ ...@@ -2095,7 +2095,7 @@
</w:tc> </w:tc>
</#if> </#if>
<#if installLicenseNoList?size == 3> <#if equipList.installLicenseNoList?size == 3>
<w:tc> <w:tc>
<w:tcPr> <w:tcPr>
<w:tcW w:w="809" w:type="pct"/> <w:tcW w:w="809" w:type="pct"/>
...@@ -2128,7 +2128,7 @@ ...@@ -2128,7 +2128,7 @@
<w:gridCol w:w="1645"/> <w:gridCol w:w="1645"/>
</w:tblGrid> </w:tblGrid>
<#list installLicenseNoList as item> <#list equipList.installLicenseNoList as item>
<w:tr> <w:tr>
<w:tblPrEx> <w:tblPrEx>
<w:tblBorders> <w:tblBorders>
...@@ -2257,7 +2257,7 @@ ...@@ -2257,7 +2257,7 @@
</w:r> </w:r>
</w:p> </w:p>
</w:tc> </w:tc>
<#if installLicenseExpirationDateList?size == 0> <#if equipList.installLicenseExpirationDateList?size == 0>
<w:tc> <w:tc>
<w:tcPr> <w:tcPr>
<w:tcW w:w="1119" w:type="pct"/> <w:tcW w:w="1119" w:type="pct"/>
...@@ -2305,7 +2305,7 @@ ...@@ -2305,7 +2305,7 @@
</#if> </#if>
<#if installLicenseExpirationDateList?size == 1> <#if equipList.installLicenseExpirationDateList?size == 1>
<w:tc> <w:tc>
<w:tcPr> <w:tcPr>
<w:tcW w:w="1119" w:type="pct"/> <w:tcW w:w="1119" w:type="pct"/>
...@@ -2355,7 +2355,7 @@ ...@@ -2355,7 +2355,7 @@
</#if> </#if>
<#if installLicenseExpirationDateList?size == 2> <#if equipList.installLicenseExpirationDateList?size == 2>
<w:tc> <w:tc>
<w:tcPr> <w:tcPr>
<w:tcW w:w="1119" w:type="pct"/> <w:tcW w:w="1119" w:type="pct"/>
...@@ -2388,7 +2388,7 @@ ...@@ -2388,7 +2388,7 @@
<w:gridCol w:w="1340"/> <w:gridCol w:w="1340"/>
</w:tblGrid> </w:tblGrid>
<#list installLicenseExpirationDateList as item1> <#list equipList.installLicenseExpirationDateList as item1>
<w:tr> <w:tr>
<w:tblPrEx> <w:tblPrEx>
<w:tblBorders> <w:tblBorders>
...@@ -2478,7 +2478,7 @@ ...@@ -2478,7 +2478,7 @@
</#if> </#if>
<#if installLicenseExpirationDateList?size == 3> <#if equipList.installLicenseExpirationDateList?size == 3>
<w:tc> <w:tc>
<w:tcPr> <w:tcPr>
<w:tcW w:w="1119" w:type="pct"/> <w:tcW w:w="1119" w:type="pct"/>
...@@ -2510,7 +2510,7 @@ ...@@ -2510,7 +2510,7 @@
<w:tblGrid> <w:tblGrid>
<w:gridCol w:w="1349"/> <w:gridCol w:w="1349"/>
</w:tblGrid> </w:tblGrid>
<#list installLicenseExpirationDateList as item1> <#list equipList.installLicenseExpirationDateList as item1>
<w:tr> <w:tr>
<w:tblPrEx> <w:tblPrEx>
<w:tblBorders> <w:tblBorders>
......
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