소스 검색

订单修改数量控制调整

沈静伟 4 년 전
부모
커밋
5d648de644
1개의 변경된 파일6개의 추가작업 그리고 6개의 파일을 삭제
  1. 6 6
      src/apps/saorderdetail/saorderdetail.java

+ 6 - 6
src/apps/saorderdetail/saorderdetail.java

@@ -305,13 +305,13 @@ public class saorderdetail extends PaoCust {
         }
         }
         if ("FCHANGEQTY".equals(fieldname)) {
         if ("FCHANGEQTY".equals(fieldname)) {
             double fundeliqty = getDouble("fundeliqty");
             double fundeliqty = getDouble("fundeliqty");
-            double fqty = getDouble("fqty");
-            double foldqty = getPaoField("fqty").getPreviousValue().asDouble();
-            if (fqty >= foldqty) {
-                throw new P2AppException("", "修改数量必须小于原订单数量" + Math.sub(fqty, fundeliqty));
+            double FCHANGEQTY = getDouble("FCHANGEQTY");
+            double foldqty = getDouble("fqty");
+            if (FCHANGEQTY >= foldqty) {
+                throw new P2AppException("", "修改数量必须小于原订单数量" + foldqty);
             }
             }
-            if (getDouble(fieldname) < Math.sub(fqty, fundeliqty)) {
-                throw new P2AppException("", "修改数量必须大于等于已发货数量" + Math.sub(fqty, fundeliqty));
+            if (getDouble(fieldname) < Math.sub(foldqty, fundeliqty)) {
+                throw new P2AppException("", "修改数量必须大于等于已发货数量" + Math.sub(foldqty, fundeliqty));
             }
             }
             if (getDouble(fieldname) < 0) {
             if (getDouble(fieldname) < 0) {
                 throw new P2AppException("", "修改数量不可小于0");
                 throw new P2AppException("", "修改数量不可小于0");