Ver código fonte

Merge branch 'develop' into release

tags/V1.2.1^2
wanghaoran 1 ano atrás
pai
commit
f718de7d5f
7 arquivos alterados com 28 adições e 22 exclusões
  1. +17
    -7
      tuoheng-admin/src/main/java/com/tuoheng/admin/config/SystemConstant.java
  2. +2
    -6
      tuoheng-admin/src/main/java/com/tuoheng/admin/service/impl/IndexServiceImpl.java
  3. +5
    -5
      tuoheng-admin/src/main/java/com/tuoheng/admin/service/impl/ThInspectionServiceImpl.java
  4. +1
    -1
      tuoheng-admin/src/main/resources/application-dev.yml
  5. +1
    -1
      tuoheng-admin/src/main/resources/application-local.yml
  6. +1
    -1
      tuoheng-admin/src/main/resources/application-prod.yml
  7. +1
    -1
      tuoheng-admin/src/main/resources/application-test.yml

+ 17
- 7
tuoheng-admin/src/main/java/com/tuoheng/admin/config/SystemConstant.java Ver arquivo

@@ -10,22 +10,22 @@ public interface SystemConstant {
/**
* 机场平台:获取机场列表接口
*/
String API_AIRPORT_LIST = "/api/airportInterface/airportList";
String API_AIRPORT_LIST = "/airportInterface/airportList";

/**
* 机场平台:获取机场路线列表接口
*/
String API_AIRPORT_LINE_LIST = "/api/airportInterface/taskByDroneId";
String API_AIRPORT_LINE_LIST = "/airportInterface/taskByDroneId";

/**
* 机场平台:执行接口
*/
String API_AIRPORT_EXECUTE_TASK = "/api/airportInterface/executeTaskAnsy";
String API_AIRPORT_EXECUTE_TASK = "/airportInterface/executeTaskAnsy";

/**
* 机场平台:获取天气
*/
String API_AIRPORT_GET_WEATHER = "/api/airportInterface/getWeather";
String API_AIRPORT_GET_WEATHER = "/airportInterface/getWeather";

// 飞手平台不同接口url
/**
@@ -37,16 +37,26 @@ public interface SystemConstant {
/**
* 机场平台:定点飞行
*/
String API_AIRPORT_POINT_FLIGH = "/api/airportInterface/createPointLine";
String API_AIRPORT_POINT_FLIGH = "/airportInterface/createPointLine";

/**
* 机场平台:控制无人机
*/
String API_AIRPORT_DRONE_CONTROL = "/api/airportInterface/droneCommand";
String API_AIRPORT_DRONE_CONTROL = "/airportInterface/droneCommand";

/**
* 机场平台:获取机场状态
*/
String API_AIRPORT_STATUS_BY_AIRPORT_ID = "/api/airportInterface/getAirportStatusByAirportId";
String API_AIRPORT_STATUS_BY_AIRPORT_ID = "/airportInterface/getAirportStatusByAirportId";

/**
* 机场平台:获取机场状态
*/
String API_AIRPORT_STATUS = "/airportInterface/getAirportStatus";

/**
* 机场平台:获取航点文件坐标
*/
String API_AIRPORT_LOCATION = "/airportInterface/getLocationById";

}

+ 2
- 6
tuoheng-admin/src/main/java/com/tuoheng/admin/service/impl/IndexServiceImpl.java Ver arquivo

