Browse Source

变更修复计量上限值bug

ellisran 1 year ago
parent
commit
2af3e8b7e6
1 changed files with 2 additions and 2 deletions
  1. 2 2
      app/controller/change_controller.js

+ 2 - 2
app/controller/change_controller.js

@@ -738,8 +738,8 @@ module.exports = app => {
                             if (useChangeUsedData.length > 0 && ctx.helper._.findIndex(useChangeUsedData, { cbid: cl.id }) !== -1) {
                                 // 获取比例值
                                 const uc = ctx.helper._.find(useChangeUsedData, { cbid: cl.id });
-                                const minLimit = Math.ceil(ctx.helper.div(uc.qty, cl.camount) * 100);
-                                if (minLimit < renderData.deLimit) {
+                                const minLimit = Math.ceil(ctx.helper.mul(ctx.helper.div(uc.qty, cl.camount), 100));
+                                if (minLimit <= renderData.deLimit) {
                                     one.delimit = renderData.deLimit;
                                     cl.delimit = renderData.deLimit;
                                 }