Browse Source

修改创建航线代码

tags/v1.0.4^2
wanjing 10 months ago
parent
commit
a14f21b511
1 changed files with 4 additions and 2 deletions
  1. +4
    -2
      tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/service/airportline/add/AddAirportLineService.java

+ 4
- 2
tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/service/airportline/add/AddAirportLineService.java View File

//Integer lineId = (Integer) data.get("id"); //Integer lineId = (Integer) data.get("id");
JSONObject dataObject = (JSONObject) JSONObject.toJSON(result.getData()); JSONObject dataObject = (JSONObject) JSONObject.toJSON(result.getData());
Integer lineId = null; Integer lineId = null;
Integer airlineFileId = null;
if(Objects.nonNull(dataObject)){ if(Objects.nonNull(dataObject)){
lineId = dataObject.getInteger("id"); lineId = dataObject.getInteger("id");
log.info("航线id为:lineId={}",lineId);
airlineFileId = dataObject.getInteger("airlineFileId");
log.info("航线id为:lineId={}, airlineFileId={}", lineId, airlineFileId);
} }


//属性赋值 //属性赋值
AirportLine airportLine = new AirportLine(); AirportLine airportLine = new AirportLine();
airportLine.setTenantId(tenantId); airportLine.setTenantId(tenantId);
airportLine.setInspectionLineId(lineId);
airportLine.setInspectionLineId(airlineFileId);
airportLine.setAirportLineName(airportLineName); airportLine.setAirportLineName(airportLineName);
airportLine.setCreateTime(DateUtils.now()); airportLine.setCreateTime(DateUtils.now());
airportLine.setCreateUser(user.getId()); airportLine.setCreateUser(user.getId());

Loading…
Cancel
Save