| | |
| | | package com.zy.acs.manager.core.service; |
| | | |
| | | import com.zy.acs.framework.common.Cools; |
| | | import com.zy.acs.manager.manager.entity.Code; |
| | | import com.zy.acs.manager.manager.entity.Loc; |
| | | import com.zy.acs.manager.manager.entity.Sta; |
| | | import com.zy.acs.manager.manager.entity.Task; |
| | | import com.zy.acs.manager.manager.service.AreaAgvService; |
| | | import com.zy.acs.manager.manager.service.CodeService; |
| | | import com.zy.acs.manager.manager.service.LocService; |
| | | import com.zy.acs.manager.manager.service.StaService; |
| | | import lombok.extern.slf4j.Slf4j; |
| | |
| | | private AreaGovernService areaGovernService; |
| | | @Autowired |
| | | private AreaAgvService areaAgvService; |
| | | @Autowired |
| | | private CodeService codeService; |
| | | |
| | | @PostConstruct |
| | | public void init() { |
| | |
| | | Sta destSta = null; |
| | | if (null != task.getOriLoc()) { |
| | | oriLoc = locService.getById(task.getOriLoc()); |
| | | return this.getAgvIdsByCode(oriLoc.getCode$()); |
| | | Code code = codeService.getCacheById(oriLoc.getCode()); |
| | | return this.getAgvIdsByCode(code.getData()); |
| | | } |
| | | if (null != task.getOriSta()) { |
| | | oriSta = staService.getById(task.getOriSta()); |
| | | return this.getAgvIdsByCode(oriSta.getCode$()); |
| | | Code code = codeService.getCacheById(oriSta.getCode()); |
| | | return this.getAgvIdsByCode(code.getData()); |
| | | } |
| | | if (null != task.getDestLoc()) { |
| | | destLoc = locService.getById(task.getDestLoc()); |
| | | return this.getAgvIdsByCode(destLoc.getCode$()); |
| | | Code code = codeService.getCacheById(destLoc.getCode()); |
| | | return this.getAgvIdsByCode(code.getData()); |
| | | } |
| | | if (null != task.getDestSta()) { |
| | | destSta = staService.getById(task.getDestSta()); |
| | | return this.getAgvIdsByCode(destSta.getCode$()); |
| | | Code code = codeService.getCacheById(destSta.getCode()); |
| | | return this.getAgvIdsByCode(code.getData()); |
| | | } |
| | | return null; |
| | | } |