政策重点认证事业部 风险项入库
This commit is contained in:
@@ -0,0 +1,120 @@
|
||||
<?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.adc.da.slrs.sarIssueTrack.dao.IssueTrackDao">
|
||||
|
||||
<resultMap id="IssueTrackPage" type="com.adc.da.slrs.sarIssueTrack.entity.IssueTrack">
|
||||
<result property="id" column="ID"/>
|
||||
<result property="lawId" column="law_id"/>
|
||||
<result property="dataSource" column="data_source"/>
|
||||
<result property="lawCode" column="law_code"/>
|
||||
<result property="lawName" column="law_name"/>
|
||||
<result property="productType" column="product_type"/>
|
||||
<result property="implTime" column="impl_time"/>
|
||||
<result property="implRequire" column="impl_require"/>
|
||||
|
||||
|
||||
</resultMap>
|
||||
|
||||
<sql id="issueColumn">
|
||||
issue.id,data_source,law_id,product_type,impl_time,impl_require
|
||||
</sql>
|
||||
|
||||
<select id="findPage" resultMap="IssueTrackPage" parameterType="com.adc.da.slrs.sarIssueTrack.entity.IssueTrackVo">
|
||||
(
|
||||
SELECT
|
||||
CONCAT(
|
||||
sarInfo.STAND_SORT,
|
||||
' ',
|
||||
sarInfo.STAND_NUMBER,
|
||||
'-',
|
||||
sarInfo.STAND_YEAR
|
||||
) AS law_code,
|
||||
sarInfo.STAND_NAME AS law_name,
|
||||
<include refid="issueColumn"/>
|
||||
FROM
|
||||
issue_track AS issue
|
||||
JOIN sar_standards_info AS sarInfo ON sarInfo.ID = issue.law_id
|
||||
|
||||
<where>
|
||||
del_flag=0
|
||||
|
||||
<if test="pageVo.lawCode != null and pageVo.lawCode != ''">
|
||||
trim(replace(CONCAT(
|
||||
sarInfo.STAND_SORT,
|
||||
' ',
|
||||
sarInfo.STAND_NUMBER,
|
||||
'-',
|
||||
sarInfo.STAND_YEAR
|
||||
),' ','')) LIKE trim(replace(CONCAT('%',#{pageVo.lawCode},'%'),' ',''))
|
||||
</if>
|
||||
|
||||
|
||||
|
||||
<if test="pageVo.lawName != null and pageVo.lawName != ''">
|
||||
sarInfo.STAND_NAME LIKE CONCAT('%',#{pageVo.lawName},'%')
|
||||
</if>
|
||||
|
||||
|
||||
<if test="pageVo.productType != null and pageVo.productType != ''">
|
||||
issue.product_type LIKE CONCAT('%',#{pageVo.productType},'%')
|
||||
</if>
|
||||
|
||||
</where>
|
||||
|
||||
) UNION ALL (
|
||||
SELECT
|
||||
sarInfo.LAWS_NUMBER AS law_code,
|
||||
sarInfo.LAWS_NAME AS law_name,
|
||||
<include refid="issueColumn"/>
|
||||
FROM
|
||||
issue_track AS issue
|
||||
JOIN sar_laws_stand_info AS sarInfo ON sarInfo.ID = issue.law_id
|
||||
<where>
|
||||
del_flag=0
|
||||
|
||||
<if test="pageVo.lawCode != null and pageVo.lawCode != ''">
|
||||
sarInfo.LAWS_NUMBER LIKE CONCAT('%',#{pageVo.lawCode},'%')
|
||||
</if>
|
||||
|
||||
<if test="pageVo.lawName != null and pageVo.lawName != ''">
|
||||
sarInfo.LAWS_NAME LIKE CONCAT('%',#{pageVo.lawName},'%')
|
||||
</if>
|
||||
|
||||
<if test="pageVo.productType != null and pageVo.productType != ''">
|
||||
issue.product_type LIKE CONCAT('%',#{pageVo.productType},'%')
|
||||
</if>
|
||||
</where>
|
||||
|
||||
|
||||
) UNION ALL (
|
||||
SELECT
|
||||
sarInfo.STAND_CODE AS law_code,
|
||||
sarInfo.STAND_NAME AS law_name,
|
||||
<include refid="issueColumn"/>
|
||||
FROM
|
||||
issue_track AS issue
|
||||
JOIN sar_bussioness_stand AS sarInfo ON sarInfo.ID = issue.law_id
|
||||
|
||||
|
||||
<where>
|
||||
del_flag=0
|
||||
|
||||
<if test="pageVo.lawCode != null and pageVo.lawCode != ''">
|
||||
sarInfo.STAND_CODE LIKE CONCAT('%',#{pageVo.lawCode},'%')
|
||||
</if>
|
||||
|
||||
<if test="pageVo.lawName != null and pageVo.lawName != ''">
|
||||
sarInfo.STAND_NAME LIKE CONCAT('%',#{pageVo.lawName},'%')
|
||||
</if>
|
||||
|
||||
<if test="pageVo.productType != null and pageVo.productType != ''">
|
||||
issue.product_type LIKE CONCAT('%',#{pageVo.productType},'%')
|
||||
</if>
|
||||
|
||||
</where>
|
||||
|
||||
|
||||
)
|
||||
|
||||
</select>
|
||||
</mapper>
|
||||
Reference in New Issue
Block a user