| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960 |
- <?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="platform.modules.government.dao.ProjectProvincesDeclarationDao">
- <select id="findPageInfo" resultType="platform.modules.government.entity.ProjectProvincesDeclaration">
- SELECT * FROM project_provinces_declaration d
- LEFT JOIN project_service_type t ON t.id = d.project_service_type
- WHERE 1=1
- AND d.del_flag = 0
- <if test="projectName != null and projectName != '' ">
- AND d.project_name LIKE CONCAT ('%',#{projectName},'%')
- </if>
- <if test="projectType != null and projectType != '' ">
- AND t.service_type_name LIKE CONCAT ('%',#{projectType},'%')
- </if>
- <if test="projectSource != null and projectSource != '' ">
- AND d.project_source = #{projectSource}
- </if>
- ORDER BY d.create_time DESC
- </select>
- <select id="selectById" resultType="platform.modules.government.entity.ProjectProvincesDeclaration">
- select * from project_provinces_declaration where id = #{id}
- </select>
- <select id="findProvincesPageInfo" resultType="platform.modules.government.entity.ProjectProvincesDeclaration">
- SELECT * FROM project_provinces_declaration d
- inner JOIN project_service_type t ON t.id = d.project_service_type and t.del_flag = 0
- where d.del_flag = 0 and d.status = 1
- <if test="projectName != null and projectName != '' ">
- AND d.project_name LIKE CONCAT ('%',#{projectName},'%')
- </if>
- <if test="projectType != null and projectType != '' ">
- AND t.service_type_name LIKE CONCAT ('%',#{projectType},'%')
- </if>
- <if test="projectSource != null and projectSource != '' ">
- AND d.project_source = #{projectSource}
- </if>
- ORDER BY d.create_time DESC
- </select>
- <select id="findAll" resultType="platform.modules.government.entity.ProjectProvincesDeclaration">
- SELECT
- p.*
- FROM
- project_provinces_declaration p
- inner join project_service_type t on p.project_service_type = t.id and t.del_flag = 0
- WHERE p.status = 1
- <if test="searchCondition.begin_date != null and searchCondition.begin_date != ''">
- AND p.release_date <![CDATA[>=]]> #{searchCondition.begin_date}
- </if>
- <if test="searchCondition.end_date != null and searchCondition.end_date != ''">
- AND p.release_date <![CDATA[<=]]> #{searchCondition.end_date}
- </if>
- </select>
- </mapper>
|