济菏高速数据中心代码
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

44 lines
1.5 KiB

<?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.zc.business.mapper.DcSwitchMapper">
<resultMap type="DcSwitch" id="DcSwitch">
<result property="switchId" column="switch_id"/>
<result property="parentId" column="parent_id"/>
<result property="ancestors" column="ancestors"/>
<result property="switchName" column="switch_name"/>
<result property="stakeMark" column="stake_mark"/>
<result property="deviceList" column="device_list"/>
<result property="switchIp" column="switch_ip"/>
<result property="userState" column="user_state"/>
<result property="stakeMark" column="stake_mark"/>
<result property="createTime" column="create_time"/>
<result property="updateTime" column="update_time"/>
</resultMap>
<sql id="selectDcSwitchVo">
select switch_id,
parent_id,
ancestors,
switch_name,
stake_mark,
device_list,
switch_ip,
user_state,
create_time,
update_time
from dc_switch
</sql>
<select id="getSwitchList" parameterType="DcSwitch" resultType="DcSwitch">
<include refid="selectDcSwitchVo"/>
<where>
<if test="parentId != null ">and parent_id = #{parentId}</if>
</where>
and user_state = 1
</select>
</mapper>