Commit f9ef2c88 by 江和松

销售出库单价金额不能小于0

parent 64bb2fb2
...@@ -163,7 +163,7 @@ public class ServiceHGKC004 extends ServiceEPBase { ...@@ -163,7 +163,7 @@ public class ServiceHGKC004 extends ServiceEPBase {
List<HGKC004A> hgkc004s = HGKCTools.HgKc004.getDetailById(hgkc004.getId()); List<HGKC004A> hgkc004s = HGKCTools.HgKc004.getDetailById(hgkc004.getId());
AssertUtils.isEmpty(hgkc004s, "销售出库单明细不存在!"); AssertUtils.isEmpty(hgkc004s, "销售出库单明细不存在!");
for (HGKC004A hgkc004A : hgkc004s) { for (HGKC004A hgkc004A : hgkc004s) {
if (hgkc004A.getPrice().compareTo(BigDecimal.ZERO)<=0 || hgkc004A.getAmount().compareTo(BigDecimal.ZERO)<=0){ if (hgkc004A.getPrice().compareTo(BigDecimal.ZERO) < 0 || hgkc004A.getAmount().compareTo(BigDecimal.ZERO) < 0){
throw new PlatException("单价和金额不能小于0!"); throw new PlatException("单价和金额不能小于0!");
} }
HGKC010 hgkc010 = HGKCTools.HgKc010.get(kc004.getCompanyCode(), kc004.getWhCode(), hgkc004A.getInventCode()); HGKC010 hgkc010 = HGKCTools.HgKc010.get(kc004.getCompanyCode(), kc004.getWhCode(), hgkc004A.getInventCode());
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment