zss
2023-08-22 c427ed3db05c772cec3658949e19bcf1b6c0d2a7
inspection-server/src/main/resources/mapper/InspectionProductMapper.xml
@@ -37,4 +37,22 @@
        where state = 1
          and test_state is null
    </select>
    <!--获取检验项目,设备,检验开始时间,执行人,检验结束时间-->
    <select id="getResultNum" resultType="java.util.Map">
        select ip.name,
               equipment_name                      instrumentname,
               DATE_FORMAT(start_time, '%Y-%m-%d') startTime,
               user.name                           checkname,
               DATE_FORMAT(end_time, '%Y-%m-%d')   endTime
        from lims_laboratory.inspection_product ip
                 left join lims_laboratory.inspection_material on ip.inspection_material_id = inspection_material.id
                 left join lims_laboratory.inspection i on inspection_material.inspection_id = i.id
                 left join lims_laboratory.instrument on ip.instrument_id = instrument.id
                 left join lims_laboratory.user on ip.user_id = user.id
        where ip.state = 1
          and test_state is null
        order by start_time
        limit 4
    </select>
</mapper>