rittenhop-dev/versions/5.94.2/node_modules/@tryghost/donations/build/DonationPaymentEvent.js
2024-09-23 19:40:12 -04:00

38 lines
1.2 KiB
JavaScript

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.DonationPaymentEvent = void 0;
class DonationPaymentEvent {
timestamp;
name;
email;
memberId;
amount;
currency;
donationMessage;
attributionId;
attributionUrl;
attributionType;
referrerSource;
referrerMedium;
referrerUrl;
constructor(data, timestamp) {
this.timestamp = timestamp;
this.name = data.name;
this.email = data.email;
this.memberId = data.memberId;
this.amount = data.amount;
this.currency = data.currency;
this.donationMessage = data.donationMessage;
this.attributionId = data.attributionId;
this.attributionUrl = data.attributionUrl;
this.attributionType = data.attributionType;
this.referrerSource = data.referrerSource;
this.referrerMedium = data.referrerMedium;
this.referrerUrl = data.referrerUrl;
}
static create(data, timestamp) {
return new DonationPaymentEvent(data, timestamp ?? new Date());
}
}
exports.DonationPaymentEvent = DonationPaymentEvent;
//# sourceMappingURL=DonationPaymentEvent.js.map