Browse Source

Merge branch 'feature_v1.0' into develop

tags/v1.0.2
chengwang 1 year ago
parent
commit
0ce8ee6e1f
3 changed files with 105 additions and 0 deletions
  1. +7
    -0
      tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/entity/dto/AirportDetailDto.java
  2. +83
    -0
      tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/entity/dto/MountEquipment.java
  3. +15
    -0
      tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/service/third/airport/GetAirportDetailService.java

+ 7
- 0
tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/entity/dto/AirportDetailDto.java View File

import lombok.NoArgsConstructor; import lombok.NoArgsConstructor;
import lombok.experimental.Accessors; import lombok.experimental.Accessors;


import java.util.List;

/** /**
* @author chenjiandong * @author chenjiandong
* @description: TODO * @description: TODO
*/ */
private String mountName; private String mountName;


/**
* 挂载
*/
private List<MountEquipment> mountEquipmentList;

/** /**
* 降雨量 * 降雨量
*/ */

+ 83
- 0
tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/entity/dto/MountEquipment.java View File

package com.tuoheng.admin.entity.dto;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;

/**
* @Author ChengWang
* @Date 2023/7/17
*/
@Data
@AllArgsConstructor
@NoArgsConstructor
@Accessors(chain = true)
public class MountEquipment {
/**
* id
*/
private Integer id;
/**
* 创建时间
*/
private String createTime;
/**
* 创建人
*/
private Integer createUser;
/**
* 更新人
*/
private Integer updateUser;
/**
* 更新时间
*/
private String updateTime;
/**
* 标识
*/
private Integer mark;
/**
* 租户id
*/
private Integer tenantId;
/**
* 类型
*/
private Integer type;
/**
*
*/
private Integer series;
/**
* 编码
*/
private String code;
/**
* 名称
*/
private String name;
/**
* 图片
*/
private String image;
/**
*
*/
private String zoomFactor;
/**
*
*/
private String imaging;
/**
*
*/
private String manufacturer;
/**
* 状态
*/
private Integer status;


}

+ 15
- 0
tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/service/third/airport/GetAirportDetailService.java View File

package com.tuoheng.admin.service.third.airport; package com.tuoheng.admin.service.third.airport;


import cn.hutool.core.util.ObjectUtil;
import com.alibaba.fastjson.JSONObject; import com.alibaba.fastjson.JSONObject;
import com.tuoheng.admin.entity.dto.AirportDetailDto; import com.tuoheng.admin.entity.dto.AirportDetailDto;
import com.tuoheng.admin.entity.dto.MountEquipment;
import com.tuoheng.common.core.config.common.CommonConfig; import com.tuoheng.common.core.config.common.CommonConfig;
import com.tuoheng.common.core.utils.HttpUtils; import com.tuoheng.common.core.utils.HttpUtils;
import com.tuoheng.common.core.utils.JacksonUtil; import com.tuoheng.common.core.utils.JacksonUtil;
import com.tuoheng.common.core.utils.JsonResult; import com.tuoheng.common.core.utils.JsonResult;
import com.tuoheng.common.core.utils.StringUtils;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;



import java.util.List;
import java.util.Objects; import java.util.Objects;


/** /**
mountJson.getString("searchlightName") mountJson.getString("searchlightName")
); );
} }
JSONObject metJson = dataObject.getJSONObject("mountEquipmentList");
if(ObjectUtil.isNotNull(metJson)){
//json-->string
String mountEquipmentList = metJson.toJSONString();
if(StringUtils.isNotEmpty(mountEquipmentList)){
List<MountEquipment> mountEquipments = JSONObject.parseArray(mountEquipmentList, MountEquipment.class);
vo.setMountEquipmentList(mountEquipments);
}

}
vo.setStatus(dataObject.getString("status")); vo.setStatus(dataObject.getString("status"));
return JsonResult.success(vo); return JsonResult.success(vo);
} }

Loading…
Cancel
Save