update 电单车协议

This commit is contained in:
Guoqs
2024-09-20 09:00:45 +08:00
parent 9a2af549d8
commit d08ee877f6
7 changed files with 112 additions and 28 deletions

View File

@@ -419,4 +419,32 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
id desc
limit 1
</select>
<select id="selectPileDetailByPileSn" resultType="com.jsowell.pile.vo.web.PileDetailVO">
SELECT
t1.id as pileId,
t1.sn AS pileSn,
t1.name as name,
t1.merchant_id AS merchantId,
t2.merchant_name AS merchantName,
t1.station_id AS stationId,
t3.station_name AS stationName,
t1.model_id AS modelId,
t4.rated_power AS ratedPower,
t4.rated_current AS ratedCurrent,
t1.sim_id AS simId,
t5.iccid AS iccid ,
t5.sim_supplier as simSupplier,
IF(t4.charger_pile_type = '2','3',(IF(t4.speed_type = '1','1','2'))) AS pileType,
t5.operator
FROM
pile_basic_info t1
left JOIN pile_merchant_info t2 ON t1.merchant_id = t2.id
left JOIN pile_station_info t3 ON t1.station_id = t3.id
left JOIN pile_model_info t4 ON t1.model_id = t4.id
left JOIN pile_sim_info t5 ON t1.sim_id = t5.id
WHERE
t1.del_flag = '0'
and t1.sn = #{pileSn,jdbcType=VARCHAR}
</select>
</mapper>