archetecture security fix

This commit is contained in:
root
2026-06-11 03:22:12 -04:00
parent 6def9993da
commit 9483750161
3126 changed files with 177194 additions and 37211 deletions
@@ -0,0 +1,23 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.applyPricingRules = void 0;
exports.calculateUpdatedInsuranceCharge = calculateUpdatedInsuranceCharge;
exports.calculateUpdatedAdditionalDriverCharge = calculateUpdatedAdditionalDriverCharge;
var pricingRuleService_1 = require("../../services/pricingRuleService");
Object.defineProperty(exports, "applyPricingRules", { enumerable: true, get: function () { return pricingRuleService_1.applyPricingRules; } });
function calculateUpdatedInsuranceCharge(chargeType, chargeValue, totalDays, baseRentalAmount) {
switch (chargeType) {
case 'PER_DAY': return chargeValue * totalDays;
case 'PER_RENTAL': return chargeValue;
case 'PERCENTAGE_OF_RENTAL': return Math.round(baseRentalAmount * chargeValue / 100);
default: return 0;
}
}
function calculateUpdatedAdditionalDriverCharge(chargeType, chargeValue, totalDays) {
switch (chargeType) {
case 'PER_DAY': return chargeValue * totalDays;
case 'FLAT': return chargeValue;
default: return 0;
}
}
//# sourceMappingURL=reservation.pricing.service.js.map