|
|
|
@ -1,5 +1,6 @@
|
|
|
|
|
package com.glxp.api.controller.inv;
|
|
|
|
|
|
|
|
|
|
import com.glxp.api.entity.auth.InvWarehouseEntity;
|
|
|
|
|
import com.glxp.api.service.inv.impl.InvProductDetailService;
|
|
|
|
|
import com.glxp.api.service.inv.impl.InvProductService;
|
|
|
|
|
import org.springframework.beans.BeanUtils;
|
|
|
|
@ -309,7 +310,14 @@ public class InvProductController extends BaseController {
|
|
|
|
|
BasicBussinessTypeEntity bussinessTypeEntity = basicBussinessTypeService.findByAction(codeTempEntity.getAction());
|
|
|
|
|
int count = 0;
|
|
|
|
|
if (bussinessTypeEntity.getSpaceOut() == ConstantStatus.SPACE_OUT_NULL) {
|
|
|
|
|
count = invProductDetailService.vailStockCount(codeTempEntity.getRelId(), codeTempEntity.getBatchNo(), codeTempEntity.getSupId(), codeTempEntity.getDeptCode(), codeTempEntity.getInvCode(), null);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
String outInvCode = codeTempEntity.getInvCode();
|
|
|
|
|
InvWarehouseEntity invWarehouseEntity = invWarehouseService.findNoInvTypeInv(bussinessTypeEntity.getDeptNoInvType(), outInvCode);
|
|
|
|
|
if (invWarehouseEntity != null) {
|
|
|
|
|
outInvCode = invWarehouseEntity.getCode();
|
|
|
|
|
}
|
|
|
|
|
count = invProductDetailService.vailStockCount(codeTempEntity.getRelId(), codeTempEntity.getBatchNo(), codeTempEntity.getSupId(), null, outInvCode, null);
|
|
|
|
|
} else if (bussinessTypeEntity.getSpaceOut() == ConstantStatus.SPACE_OUT_SET) {
|
|
|
|
|
count = invProductDetailService.vailStockCount(codeTempEntity.getRelId(), codeTempEntity.getBatchNo(), codeTempEntity.getSupId(), codeTempEntity.getDeptCode(), codeTempEntity.getInvCode(), codeTempEntity.getWarehouseCode());
|
|
|
|
|
} else if (bussinessTypeEntity.getSpaceOut() == ConstantStatus.SPACE_OUT_CODE) {
|
|
|
|
|