12345678910111213141516171819202122232425262728293031323334353637 |
- <?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.huiju.estateagents.mapper.TaOrgCityMapper">
- <select id="selectByIdCity" resultType="string">
- select city_id from ta_org_city where parentid != 100000 and org_id = #{orgId}
- </select>
-
- <select id="selectAdminTdCityList" resultType="com.huiju.estateagents.entity.TaOrgCity">
- SELECT
- oc.city_id AS id,
- oc.`name` AS name,
- oc.org_id,
- oc.`status`,
- oc.parentid,
- LEFT (c.pinyin, 1) AS initial
- FROM
- ta_org_city oc
- LEFT JOIN td_city c ON oc.city_id = c.id
- WHERE
- oc.org_id = #{orgId}
- and oc.parentid !=100000
- and oc.status = 1
- ORDER BY
- c.pinyin
- </select>
- <select id="selectAdminTdAreaCityList" resultType="com.huiju.estateagents.entity.TaOrgCity">
- SELECT
- id,
- NAME,
- parentid,
- LEFT ( pinyin, 1 ) AS initial
- FROM
- td_city
- WHERE
- parentid = #{cityId}
- </select>
- </mapper>
|