| | |
| | | package com.zy.common.model; |
| | | |
| | | import com.baomidou.mybatisplus.mapper.EntityWrapper; |
| | | import com.core.common.SpringUtils; |
| | | import com.zy.asrs.entity.LocDetl; |
| | | import com.zy.asrs.service.LocDetlService; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | |
| | | public void setLocDetlDtos(List<LocDetlDto> locDetlDtos) { |
| | | this.locDetlDtos = locDetlDtos; |
| | | } |
| | | |
| | | public boolean isAll(){ |
| | | // 查询当前库位号所有的库存明细 |
| | | LocDetlService locDetlService = SpringUtils.getBean(LocDetlService.class); |
| | | List<LocDetl> locDetls = locDetlService.selectList(new EntityWrapper<LocDetl>().eq("loc_no", this.locNo)); |
| | | if (locDetls == null || locDetls.isEmpty()){ |
| | | return true; |
| | | } |
| | | int sameNumber = 0; |
| | | for (LocDetl locDetl : locDetls) { |
| | | for (LocDetlDto dto : this.locDetlDtos) { |
| | | if (dto.getLocDetl().getMatnr().equals(locDetl.getMatnr()) && dto.getCount().equals(locDetl.getAnfme())) { |
| | | sameNumber++; |
| | | break; |
| | | } |
| | | } |
| | | } |
| | | return sameNumber == locDetls.size(); |
| | | } |
| | | |
| | | } |