|
|
|
@ -502,13 +502,13 @@ public class InvCountOrderService extends ServiceImpl<InvCountOrderMapper, InvCo
|
|
|
|
|
for (InvCountOrderDetailEntity invCountOrderDetail : orderDetailList) {
|
|
|
|
|
if (IntUtil.value(invCountOrderDetail.getLossNum()) > 0) {
|
|
|
|
|
IoCodeTempEntity warehouseEntity = buildCodeEntity(invCountOrderDetail, invCountOrder, ConstantType.TYPE_OUT);
|
|
|
|
|
warehouseEntity.setSupId(getSupId(warehouseEntity));
|
|
|
|
|
warehouseEntity.setSupId(invCountOrderDetail.getSupId());
|
|
|
|
|
lossCodesList.add(warehouseEntity);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (IntUtil.value(invCountOrderDetail.getProfitNum()) > 0) {
|
|
|
|
|
IoCodeTempEntity warehouseEntity = buildCodeEntity(invCountOrderDetail, invCountOrder, ConstantType.TYPE_PUT);
|
|
|
|
|
warehouseEntity.setSupId(getSupId(warehouseEntity));
|
|
|
|
|
warehouseEntity.setSupId(invCountOrderDetail.getSupId());
|
|
|
|
|
profitCodesList.add(warehouseEntity);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
@ -704,13 +704,13 @@ public class InvCountOrderService extends ServiceImpl<InvCountOrderMapper, InvCo
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private String getSupId(IoCodeTempEntity warehouseEntity) {
|
|
|
|
|
List<String> supIds = companyProductRelevanceDao.selectUnitFkByUdiRlIdFk(warehouseEntity.getRelId() + "");
|
|
|
|
|
if (CollUtil.isNotEmpty(supIds) && supIds.size() == 1) {
|
|
|
|
|
return supIds.get(0);
|
|
|
|
|
}
|
|
|
|
|
return null;
|
|
|
|
|
}
|
|
|
|
|
// private String getSupId(IoCodeTempEntity warehouseEntity) {
|
|
|
|
|
// List<String> supIds = companyProductRelevanceDao.selectUnitFkByUdiRlIdFk(warehouseEntity.getRelId() + "");
|
|
|
|
|
// if (CollUtil.isNotEmpty(supIds) && supIds.size() == 1) {
|
|
|
|
|
// return supIds.get(0);
|
|
|
|
|
// }
|
|
|
|
|
// return null;
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
|
|
public InvCountOrderEntity selectByOrderId(String orderId) {
|
|
|
|
|
return invCountOrderDao.selectByOrderId(orderId);
|
|
|
|
|