| | |
| | | <result column="default_value" property="defaultValue" /> |
| | | </resultMap> |
| | | <select id="selectListByProductId" resultType="com.ruoyi.quality.pojo.QualityTestStandardParam"> |
| | | select t1.* from quality_test_standard_param t1 |
| | | left join quality_test_standard t2 on t1.test_standard_id = t2.id |
| | | left join quality_test_standard_binding t3 on t2.id = t3.test_standard_id |
| | | select distinct t1.* from quality_test_standard_param t1 |
| | | inner join quality_test_standard t2 on t1.test_standard_id = t2.id |
| | | inner join quality_test_standard_binding t3 on t2.id = t3.test_standard_id |
| | | left join product_process pp on t2.process_id = pp.id |
| | | where t3.product_id = #{productId} |
| | | <if test="inspectType != null"> |
| | | and t2.inspect_type = #{inspectType} |
| | | </if> |
| | | <if test="process != null and process != ''"> |
| | | and pp.name = #{process} |
| | | </if> |
| | | order by t1.id desc |
| | | </select> |
| | | |
| | | <select id="selectPageByProductId" resultType="com.ruoyi.quality.pojo.QualityTestStandardParam"> |
| | | select distinct t1.* from quality_test_standard_param t1 |
| | | inner join quality_test_standard t2 on t1.test_standard_id = t2.id |
| | | inner join quality_test_standard_binding t3 on t1.test_standard_id = t3.test_standard_id |
| | | where t3.product_id = #{productId} |
| | | <if test="inspectType != null"> |
| | | and t2.inspect_type = #{inspectType} |
| | | </if> |
| | | <if test="processId != null"> |
| | | and t2.process_id = #{processId} |
| | | </if> |
| | | order by t1.id desc |
| | | </select> |
| | | |
| | | </mapper> |