| | |
| | | <result column="addType" property="addType"/> |
| | | <result column="addObjectId" property="addObjectId"/> |
| | | </resultMap> |
| | | |
| | | <update id="updateUseState"> |
| | | update t_car set useDriverId = null where useDriverId = #{uid} |
| | | </update> |
| | | |
| | | |
| | | <select id="queryIdleData" resultType="map"> |
| | |
| | | addObjectId as addObjectId |
| | | from t_car where state = 1 and carLicensePlate = #{licensePlate} |
| | | </select> |
| | | <select id="queryIdleDataFromId" resultType="java.util.Map"> |
| | | select |
| | | a.id as id, |
| | | CONCAT(a.carLicensePlate, '-',c.`name`, b.`name`, ' ', a.carColor) as name, |
| | | a.useDriverId as useDriverId |
| | | from t_car a |
| | | left join t_car_model b on (a.carModelId = b.id) |
| | | left join t_car_brand c on (b.brandId = c.id) |
| | | where a.state = 1 and find_in_set(#{id},a.bindDriverId) |
| | | </select> |
| | | </mapper> |