rev:修改路由路线更新设备类型
This commit is contained in:
@@ -108,7 +108,6 @@ public class RouteLineServiceImpl extends CommonServiceImpl<RouteLineMapper, Rou
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
public RouteLineDto findById(String id) {
|
||||
return ConvertUtil.convert(getById(id), RouteLineDto.class);
|
||||
}
|
||||
@@ -351,20 +350,20 @@ public class RouteLineServiceImpl extends CommonServiceImpl<RouteLineMapper, Rou
|
||||
if (entity == null) {
|
||||
throw new BadRequestException(LangProcess.msg("error_sysAuth"));
|
||||
}
|
||||
|
||||
DeviceDto startDevice = deviceService.findByCode(dto.getDevice_code());
|
||||
DeviceDto nextDevice = deviceService.findByCode(dto.getNext_device_code());
|
||||
if (startDevice != null) {
|
||||
dto.setStart_device_type(startDevice.getDevice_type());
|
||||
}
|
||||
if (nextDevice != null) {
|
||||
dto.setNext_device_type(nextDevice.getDevice_type());
|
||||
}
|
||||
String currentUsername = SecurityUtils.getCurrentUsername();
|
||||
String now = DateUtil.now();
|
||||
dto.setUpdate_time(now);
|
||||
dto.setUpdate_by(currentUsername);
|
||||
|
||||
// WQLObject wo = WQLObject.getWQLObject("acs_route_line");
|
||||
// JSONObject json = (JSONObject) JSONObject.toJSON(dto);
|
||||
//
|
||||
// wo.update(json);
|
||||
|
||||
RouteLine routeLine = ConvertUtil.convert(dto, RouteLine.class);
|
||||
routeLineMapper.updateById(routeLine);
|
||||
|
||||
reload();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user