<?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.nuvole.four.mapper.ChannelOrgConfigMapper">
|
|
<select id="selectAllList" parameterType="com.nuvole.four.domain.dto.ChannelOrgConfigDto"
|
resultType="com.nuvole.four.domain.dto.ChannelOrgConfigDto">
|
SELECT so.id orgId,so.name orgName,so.org_code orgCode,so.pid pId,coc.update_time updateTime,IFNULL(count(coc.id),0) configCount FROM sys_org so LEFT JOIN channel_org_config coc ON coc.org_id = so.id
|
<where>
|
so.state = 1
|
<if test="orgName != null and orgName != '' ">
|
and so.name like CONCAT(CONCAT('%',#{orgName},'%'))
|
</if>
|
<if test="orgId != null">
|
and so.pid = #{orgId}
|
</if>
|
</where>
|
GROUP BY so.id order by sort_no
|
</select>
|
|
<select id="selectAll" parameterType="com.nuvole.four.domain.ChannelOrgConfig"
|
resultType="com.nuvole.four.domain.ChannelOrgConfig">
|
select
|
<include refid="Base_Column_List"></include>
|
from channel_info
|
<where>
|
<if test="orgId != null">
|
and org_id = #{orgId}
|
</if>
|
</where>
|
</select>
|
|
</mapper>
|