select relation_device_detail_id,relation_device_id,device_name,device_model,iot_no,remarks, (CASE device_type WHEN '1' THEN '压力表' WHEN '2' THEN '流量计' end) as device_type
select relation_device_detail_id,detection_medium,relation_device_id,device_name,device_model,iot_no,remarks, (CASE device_type WHEN '1' THEN '压力表' WHEN '2' THEN '流量计' WHEN '3' THEN '探测器' end) as device_type
from t_relation_device_detail_info where is_del='0' and relation_device_id is null
from t_relation_device_detail_info where is_del='0' and relation_device_id is null
<iftest="deviceName != null and deviceName != ''"> and device_name like concat('%', #{deviceName}, '%')</if>
<iftest="deviceName != null and deviceName != ''"> and device_name like concat('%', #{deviceName}, '%')</if>
<iftest="deviceModel != null and deviceModel != ''"> and device_model like concat('%', #{deviceModel}, '%')</if>
<iftest="deviceModel != null and deviceModel != ''"> and device_model like concat('%', #{deviceModel}, '%')</if>
...
@@ -175,7 +176,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
...
@@ -175,7 +176,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
select relation_device_detail_id,relation_device_id,device_name,device_model,iot_no,remarks, (CASE device_type WHEN '1' THEN '压力表' WHEN '2' THEN '流量计' end) as device_type
select relation_device_detail_id,detection_medium,relation_device_id,device_name,device_model,iot_no,remarks, (CASE device_type WHEN '1' THEN '压力表' WHEN '2' THEN '流量计' WHEN '3' THEN '探测器' end) as device_type
from t_relation_device_detail_info where relation_device_id=#{id} and relation_device_type=#{relationDeviceType}
from t_relation_device_detail_info where relation_device_id=#{id} and relation_device_type=#{relationDeviceType}