版本文件
前缀字段
This commit is contained in:
parent
d29c85c600
commit
6d08137305
|
@ -209,6 +209,7 @@ public class AppController extends BaseController
|
|||
@PostMapping(value = "/bandDevice")
|
||||
public AjaxResult bandDevice(@RequestBody AsDevice asDevice)
|
||||
{
|
||||
logger.info("接收到绑定设备请求:【{}】",JSON.toJSON(asDevice));
|
||||
return success(asDeviceService.bandDevice(asDevice));
|
||||
}
|
||||
//
|
||||
|
|
|
@ -40,12 +40,15 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
<result property="modeStr" column="mode_str" />
|
||||
<result property="bluetoothId" column="bluetooth_id" />
|
||||
<result property="bluetoothName" column="bluetooth_name" />
|
||||
<result property="pre" column="pre" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectAsDeviceVo">
|
||||
select device_id, picture, device_name, classify_id, classify_name, model_id, model, mac, activation_time, online_status,
|
||||
user_id, user_name, nick_name, regular_watering, soil_moisture_open, soil_moisture_close, water_intensity, pulse_mode,
|
||||
pulse_mode_param, screen_rest_time, version, version_id, create_by, create_time, update_by, update_time, remark, regular_watering_json, soil_moisture, water_intensity_switch,is_network,is_default,mode_str,bluetooth_id,bluetooth_name from as_device
|
||||
pulse_mode_param, screen_rest_time, version, version_id, create_by, create_time, update_by, update_time, remark,
|
||||
regular_watering_json, soil_moisture, water_intensity_switch,is_network,is_default,mode_str,bluetooth_id,bluetooth_name, pre
|
||||
from as_device
|
||||
</sql>
|
||||
|
||||
<select id="selectAsDeviceList" parameterType="AsDevice" resultMap="AsDeviceResult">
|
||||
|
@ -120,6 +123,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
<if test="regularWateringJson != null">regular_watering_json,</if>
|
||||
<if test="soilMoisture != null">soil_moisture,</if>
|
||||
<if test="waterIntensitySwitch != null">water_intensity_switch</if>
|
||||
<if test="pre != null">pre,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="picture != null">#{picture},</if>
|
||||
|
@ -151,6 +155,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
<if test="regularWateringJson != null">#{regularWateringJson},</if>
|
||||
<if test="soilMoisture != null">#{soilMoisture},</if>
|
||||
<if test="waterIntensitySwitch != null">#{waterIntensitySwitch}</if>
|
||||
<if test="pre != null">#{pre},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
|
@ -192,6 +197,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
<if test="modeStr != null">mode_str = #{modeStr},</if>
|
||||
<if test="bluetoothId != null">bluetooth_id = #{bluetoothId},</if>
|
||||
<if test="bluetoothName != null">bluetooth_name = #{bluetoothName}</if>
|
||||
<if test="pre != null">pre = #{pre}</if>
|
||||
</trim>
|
||||
where device_id = #{deviceId}
|
||||
</update>
|
||||
|
@ -231,6 +237,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
<if test="isNetwork != null">is_network = #{isNetwork},</if>
|
||||
<if test="isDefault != null">is_default = #{isDefault},</if>
|
||||
<if test="modeStr != null">mode_str = #{modeStr}</if>
|
||||
<if test="bluetoothId != null">bluetooth_id = #{bluetoothId}</if>
|
||||
<if test="bluetoothName != null">bluetooth_name = #{bluetoothName}</if>
|
||||
<if test="pre != null">pre = #{pre}</if>
|
||||
</trim>
|
||||
where mac = #{mac}
|
||||
</update>
|
||||
|
|
Loading…
Reference in New Issue
Block a user