turf-common 1.2.1-beta.4 → 1.2.1-beta.5
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.
|
@@ -26,10 +26,9 @@ export declare class ChargesModel implements IChargeModel {
|
|
|
26
26
|
private modifyMove;
|
|
27
27
|
clone(): ChargesModel;
|
|
28
28
|
private modifyDelete;
|
|
29
|
-
static
|
|
29
|
+
static getInstance(bookingDetailsEntity: IChargeModel, discountPolicy?: ModificationDiscountPolicy): ChargesModel;
|
|
30
30
|
static assignByInterface(bookingDetailsEntity: IChargeModel, discountPolicy?: ModificationDiscountPolicy): ChargesModel;
|
|
31
31
|
getTotalAmount(): number;
|
|
32
32
|
getPaymentStatus(): "Refund" | "Paid" | "Pending";
|
|
33
|
-
static getInstance(data: Partial<ChargesModel>, discountPolicy?: ModificationDiscountPolicy): ChargesModel;
|
|
34
33
|
getTotalNetAmount(): number;
|
|
35
34
|
}
|
|
@@ -185,7 +185,7 @@ var ChargesModel = /** @class */ (function () {
|
|
|
185
185
|
}
|
|
186
186
|
return newChargeModel;
|
|
187
187
|
};
|
|
188
|
-
ChargesModel.
|
|
188
|
+
ChargesModel.getInstance = function (bookingDetailsEntity, discountPolicy) {
|
|
189
189
|
if (discountPolicy === void 0) { discountPolicy = modification_discount_policy_enum_1.ModificationDiscountPolicy.DISCOUNT_CONDITIONAL; }
|
|
190
190
|
var chargesModel = new ChargesModel(bookingDetailsEntity.initialBookingGrossAmount, bookingDetailsEntity.amountPaid, bookingDetailsEntity.couponCode, discountPolicy);
|
|
191
191
|
Object.assign(chargesModel, bookingDetailsEntity);
|
|
@@ -222,13 +222,6 @@ var ChargesModel = /** @class */ (function () {
|
|
|
222
222
|
? "Paid"
|
|
223
223
|
: "Pending";
|
|
224
224
|
};
|
|
225
|
-
ChargesModel.getInstance = function (data, discountPolicy) {
|
|
226
|
-
if (discountPolicy === void 0) { discountPolicy = modification_discount_policy_enum_1.ModificationDiscountPolicy.DISCOUNT_CONDITIONAL; }
|
|
227
|
-
var chargesModel = new ChargesModel(data.initialBookingGrossAmount, data.amountPaid, data.couponCode, discountPolicy);
|
|
228
|
-
// set values
|
|
229
|
-
Object.assign(chargesModel, data);
|
|
230
|
-
return chargesModel;
|
|
231
|
-
};
|
|
232
225
|
ChargesModel.prototype.getTotalNetAmount = function () {
|
|
233
226
|
return this.getNetAmount() + this.totalCancellationCharges;
|
|
234
227
|
};
|