RuleTreeNodeLine_Mapper.xml 1.1 KB
Newer Older
1 2
<?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">
A
atsuc 已提交
3
<mapper namespace="cn.atsuc.frame.infrastructure.dao.RuleTreeNodeLineDao">
4

A
atsuc 已提交
5
    <resultMap id="ruleTreeNodeLineResultMap" type="cn.atsuc.frame.infrastructure.po.RuleTreeNodeLinePO">
6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
        <id column="id" property="id"/>
        <result column="tree_id" property="treeId"/>
        <result column="node_id_from" property="nodeIdFrom"/>
        <result column="node_id_to" property="nodeIdTo"/>
        <result column="rule_limit_type" property="ruleLimitType"/>
        <result column="rule_limit_value" property="ruleLimitValue"/>
    </resultMap>

    <select id="queryRuleTreeNodeLineList" resultMap="ruleTreeNodeLineResultMap">
        SELECT id, tree_id, node_id_from, node_id_to, rule_limit_type, rule_limit_value
        FROM rule_tree_node_line
        where tree_id = #{treeId} and node_id_from = #{nodeIdFrom}
    </select>

    <select id="queryTreeNodeLineCount" resultType="java.lang.Integer">
        select count(id) from rule_tree_node_line where tree_id = #{treeId}
    </select>

</mapper>