InstitutionCQuery.xml 1011 B

1234567891011121314151617181920
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  3. <mapper namespace="com.hz.employmentsite.mapper.cquery.InstitutionCQuery">
  4. <select id="getList" resultType="com.hz.employmentsite.vo.baseSettings.InstitutionModel">
  5. select A.*,Count(B.szkey)as SiteCount from pc_institution A,pc_site_institution B where A.szkey = B.szinstitutionkey and 1=1
  6. <if test="primaryKey!='' and primaryKey!=null">
  7. and szkey in (${primaryKey})
  8. </if>
  9. <if test="companyName!='' and companyName!=null">
  10. and szcompanyname like Concat('%',#{companyName},'%')
  11. </if>
  12. <if test="companyAddress!='' and companyAddress!=null">
  13. and szcomaddress like Concat('%',#{companyAddress},'%')
  14. </if>
  15. <if test="dutyUserName!='' and dutyUserName!=null">
  16. and szcomusername like Concat('%',#{dutyUserName},'%')
  17. </if>
  18. </select>
  19. </mapper>