改正BUG
This commit is contained in:
parent
e3f1005e9a
commit
e2d4ed4771
|
|
@ -79,6 +79,7 @@
|
|||
a.old_server_url ,
|
||||
a.sync_type
|
||||
from nu_iot_tq_electricity_meter a
|
||||
left join nu_iot_tq_collector b on a.cid = b.cid
|
||||
</select>
|
||||
|
||||
<select id="getElectricityMeter" parameterType="com.nu.modules.tq.electricity.entity.ElectricityMeter" resultType="com.nu.modules.tq.electricity.entity.ElectricityMeter">
|
||||
|
|
|
|||
|
|
@ -65,19 +65,19 @@ public class DeviceMaintainServiceImpl extends ServiceImpl<DeviceMaintainMapper,
|
|||
di.setRemark(remark);
|
||||
di.setUpdateDate(updateDate);
|
||||
updateDeviceByType(di);
|
||||
QueryWrapper<DeviceMaintain> qw = new QueryWrapper<>();
|
||||
qw.eq("device_id",di.getDeviceId());
|
||||
DeviceMaintain entity = this.getOne(qw);
|
||||
if(entity!=null){
|
||||
entity.setReserveDepartId(reserveDepartId);
|
||||
entity.setReserveDepartName(reserveDepartName);
|
||||
entity.setRemark(remark);
|
||||
entity.setUpdateDate(updateDate);
|
||||
this.updateById(entity);
|
||||
}else{
|
||||
// QueryWrapper<DeviceMaintain> qw = new QueryWrapper<>();
|
||||
// qw.eq("device_id",di.getDeviceId());
|
||||
// DeviceMaintain entity = this.getOne(qw);
|
||||
// if(entity!=null){
|
||||
// entity.setReserveDepartId(reserveDepartId);
|
||||
// entity.setReserveDepartName(reserveDepartName);
|
||||
// entity.setRemark(remark);
|
||||
// entity.setUpdateDate(updateDate);
|
||||
// this.updateById(entity);
|
||||
// }else{
|
||||
di.setId(null);
|
||||
this.save(di);
|
||||
}
|
||||
// }
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue