b2m-utils 0.0.195 → 0.0.196

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -355,7 +355,7 @@ var calculateFee = function (ratecardLaneFee, cte, allFees, debug, allFeesForCal
355
355
  switch (fee_1.id) {
356
356
  case FeeEnum.ICMS:
357
357
  if (allFees && Array.isArray(allFees) && (allFees === null || allFees === void 0 ? void 0 : allFees.length) > 0) {
358
- var totalFromAllFees = filterSiblingFees(allFees).filter(function (i) { var _a; return ((_a = i.fee) === null || _a === void 0 ? void 0 : _a.feeCalculationTypeId) !== FeeCalculationTypeEnum.TOTAL_PERCENTAGE; }).map(function (it) {
358
+ var totalFromAllFees = filterSiblingFees(allFees).filter(function (i) { var _a; return ((_a = i.fee) === null || _a === void 0 ? void 0 : _a.id) !== fee_1.id; }).map(function (it) {
359
359
  var result = calculateFee(it, cte, allFees, debug, allFeesForCalc);
360
360
  if (result === null || result === void 0 ? void 0 : result.totalToCalc) {
361
361
  return result.totalToCalc;
@@ -458,7 +458,7 @@ var calculateFee = function (ratecardLaneFee, cte, allFees, debug, allFeesForCal
458
458
  style: 'currency',
459
459
  currency: 'BRL',
460
460
  });
461
- var result_1 = "".concat(totalValueFromAllFeesCurrency, " x ").concat(valueToMultiply, "%").concat(redeliveryInfo_1, " = ").concat(resultCurrency_1);
461
+ var result_1 = "".concat(totalValueFromAllFeesCurrency, " x ").concat(+value, "%").concat(redeliveryInfo_1, " = ").concat(resultCurrency_1);
462
462
  totalFee = total_1;
463
463
  resultFee = result_1;
464
464
  }
Binary file