| | |
| | | </select> |
| | | |
| | | <select id="selectEcOrderList" parameterType="org.springblade.modules.eCallEventTwo.dto.EcOrderDTO" resultMap="EcOrderDTOResult"> |
| | | <include refid="selectEcOrder"/> |
| | | SELECT |
| | | * |
| | | FROM ec_order |
| | | <where> |
| | | <if test="startTime != null and endTime != null">and eoc.callin_time BETWEEN #{startTime} AND #{endTime} |
| | | </if> |
| | | <if test="orderId != null "> and order_id = #{orderId}</if> |
| | | <if test="orderCode != null and orderCode != ''"> and order_code = #{orderCode}</if> |
| | | <if test="issueOrigin != null and issueOrigin != ''"> and issue_origin = #{issueOrigin}</if> |
| | |
| | | resultType="java.lang.Integer"> |
| | | SELECT |
| | | COUNT(DISTINCT(eo.order_id)) |
| | | FROM |
| | | ec_order_cti eoc |
| | | LEFT JOIN ec_order eo on eo.order_id= eoc.order_id |
| | | FROM ec_order eo |
| | | LEFT JOIN ec_dispatch ed ON eo.order_id = ed.order_id |
| | | LEFT JOIN ec_order_cti eoc on eoc.order_id = eo.order_id |
| | | <where> |
| | | <if test="tagMain != null and tagMain != ''">and ed.tag_main = #{tagMain}</if> |
| | | <if test="objectOrgCode != null and objectOrgCode != ''">and ed.object_org_code = #{objectOrgCode}</if> |
| | | <if test="subjectOrgCode != null and subjectOrgCode != ''">and ed.subject_org_code = #{subjectOrgCode}</if> |
| | | <if test="sinkOrgCode != null and sinkOrgCode != ''">and ed.sink_org_code = #{sinkOrgCode}</if> |
| | | <if test="startTime != null and endTime != null">and eoc.callin_time BETWEEN #{startTime} AND #{endTime} |
| | | </if> |
| | |
| | | <select id="selectEcDispatchCount" parameterType="org.springblade.modules.eCallEventTwo.dto.EcDispatchDTO" |
| | | resultType="java.lang.Integer"> |
| | | SELECT |
| | | COUNT( |
| | | DISTINCT ( eo.order_id )) |
| | | COUNT(1) |
| | | FROM |
| | | ec_dispatch ed |
| | | LEFT JOIN ec_order eo ON eo.order_id = ed.order_id |
| | | LEFT JOIN ec_order_cti eoc on eoc.order_id = eo.order_id |
| | | <where> |
| | | <if test="tagMain != null and tagMain != ''">and ed.tag_main = #{tagMain}</if> |
| | | <if test="objectOrgCode != null and objectOrgCode != ''">and ed.object_org_code = #{objectOrgCode}</if> |
| | | <if test="subjectOrgCode != null and subjectOrgCode != ''">and ed.subject_org_code = #{subjectOrgCode}</if> |
| | | <if test="sinkOrgCode != null and sinkOrgCode != ''">and ed.sink_org_code = #{sinkOrgCode}</if> |
| | | <if test="startTime != null and endTime != null">and ed.dispatch_time BETWEEN #{startTime} AND #{endTime} |
| | | </if> |
| | | |
| | | <if test="startTime != null and endTime != null">and eoc.callin_time BETWEEN #{startTime} AND #{endTime} |
| | | </if> |
| | | |
| | | <if test="dispatchId != null ">and dispatch_id = #{dispatchId}</if> |
| | | <if test="orderId != null ">and order_id = #{orderId}</if> |
| | |
| | | <select id="selectEcHandleCount" parameterType="org.springblade.modules.eCallEventTwo.dto.EcHandleDTO" |
| | | resultType="java.lang.Integer"> |
| | | SELECT |
| | | COUNT(DISTINCT(eo.order_id)) |
| | | COUNT(DISTINCT(ehd.uid)) |
| | | FROM |
| | | ec_handle eh |
| | | LEFT JOIN ec_order eo on eh.order_id = eo.order_id |
| | | ec_handle_doing ehd |
| | | LEFT JOIN ec_handle eh ON ehd.order_id = eh.order_id |
| | | LEFT JOIN ec_order eo ON eh.order_id = eo.order_id |
| | | LEFT JOIN ec_dispatch ed ON eo.order_id = ed.order_id |
| | | LEFT JOIN ec_order_cti eoc on eoc.order_id = eo.order_id |
| | | <where> |
| | | |
| | | <if test="tagMain != null and tagMain != ''">and ed.tag_main = #{tagMain}</if> |
| | | <if test="objectOrgCode != null and objectOrgCode != ''">and ed.object_org_code = #{objectOrgCode}</if> |
| | | <if test="subjectOrgCode != null and subjectOrgCode != ''">and ed.subject_org_code = #{subjectOrgCode}</if> |
| | | <if test="sinkOrgCode != null and sinkOrgCode != ''">and ed.sink_org_code = #{sinkOrgCode}</if> |
| | | <if test="startTime != null and endTime != null">and eh.remote_hdl_time BETWEEN #{startTime} AND |
| | | <if test="startTime != null and endTime != null">and ehd.biz_time BETWEEN #{startTime} AND |
| | | #{endTime} |
| | | </if> |
| | | |
| | | <if test="startTime != null and endTime != null">and eoc.callin_time BETWEEN #{startTime} AND #{endTime} |
| | | </if> |
| | | |
| | | <if test="handleId != null ">and handle_id = #{handleId}</if> |
| | | <if test="orderId != null ">and order_id = #{orderId}</if> |
| | |
| | | <select id="selectEcOrderCheckCount" parameterType="org.springblade.modules.eCallEventTwo.dto.EcOrderCheckDTO" |
| | | resultType="java.lang.Integer"> |
| | | SELECT |
| | | COUNT(DISTINCT(eo.order_id)) |
| | | COUNT( |
| | | DISTINCT ( eoct.uid )) |
| | | FROM |
| | | ec_order_check eoc |
| | | LEFT JOIN ec_order eo on eoc.order_id = eo.order_id |
| | | ec_order_check_tel eoct |
| | | LEFT JOIN ec_order_check eoc ON eoct.order_id = eoc.order_id |
| | | LEFT JOIN ec_order eo ON eoc.order_id = eo.order_id |
| | | LEFT JOIN ec_dispatch ed ON eo.order_id = ed.order_id |
| | | LEFT JOIN ec_order_check_tel eoct on eoct.order_id = eo.order_id |
| | | LEFT JOIN ec_order_cti eoci on eoci.order_id = eo.order_id |
| | | <where> |
| | | |
| | | <if test="tagMain != null and tagMain != ''">and ed.tag_main = #{tagMain}</if> |
| | | <if test="objectOrgCode != null and objectOrgCode != ''">and ed.object_org_code = #{objectOrgCode}</if> |
| | | <if test="subjectOrgCode != null and subjectOrgCode != ''">and ed.subject_org_code = #{subjectOrgCode}</if> |
| | | <if test="sinkOrgCode != null and sinkOrgCode != ''">and ed.sink_org_code = #{sinkOrgCode}</if> |
| | | <if test="startTime != null and endTime != null">and eoct.chk_time BETWEEN #{startTime} AND #{endTime}</if> |
| | | |
| | | <if test="startTime != null and endTime != null">and eoci.callin_time BETWEEN #{startTime} AND #{endTime} |
| | | </if> |
| | | |
| | | <if test="orderId != null ">and order_id = #{orderId}</if> |
| | | <if test="checkCode != null and checkCode != ''">and check_code = #{checkCode}</if> |
| | |
| | | <select id="selectEcOrderDoneCount" parameterType="org.springblade.modules.eCallEventTwo.dto.EcOrderDoneDTO" |
| | | resultType="java.lang.Integer"> |
| | | SELECT |
| | | COUNT(DISTINCT(eo.order_id)) |
| | | COUNT( |
| | | DISTINCT ( eodl.uid )) |
| | | FROM |
| | | ec_order_done eod |
| | | LEFT JOIN ec_order eo on eod.order_id = eo.order_id |
| | | ec_order_done_log eodl |
| | | LEFT JOIN ec_order_done eod ON eod.order_id = eodl.order_id |
| | | LEFT JOIN ec_order eo ON eod.order_id = eo.order_id |
| | | LEFT JOIN ec_dispatch ed ON eo.order_id = ed.order_id |
| | | LEFT JOIN ec_order_cti eoc on eoc.order_id = eo.order_id |
| | | <where> |
| | | <if test="tagMain != null and tagMain != ''">and ed.tag_main = #{tagMain}</if> |
| | | <if test="objectOrgCode != null and objectOrgCode != ''">and ed.object_org_code = #{objectOrgCode}</if> |
| | | <if test="subjectOrgCode != null and subjectOrgCode != ''">and ed.subject_org_code = #{subjectOrgCode}</if> |
| | | <if test="sinkOrgCode != null and sinkOrgCode != ''">and ed.sink_org_code = #{sinkOrgCode}</if> |
| | | <if test="startTime != null and endTime != null">and eod.first_done_apply_time BETWEEN #{startTime} AND |
| | | <if test="startTime != null and endTime != null">and eodl.in_audit_time BETWEEN #{startTime} AND |
| | | #{endTime} |
| | | </if> |
| | | |
| | | <if test="startTime != null and endTime != null">and eoc.callin_time BETWEEN #{startTime} AND #{endTime} |
| | | </if> |
| | | |
| | | <if test="orderId != null ">and order_id = #{orderId}</if> |
| | | <if test="doneCode != null and doneCode != ''">and done_code = #{doneCode}</if> |
| | |
| | | <select id="selectEcOrderRespCount" parameterType="org.springblade.modules.eCallEventTwo.dto.EcOrderRespDTO" |
| | | resultType="java.lang.Integer"> |
| | | SELECT |
| | | COUNT(DISTINCT(eo.order_id)) |
| | | COUNT( |
| | | DISTINCT ( eorl.uid )) |
| | | FROM |
| | | ec_order_resp eor |
| | | LEFT JOIN ec_order eo on eor.order_id = eo.order_id |
| | | ec_order_resp_log eorl |
| | | LEFT JOIN ec_order_resp eor ON eorl.order_id = eor.order_id |
| | | LEFT JOIN ec_order eo ON eor.order_id = eo.order_id |
| | | LEFT JOIN ec_dispatch ed ON eo.order_id = ed.order_id |
| | | LEFT JOIN ec_order_resp_log eorl on eorl.order_id = eor.order_id |
| | | LEFT JOIN ec_order_cti eoc on eoc.order_id = eo.order_id |
| | | <where> |
| | | |
| | | <if test="tagMain != null and tagMain != ''">and ed.tag_main = #{tagMain}</if> |
| | | <if test="objectOrgCode != null and objectOrgCode != ''">and ed.object_org_code = #{objectOrgCode}</if> |
| | | <if test="subjectOrgCode != null and subjectOrgCode != ''">and ed.subject_org_code = #{subjectOrgCode}</if> |
| | | <if test="sinkOrgCode != null and sinkOrgCode != ''">and ed.sink_org_code = #{sinkOrgCode}</if> |
| | | <if test="startTime != null and endTime != null">and eorl.resp_time BETWEEN #{startTime} AND #{endTime}</if> |
| | | <if test="startTime != null and endTime != null">and eorl.audit_time BETWEEN #{startTime} AND #{endTime} |
| | | </if> |
| | | <if test="startTime != null and endTime != null">and eoc.callin_time BETWEEN #{startTime} AND #{endTime} |
| | | </if> |
| | | |
| | | <if test="orderId != null ">and order_id = #{orderId}</if> |
| | | <if test="respCode != null and respCode != ''">and resp_code = #{respCode}</if> |
| | |
| | | ec_order_review eor |
| | | LEFT JOIN ec_order eo on eor.order_id = eo.order_id |
| | | LEFT JOIN ec_dispatch ed ON eo.order_id = ed.order_id |
| | | LEFT JOIN ec_order_cti eoc on eoc.order_id = eo.order_id |
| | | <where> |
| | | |
| | | <if test="tagMain != null and tagMain != ''">and ed.tag_main = #{tagMain}</if> |
| | | <if test="objectOrgCode != null and objectOrgCode != ''">and ed.object_org_code = #{objectOrgCode}</if> |
| | | <if test="subjectOrgCode != null and subjectOrgCode != ''">and ed.subject_org_code = #{subjectOrgCode}</if> |
| | | <if test="sinkOrgCode != null and sinkOrgCode != ''">and ed.sink_org_code = #{sinkOrgCode}</if> |
| | | <if test="startTime != null and endTime != null">and eor.review_time BETWEEN #{startTime} AND #{endTime} |
| | | </if> |
| | | <if test="startTime != null and endTime != null">and eoc.callin_time BETWEEN #{startTime} AND #{endTime} |
| | | </if> |
| | | |
| | | |
| | |
| | | ec_order_supervise eos |
| | | LEFT JOIN ec_order eo on eos.order_id = eo.order_id |
| | | LEFT JOIN ec_dispatch ed ON eo.order_id = ed.order_id |
| | | LEFT JOIN ec_order_cti eoc on eoc.order_id = eo.order_id |
| | | <where> |
| | | |
| | | <if test="tagMain != null and tagMain != ''">and ed.tag_main = #{tagMain}</if> |
| | | <if test="objectOrgCode != null and objectOrgCode != ''">and ed.object_org_code = #{objectOrgCode}</if> |
| | | <if test="subjectOrgCode != null and subjectOrgCode != ''">and ed.subject_org_code = #{subjectOrgCode}</if> |
| | | <if test="sinkOrgCode != null and sinkOrgCode != ''">and ed.sink_org_code = #{sinkOrgCode}</if> |
| | | <if test="startTime != null and endTime != null">and eos.supervise_time BETWEEN #{startTime} AND |
| | | #{endTime} |
| | | </if> |
| | | <if test="startTime != null and endTime != null">and eoc.callin_time BETWEEN #{startTime} AND #{endTime} |
| | | </if> |
| | | |
| | | |
| | |
| | | </where> |
| | | </select> |
| | | |
| | | |
| | | <select id="getUnitAssessmentIndicators" resultType="java.util.Map"> |
| | | select * |
| | | from `v_statistics_examine_2` |
| | | |
| | | </select> |
| | | |
| | | |
| | | <select id="getOrgCode" resultType="org.springblade.modules.eCallEventTwo.dto.EcOrderDTO"> |
| | | SELECT |
| | | ed.subject_org_code,ed.subject_org_name,ed.sink_org_code,ed.sink_org_name |
| | | FROM |
| | | ec_order eo |
| | | LEFT JOIN ec_dispatch ed ON eo.order_id = ed.order_id |
| | | LEFT JOIN ec_order_cti eoc ON eoc.order_id = eo.order_id |
| | | <where> |
| | | <if test="ecOrderParamDTO.tagMain != null and ecOrderParamDTO.tagMain != '' "> |
| | | and ed.tag_main = #{ecOrderParamDTO.tagMain} |
| | | <if test="ecOrderParamDTO.mainFlag != null and ecOrderParamDTO.mainFlag == 2"> |
| | | <if test="ecOrderParamDTO.subjectOrgName != null and ecOrderParamDTO.subjectOrgName != ''"> |
| | | and ed.subject_org_name like concat('%',#{ecOrderParamDTO.subjectOrgName},'%') |
| | | </if> |
| | | GROUP BY ed.subject_org_code |
| | | </if> |
| | | <if test="ecOrderParamDTO.mainFlag != null and ecOrderParamDTO.mainFlag == 1"> |
| | | <if test="ecOrderParamDTO.sinkOrgName != null and ecOrderParamDTO.sinkOrgName != ''"> |
| | | and ed.sink_org_name like concat('%',#{ecOrderParamDTO.sinkOrgName},'%') |
| | | </if> |
| | | GROUP BY ed.sink_org_code |
| | | </if> |
| | | |
| | | </if> |
| | | </where> |
| | | |
| | | |
| | | </select> |
| | | |
| | | </mapper> |