no message
							parent
							
								
									f44a8355bf
								
							
						
					
					
						commit
						c1a20e1e2a
					
				| 
						 | 
				
			
			@ -8,6 +8,8 @@ import com.youchain.businessdata.domain.Les;
 | 
			
		|||
import com.youchain.businessdata.inputJson.LesRequest;
 | 
			
		||||
import com.youchain.businessdata.inputJson.PositionCodeRequest;
 | 
			
		||||
import com.youchain.businessdata.repository.LesRepository;
 | 
			
		||||
import com.youchain.businessdata.service.AgvTaskService;
 | 
			
		||||
import com.youchain.businessdata.service.KMReService;
 | 
			
		||||
import com.youchain.businessdata.service.LesService;
 | 
			
		||||
import com.youchain.businessdata.service.dto.LesDto;
 | 
			
		||||
import com.youchain.businessdata.service.dto.LesQueryCriteria;
 | 
			
		||||
| 
						 | 
				
			
			@ -52,6 +54,8 @@ public class LesServiceImpl implements LesService {
 | 
			
		|||
 | 
			
		||||
    private final DictService dictService;
 | 
			
		||||
 | 
			
		||||
    private final KMReService kmReService;
 | 
			
		||||
 | 
			
		||||
    private final LesMapper lesMapper;
 | 
			
		||||
 | 
			
		||||
    @Override
 | 
			
		||||
| 
						 | 
				
			
			@ -412,24 +416,7 @@ public class LesServiceImpl implements LesService {
 | 
			
		|||
    }
 | 
			
		||||
 | 
			
		||||
    private void sendLesTask(String json) {
 | 
			
		||||
        Dict dict = dictService.findDictByName("OPEN");
 | 
			
		||||
        String resultJson;
 | 
			
		||||
        if (dict != null) {
 | 
			
		||||
            resultJson = HttpPostUtil.sendPostReq(UrlApi.submitMission(), json);
 | 
			
		||||
            if (StringUtils.isEmpty(resultJson)) {
 | 
			
		||||
                throw new BadRequestException("AGV返回信息:下发任务接口调用失败");
 | 
			
		||||
            }
 | 
			
		||||
            JSONObject resulObject = JSON.parseObject(resultJson);
 | 
			
		||||
            if (resulObject == null) {
 | 
			
		||||
                throw new BadRequestException("AGV返回信息:下发任务接口返回为空");
 | 
			
		||||
            }
 | 
			
		||||
 | 
			
		||||
            String code = resulObject.getString("code");
 | 
			
		||||
            String message = resulObject.getString("message");
 | 
			
		||||
            if (!"0".equals(code)) {
 | 
			
		||||
                throw new BadRequestException("AGV返回消息:" + message);
 | 
			
		||||
            }
 | 
			
		||||
        }
 | 
			
		||||
        kmReService.sendAgvTaskToContainer(UrlApi.submitMission(), json);
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
}
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue