Commit c160f1cc authored by 王果's avatar 王果

28180 移装告知业务改为批量提交批量审批

parent a716f697
...@@ -25,23 +25,10 @@ ...@@ -25,23 +25,10 @@
tjtn.create_user_id as createUserId, tjtn.create_user_id as createUserId,
tjtn.next_execute_user_ids as nextExecuteUserIds, tjtn.next_execute_user_ids as nextExecuteUserIds,
tjtn.next_task_id AS nextTaskId, tjtn.next_task_id AS nextTaskId,
ibjui."ADDRESS" as detailedAddress,
ri.EQU_CODE AS equCode,
oi.CODE96333 as code96333,
oi.SUPERVISORY_CODE AS supervisoryCode,
DATE_FORMAT(tjtn.notice_date,'%Y-%m-%d') AS noticeDate, DATE_FORMAT(tjtn.notice_date,'%Y-%m-%d') AS noticeDate,
DATE_FORMAT(tjtn.handle_date,'%Y-%m-%d') AS handleDate, DATE_FORMAT(tjtn.handle_date,'%Y-%m-%d') AS handleDate,
DATE_FORMAT(tjtn.plan_date,'%Y-%m-%d') AS planDate, DATE_FORMAT(tjtn.plan_date,'%Y-%m-%d') AS planDate
(SELECT name from tz_equipment_category ec WHERE ec.code = ri.EQU_LIST) AS equList, FROM tzs_jg_transfer_notice tjtn
(select name from tz_equipment_category ec WHERE ec.code = ri.EQU_DEFINE) AS equDefine,
(select ec."name" from tz_equipment_category ec WHERE ec.code = ri.equ_category) AS equipCateName,
concat(ibjui."PROVINCE_NAME", '', ibjui."CITY_NAME", '', ibjui."COUNTY_NAME", '', ibjui."STREET_NAME") as equAddress
FROM
tzs_jg_transfer_notice tjtn
LEFT JOIN tzs_jg_transfer_notice_eq re ON re.equip_transfer_id = tjtn.sequence_nbr
LEFT JOIN idx_biz_jg_register_info ri ON ri.record = re.equ_id
LEFT JOIN idx_biz_jg_use_info ibjui on ibjui.RECORD = re.equ_id
LEFT JOIN idx_biz_jg_other_info oi ON oi.RECORD = re.equ_id
<where> <where>
tjtn.is_delete = false tjtn.is_delete = false
<if test="param != null "> <if test="param != null ">
...@@ -66,38 +53,12 @@ ...@@ -66,38 +53,12 @@
<if test="param.transferType != null and param.transferType != '' and param.transferType == '10003'"> <if test="param.transferType != null and param.transferType != '' and param.transferType == '10003'">
AND tjtn.transfer_type = '跨区移装' AND tjtn.transfer_type = '跨区移装'
</if> </if>
<if test="param.equList != null and param.equList != ''">
AND ri."EQU_LIST" = #{param.equList}
</if>
<if test="param.equCategory != null and param.equCategory != ''">
AND ri."equ_category" = #{param.equCategory}
</if>
<if test="param.equDefine != null and param.equDefine != ''">
AND ri."EQU_DEFINE" = #{param.equDefine}
</if>
<if test="param.equCode != null and param.equCode != ''">
AND ri."EQU_CODE" like concat('%',#{param.equCode},'%')
</if>
<if test="param.informNumber != null and param.informNumber != ''"> <if test="param.informNumber != null and param.informNumber != ''">
AND tjtn.inform_number like concat('%',#{param.informNumber},'%') AND tjtn.inform_number like concat('%',#{param.informNumber},'%')
</if> </if>
<if test="param.code96333 != null and param.code96333 != ''">
AND oi.CODE96333 like concat('%',#{param.code96333},'%')
</if>
<if test="param.supervisoryCode != null and param.supervisoryCode != ''">
AND oi.SUPERVISORY_CODE like concat('%',#{param.supervisoryCode},'%')
</if>
<if test="param.noticeDate != null"> <if test="param.noticeDate != null">
AND tjtn.notice_date LIKE CONCAT('%', DATE_FORMAT(#{param.noticeDate},'%Y-%m-%d'), '%') AND tjtn.notice_date LIKE CONCAT('%', DATE_FORMAT(#{param.noticeDate},'%Y-%m-%d'), '%')
</if> </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 test="param.useUnitCreditCode != null and param.useUnitCreditCode != ''"> <if test="param.useUnitCreditCode != null and param.useUnitCreditCode != ''">
AND tjtn."use_unit_credit_code" = #{param.useUnitCreditCode} AND tjtn."use_unit_credit_code" = #{param.useUnitCreditCode}
</if> </if>
......
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