cecon-interfaces
Version:
Interfaces de Projetos Cecon
47 lines (46 loc) • 1.6 kB
JavaScript
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.SubscriptionBaseEntity = void 0;
var general_1 = require("../../general");
var enums_1 = require("../enums");
var SubscriptionBaseEntity = /** @class */ (function () {
// #endregion Properties (25)
// #region Constructors (1)
function SubscriptionBaseEntity(data) {
// #region Properties (25)
this.amount = 0;
this.cancellationReason = '';
this.createdAt = new Date();
this.customVariables = [];
this.expiresAt = new Date();
this.id = '';
this.interval = 0;
this.intervalType = general_1.EIntervalType.MONTHS;
this.invoices = [];
this.items = [];
this.logs = [];
this.notes = '';
this.payment = new general_1.PaymentEntity();
this.paymentType = general_1.EPaymentType.NONE;
this.phoneNumbersNotification = [];
this.planId = '';
this.planName = '';
this.recentInvoices = [];
this.renewPaymentDate = new Date();
this.renovatedAt = new Date();
this.startsAt = new Date();
this.status = enums_1.ESubscriptionStatus.PENDING;
this.suspendedTimes = 0;
this.tags = [];
this.updatedAt = new Date();
if (data) {
for (var key in data) {
if (data.hasOwnProperty(key) && key in this) {
this[key] = data[key];
}
}
}
}
return SubscriptionBaseEntity;
}());
exports.SubscriptionBaseEntity = SubscriptionBaseEntity;