@@ -6,12 +6,10 @@ import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.tuoheng.admin.entity.domain.Question;
import com.tuoheng.admin.entity.domain.Tenant;
import com.tuoheng.admin.config.SystemConstant;
import com.tuoheng.admin.entity.domain.ThMission;
import com.tuoheng.admin.entity.dto.index.AirportDetailDto;
import com.tuoheng.admin.entity.dto.index.QuestionListDto;
import com.tuoheng.admin.entity.request.index.GetAirportDetailDto;
import com.tuoheng.admin.entity.request.index.GetQuestionListDto;
import com.tuoheng.admin.entity.vo.MissionVO;
import com.tuoheng.admin.enums.MarkTypeEnum;
@@ -26,10 +24,8 @@ import com.tuoheng.common.utils.HttpUtils;
import com.tuoheng.common.utils.JacksonUtil;
import com.tuoheng.common.utils.JsonResult;
import com.tuoheng.common.utils.StringUtils;
import com.tuoheng.system.entity.User;
import com.tuoheng.system.utils.ShiroUtils;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.compress.utils.Lists;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
@@ -91,7 +87,7 @@ public class IndexServiceImpl implements IndexService {

@Override
public JsonResult getAirportDetail(Integer airportId){
String url = CommonConfig.airportURL + "/api/airportInterface/getAirportStatus";
String url = CommonConfig.airportURL + SystemConstant.API_AIRPORT_STATUS;
String param = "airportId=" + airportId;
String result = HttpUtils.sendGet(url, param);
JsonResult jsonResult = JacksonUtil.json2pojo(result, JsonResult.class);

+ 5
- 5
tuoheng-admin/src/main/java/com/tuoheng/admin/service/impl/ThInspectionServiceImpl.java Ver arquivo

@@ -125,7 +125,7 @@ public class ThInspectionServiceImpl extends BaseServiceImpl<ThInspectionMapper,
@Override
public List<AirPortVO> airport() throws ServiceException, UnsupportedEncodingException {
Tenant tenant = tenantMapper.selectById(ShiroUtils.getTenantId());
String url = CommonConfig.airportURL + "/api/airportInterface/airportList";
String url = CommonConfig.airportURL + SystemConstant.API_AIRPORT_LIST;
String param = "page=1&limit=1000&tenantCode=" + tenant.getCode();
log.info("****** airportList param tenantCode:{}", tenant.getCode());
String airPortStr = HttpUtils.sendGet(url, param);
@@ -138,7 +138,7 @@ public class ThInspectionServiceImpl extends BaseServiceImpl<ThInspectionMapper,

@Override
public List<AirLineVO> airLine(Integer droneId) throws ServiceException {
String url = CommonConfig.airportURL + "/api/airportInterface/taskByDroneId";
String url = CommonConfig.airportURL + SystemConstant.API_AIRPORT_LINE_LIST;
String param = "page=1&limit=100&droneId=" + droneId;
String airPortStr = HttpUtils.sendGet(url, param);
JsonResult<AirLineVO> jsonResult = JacksonUtil.json2pojo(airPortStr, JsonResult.class);
@@ -168,7 +168,7 @@ public class ThInspectionServiceImpl extends BaseServiceImpl<ThInspectionMapper,
log.info("tenant查询完成");

log.info("executeTask准备入参");
String url = CommonConfig.airportURL + "/api/airportInterface/executeTaskAnsy";
String url = CommonConfig.airportURL + SystemConstant.API_AIRPORT_EXECUTE_TASK;
JSONObject jsonObject = new JSONObject();
jsonObject.put("code", SystemConstant.PLATFORM_CODE);
jsonObject.put("tenantCode", tenant.getCode());
@@ -201,7 +201,7 @@ public class ThInspectionServiceImpl extends BaseServiceImpl<ThInspectionMapper,

@Override
public AirWeatherVO getWeather(Integer airportId) throws ServiceException {
String url = CommonConfig.airportURL + "/api/airportInterface/getWeather";
String url = CommonConfig.airportURL + SystemConstant.API_AIRPORT_GET_WEATHER;
String param = "airportId=" + airportId;
String weatherStr = HttpUtils.sendGet(url, param);
JsonResult jsonResult;
@@ -231,7 +231,7 @@ public class ThInspectionServiceImpl extends BaseServiceImpl<ThInspectionMapper,
Assert.notNull(thMission, "任务不能为空!");
Integer taskId = thMission.getInspectionLine();
//解析标准srt文件里面的坐标,调用硬件接口,返回数据
String url = CommonConfig.airportURL + "/api/airportInterface/getLocationById";
String url = CommonConfig.airportURL + SystemConstant.API_AIRPORT_LOCATION;
String param = "id=" + taskId;
String airportLine = HttpUtils.sendGet(url, param);
JsonResult jsonResult = JacksonUtil.json2pojo(airportLine, JsonResult.class);

+ 1
- 1
tuoheng-admin/src/main/resources/application-dev.yml Ver arquivo

@@ -13,7 +13,7 @@ tuoheng:
# OSS域名
oss-url: https://ta-tech-image.oss-cn-shanghai.aliyuncs.com
# 机场域名
airport-url: http://192.168.11.22:9060
airport-url: http://192.168.11.11:7011/airport/admin
# 视频域名
video-url: https://vod.play.t-aaron.com/
# 高德Key

+ 1
- 1
tuoheng-admin/src/main/resources/application-local.yml Ver arquivo

@@ -13,7 +13,7 @@ tuoheng:
# OSS域名
oss-url: https://ta-tech-image.oss-cn-shanghai.aliyuncs.com
# 机场域名
airport-url: http://192.168.11.22:9060
airport-url: http://192.168.11.11:7011/airport/admin
# 视频域名
video-url: http://vod.play.t-aaron.com/
# 高德Key

+ 1
- 1
tuoheng-admin/src/main/resources/application-prod.yml Ver arquivo

@@ -13,7 +13,7 @@ tuoheng:
# OSS域名
oss-url: https://ta-tech-image.oss-cn-shanghai.aliyuncs.com
# 机场域名
airport-url: https://airport.t-aaron.com
airport-url: https://airport.t-aaron.com/airport/admin
# 视频域名
video-url: https://vod.play.t-aaron.com/
# 高德Key

+ 1
- 1
tuoheng-admin/src/main/resources/application-test.yml Ver arquivo

@@ -13,7 +13,7 @@ tuoheng:
# OSS域名
oss-url: https://ta-tech-image.oss-cn-shanghai.aliyuncs.com
# 机场域名
airport-url: https://airport-test.t-aaron.com
airport-url: https://airport-test.t-aaron.com/airport/admin
# 视频域名
video-url: https://vod.play.t-aaron.com/
# 高德Key

Carregando…
Cancelar
Salvar