liyong
5 小时以前 1ca5584d7e3200a9af65a099bd26d3593e2ba702
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
<?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.ruoyi.technology.mapper.TechnologyOperationParamMapper">
 
    <!-- 通用查询映射结果 -->
    <resultMap id="BaseResultMap" type="com.ruoyi.technology.pojo.TechnologyOperationParam">
        <id column="id" property="id" />
        <result column="technology_param_id" property="technologyParamId" />
        <result column="technology_operation_id" property="technologyOperationId" />
        <result column="standard_value" property="standardValue" />
    </resultMap>
 
    <select id="listOperationParam" resultType="com.ruoyi.technology.bean.vo.TechnologyOperationParamVo">
        select top1.*,
               tp.param_code as paramCode,
               tp.param_name as paramName,
               tp.param_type as paramType,
               tp.param_format as paramFormat,
               tp.unit,
               tp.is_required as isRequired
        from technology_operation_param top1
        left join technology_param tp on top1.technology_param_id = tp.id
        <where>
            <if test="technologyOperationId != null">
                and top1.technology_operation_id = #{technologyOperationId}
            </if>
            <if test="paramId != null">
                and top1.technology_param_id = #{paramId}
            </if>
        </where>
        order by top1.id asc
    </select>
</mapper>