|
|
@@ -21,10 +21,7 @@ import com.tuoheng.admin.service.IThInspectionService; |
|
|
|
import com.tuoheng.common.common.BaseServiceImpl; |
|
|
|
import com.tuoheng.common.config.CommonConfig; |
|
|
|
import com.tuoheng.common.exception.ServiceException; |
|
|
|
import com.tuoheng.common.utils.HttpUtils; |
|
|
|
import com.tuoheng.common.utils.JacksonUtil; |
|
|
|
import com.tuoheng.common.utils.JsonResult; |
|
|
|
import com.tuoheng.common.utils.RedisUtils; |
|
|
|
import com.tuoheng.common.utils.*; |
|
|
|
import com.tuoheng.system.utils.ShiroUtils; |
|
|
|
import groovy.util.logging.Slf4j; |
|
|
|
import org.apache.poi.ss.formula.functions.T; |
|
|
@@ -150,7 +147,12 @@ public class ThInspectionServiceImpl extends BaseServiceImpl<ThInspectionMapper, |
|
|
|
jsonObject.put("taskId", taskId); |
|
|
|
|
|
|
|
String airPortStr = HttpUtils.doSend(url, jsonObject, null, "POST"); |
|
|
|
JsonResult jsonResult = JacksonUtil.json2pojo(airPortStr, JsonResult.class); |
|
|
|
JsonResult jsonResult = null; |
|
|
|
try { |
|
|
|
jsonResult = JacksonUtil.json2pojo(airPortStr, JsonResult.class); |
|
|
|
} catch (Exception e) { |
|
|
|
return JsonResult.error(airPortStr); |
|
|
|
} |
|
|
|
if (ObjectUtil.isEmpty(jsonResult) || (!ObjectUtil.isEmpty(Objects.requireNonNull(jsonResult).getData()) && jsonResult.getCode() != 0)) { |
|
|
|
assert jsonResult != null; |
|
|
|
return JsonResult.error(JSONObject.parseArray(JSONObject.parseObject(JSONObject.toJSONString(jsonResult.getData())).get("data").toString(), AirExecuteTaskVO.class), "执行任务失败!"); |