| | |
| | | <result column="dept_id" property="deptId" /> |
| | | </resultMap> |
| | | |
| | | <select id="listPage" resultType="com.ruoyi.technology.bean.vo.TechnologyBomVo"> |
| | | select tb.*, |
| | | pm.model as productModelName, |
| | | p.product_name as productName |
| | | from technology_bom tb |
| | | left join product_model pm on tb.product_model_id = pm.id |
| | | left join product p on pm.product_id = p.id |
| | | <where> |
| | | <if test="c.productModelName != null and c.productModelName != ''"> |
| | | and pm.model like concat('%', #{c.productModelName}, '%') |
| | | </if> |
| | | <if test="c.productName != null and c.productName != ''"> |
| | | and p.product_name like concat('%', #{c.productName}, '%') |
| | | </if> |
| | | <if test="c.bomNo != null and c.bomNo != ''"> |
| | | and tb.bom_no like concat('%', #{c.bomNo}, '%') |
| | | </if> |
| | | <if test="c.version != null and c.version != ''"> |
| | | and tb.version = #{c.version} |
| | | </if> |
| | | </where> |
| | | order by tb.id desc |
| | | </select> |
| | | </mapper> |