| | |
| | | package com.consum.base.service; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.HashMap; |
| | | import java.util.List; |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | import org.springframework.transaction.interceptor.TransactionAspectSupport; |
| | | import org.springframework.util.CollectionUtils; |
| | | |
| | | import com.consum.base.core.utils.IdUtil; |
| | | import com.consum.base.core.utils.LockManage; |
| | | import com.consum.model.po.LGoodsUserRecord; |
| | | import com.consum.model.po.LWhFormTransfer; |
| | | import com.consum.model.po.LWhProcureModelUser; |
| | | import com.consum.model.po.LWhProcureModelUserRecord; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | import org.springframework.transaction.interceptor.TransactionAspectSupport; |
| | | import org.springframework.util.CollectionUtils; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.util.ArrayList; |
| | | import java.util.HashMap; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * @ClassName LGoodsUserRecordCoreService |
| | |
| | | LWhFormTransfer whFormTransfer = goodsBaseService.get(new LWhFormTransfer(transBusinessId)); |
| | | Integer inWarehouseType = whFormTransfer.getInWarehouseType(); |
| | | Long inWarehouseId = whFormTransfer.getInWarehouseId(); |
| | | // 将所有物品设置为未分发 |
| | | // 将所有已下发物品设置为未分发 如果发生了退回,此时数量则小于分发时的数量! |
| | | List<Long> srappedGoodsIds = lWhGoodsService.queryScrappedGoodsIds(inWarehouseType, inWarehouseId, |
| | | transBusinessId, null, null, null, null); |
| | | lWhGoodsService.modGoodsTransfering(srappedGoodsIds, null, null, null, 3); |
| | | transBusinessId, null, null, (short)2, null); |
| | | lWhGoodsService.modGoodsTransfering(srappedGoodsIds, null, null, null, 1); |
| | | // 删除该调拨单旧有使用记录 |
| | | lGoodsUserRecordService.delete(new LGoodsUserRecord(), "where TRANS_BUSINESS_ID =" + transBusinessId, |
| | | new HashMap<>()); |