| | |
| | | </select> |
| | | |
| | | |
| | | <select id="queryIdleData1" resultType="map"> |
| | | select |
| | | a.id as id, |
| | | CONCAT(a.carLicensePlate, '-',c.`name`, b.`name`, ' ', a.carColor) as name |
| | | 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 a.createBy = #{driverId} |
| | | <choose> |
| | | <when test="companyId != 1"> |
| | | and a.companyId = #{companyId} or a.franchiseeId = #{companyId} |
| | | </when> |
| | | <otherwise> |
| | | and a.isPlatCar = 1 |
| | | </otherwise> |
| | | |
| | | </choose> |
| | | </select> |
| | | |
| | | |
| | | <select id="query" resultType="com.stylefeng.guns.modular.system.model.Car"> |
| | | select |
| | | id as id, |