| | |
| | | import com.zy.asrs.service.*; |
| | | import com.zy.asrs.task.AbstractHandler; |
| | | import com.zy.asrs.task.core.ReturnT; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | @Slf4j |
| | | @Service |
| | | public class AgvWrkMastHandler extends AbstractHandler<String> { |
| | | |
| | |
| | | agvLocMastService.updateLocStsByLocNo(agvWrkMast.getLocNo(),"F"); |
| | | } |
| | | //生成AGV工作历史档 |
| | | agvWrkMastLogService.save(wrkNo); |
| | | agvWrkMastLogService.save(agvWrkMast); |
| | | //生成AGV工作明细历史档 |
| | | agvWrkDetlLogService.save(wrkNo); |
| | | //删除AGV工作档 |
| | | agvWrkMastService.deleteById(wrkNo); |
| | | //删除AGV工作明细档 |
| | | agvWrkDetlService.delete(new EntityWrapper<AgvWrkDetl>().eq("wrk_no",wrkNo)); |
| | | //类型为入库时 |
| | | if(agvWrkMast.getIoType() == 1){ |
| | | //更新目标库位明细 |
| | | log.info("更新目标库位明细 agvWrkMast.getLocNo(): " + agvWrkMast.getLocNo() + ", wrkNo: " + wrkNo); |
| | | agvLocDetlService.addLocDetlInfo(agvWrkMast.getLocNo(),wrkNo); |
| | | //生成入库通知历史档 |
| | | agvWaitPakinLogService.save(barcode); |
| | | boolean save = agvWaitPakinLogService.save(barcode); |
| | | //删除入库通知档 |
| | | agvWaitPakinService.delete(new EntityWrapper<AgvWaitPakin>().eq("zpallet",barcode)); |
| | | log.info("删除入库通知档 supp_code: " + barcode); |
| | | agvWaitPakinService.delete(new EntityWrapper<AgvWaitPakin>().eq("supp_code",barcode)); |
| | | } |
| | | //类型为库位移转时 |
| | | if(agvWrkMast.getIoType() == 11){ |
| | |
| | | //修改源库位状态为O |
| | | agvLocMastService.updateLocStsByLocNo(agvWrkMast.getSourceLocNo(),"O"); |
| | | } |
| | | |
| | | //删除AGV工作档 |
| | | agvWrkMastService.deleteById(wrkNo); |
| | | //删除AGV工作明细档 |
| | | agvWrkDetlService.delete(new EntityWrapper<AgvWrkDetl>().eq("wrk_no",wrkNo)); |
| | | |
| | | if(!isJSON(orderNo)){ |
| | | //检查订单是否已完成 |
| | | orderService.checkComplete(orderNo); |
| | |
| | | } |
| | | |
| | | //生成AGV工作历史档 |
| | | agvWrkMastLogService.save(wrkNo); |
| | | agvWrkMastLogService.save(agvWrkMast); |
| | | //生成AGV工作明细历史档 |
| | | agvWrkDetlLogService.save(wrkNo); |
| | | //删除AGV工作档 |