cecon-interfaces 1.1.17 → 1.1.19
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/company/entities/company.entity.d.ts +0 -2
- package/dist/company/entities/company.entity.js +0 -1
- package/dist/company/interfaces/i-company.d.ts +4 -5
- package/dist/esm2022/company/entities/company.entity.mjs +1 -2
- package/dist/esm2022/company/interfaces/i-company.mjs +1 -1
- package/dist/esm2022/general/entities/index.mjs +7 -1
- package/dist/esm2022/general/entities/payment-card.entity.mjs +18 -0
- package/dist/esm2022/general/entities/payment-cash.entity.mjs +16 -0
- package/dist/esm2022/general/entities/payment-method-option.entity.mjs +31 -0
- package/dist/esm2022/general/entities/payment-method.entity.mjs +14 -18
- package/dist/esm2022/general/entities/payment-pix.entity.mjs +17 -0
- package/dist/esm2022/general/entities/payment-wallet.entity.mjs +16 -0
- package/dist/esm2022/general/entities/payment.entity.mjs +25 -0
- package/dist/esm2022/general/enums/payment-type.enum.mjs +2 -1
- package/dist/esm2022/general/interfaces/i-payment-card.mjs +2 -0
- package/dist/esm2022/general/interfaces/i-payment-cash.mjs +2 -0
- package/dist/esm2022/general/interfaces/i-payment-method-option.mjs +2 -0
- package/dist/esm2022/general/interfaces/i-payment-method.mjs +1 -1
- package/dist/esm2022/general/interfaces/i-payment-pix.mjs +2 -0
- package/dist/esm2022/general/interfaces/i-payment-wallet.mjs +2 -0
- package/dist/esm2022/general/interfaces/i-payment.mjs +2 -0
- package/dist/esm2022/general/interfaces/index.mjs +1 -1
- package/dist/esm2022/partner/entities/partner.entity.mjs +1 -2
- package/dist/esm2022/partner/interfaces/i-partner.mjs +1 -1
- package/dist/esm2022/subscription/entities/subscription.entity.mjs +5 -4
- package/dist/esm2022/subscription/interfaces/i-subscription.mjs +1 -1
- package/dist/fesm2022/cecon-interfaces.mjs +123 -6
- package/dist/fesm2022/cecon-interfaces.mjs.map +1 -1
- package/dist/general/entities/index.d.ts +6 -0
- package/dist/general/entities/index.js +13 -1
- package/dist/general/entities/payment-card.entity.d.ts +7 -0
- package/dist/general/entities/payment-card.entity.js +22 -0
- package/dist/general/entities/payment-cash.entity.d.ts +5 -0
- package/dist/general/entities/payment-cash.entity.js +20 -0
- package/dist/general/entities/payment-method-option.entity.d.ts +20 -0
- package/dist/general/entities/payment-method-option.entity.js +35 -0
- package/dist/general/entities/payment-method.entity.d.ts +17 -16
- package/dist/general/entities/payment-method.entity.js +13 -17
- package/dist/general/entities/payment-pix.entity.d.ts +6 -0
- package/dist/general/entities/payment-pix.entity.js +21 -0
- package/dist/general/entities/payment-wallet.entity.d.ts +5 -0
- package/dist/general/entities/payment-wallet.entity.js +20 -0
- package/dist/general/entities/payment.entity.d.ts +8 -0
- package/dist/general/entities/payment.entity.js +29 -0
- package/dist/general/enums/payment-type.enum.d.ts +2 -1
- package/dist/general/enums/payment-type.enum.js +1 -0
- package/dist/general/interfaces/i-payment-card.d.ts +5 -0
- package/dist/general/interfaces/i-payment-card.js +2 -0
- package/dist/general/interfaces/i-payment-cash.d.ts +3 -0
- package/dist/general/interfaces/i-payment-cash.js +2 -0
- package/dist/general/interfaces/i-payment-method-option.d.ts +18 -0
- package/dist/general/interfaces/i-payment-method-option.js +2 -0
- package/dist/general/interfaces/i-payment-method.d.ts +15 -15
- package/dist/general/interfaces/i-payment-pix.d.ts +4 -0
- package/dist/general/interfaces/i-payment-pix.js +2 -0
- package/dist/general/interfaces/i-payment-wallet.d.ts +3 -0
- package/dist/general/interfaces/i-payment-wallet.js +2 -0
- package/dist/general/interfaces/i-payment.d.ts +6 -0
- package/dist/general/interfaces/i-payment.js +2 -0
- package/dist/general/interfaces/index.d.ts +6 -0
- package/dist/package.json +1 -1
- package/dist/partner/entities/partner.entity.d.ts +1 -2
- package/dist/partner/entities/partner.entity.js +0 -1
- package/dist/partner/interfaces/i-partner.d.ts +1 -2
- package/dist/subscription/entities/subscription.entity.d.ts +2 -1
- package/dist/subscription/entities/subscription.entity.js +3 -2
- package/dist/subscription/interfaces/i-subscription.d.ts +2 -0
- package/package.json +1 -1
@@ -8,10 +8,16 @@ export { DeliveryAreaFixedEntity } from './dellivery-area-fixed.entity';
|
|
8
8
|
export { MessagerChannelEntity } from './messager-channel.entity';
|
9
9
|
export { MobyoApiConfigEntity } from './mobyo-apiconfig.entity';
|
10
10
|
export { OriginEntity } from './origin.entity';
|
11
|
+
export { PaymentCardEntity } from './payment-card.entity';
|
12
|
+
export { PaymentCashEntity } from './payment-cash.entity';
|
13
|
+
export { PaymentMethodOptionEntity } from './payment-method-option.entity';
|
11
14
|
export { PaymentMethodEntity } from './payment-method.entity';
|
15
|
+
export { PaymentPixEntity } from './payment-pix.entity';
|
12
16
|
export { PaymentProviderAgentEntity } from './payment-provider-agent.entity';
|
13
17
|
export { PaymentProviderEntity } from './payment-provider.entity';
|
14
18
|
export { PaymentTokenDataEntity } from './payment-token-data.entity';
|
15
19
|
export { PaymentTokenEntity } from './payment-token.entity';
|
20
|
+
export { PaymentWalletEntity } from './payment-wallet.entity';
|
21
|
+
export { PaymentEntity } from './payment.entity';
|
16
22
|
export { RatingEntity } from './rating.entity';
|
17
23
|
export { SponsorshipValueEntity } from './sponsorship-value.entity';
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.SponsorshipValueEntity = exports.RatingEntity = exports.PaymentTokenEntity = exports.PaymentTokenDataEntity = exports.PaymentProviderEntity = exports.PaymentProviderAgentEntity = exports.PaymentMethodEntity = exports.OriginEntity = exports.MobyoApiConfigEntity = exports.MessagerChannelEntity = exports.DeliveryAreaFixedEntity = exports.DeliveryAreaEntity = exports.CustomVariableEntity = exports.CoordsEntity = exports.CarouselImageEntity = exports.BaseEntity = exports.AddressEntity = void 0;
|
3
|
+
exports.SponsorshipValueEntity = exports.RatingEntity = exports.PaymentEntity = exports.PaymentWalletEntity = exports.PaymentTokenEntity = exports.PaymentTokenDataEntity = exports.PaymentProviderEntity = exports.PaymentProviderAgentEntity = exports.PaymentPixEntity = exports.PaymentMethodEntity = exports.PaymentMethodOptionEntity = exports.PaymentCashEntity = exports.PaymentCardEntity = exports.OriginEntity = exports.MobyoApiConfigEntity = exports.MessagerChannelEntity = exports.DeliveryAreaFixedEntity = exports.DeliveryAreaEntity = exports.CustomVariableEntity = exports.CoordsEntity = exports.CarouselImageEntity = exports.BaseEntity = exports.AddressEntity = void 0;
|
4
4
|
var address_entity_1 = require("./address.entity");
|
5
5
|
Object.defineProperty(exports, "AddressEntity", { enumerable: true, get: function () { return address_entity_1.AddressEntity; } });
|
6
6
|
var base_entity_1 = require("./base.entity");
|
@@ -21,8 +21,16 @@ var mobyo_apiconfig_entity_1 = require("./mobyo-apiconfig.entity");
|
|
21
21
|
Object.defineProperty(exports, "MobyoApiConfigEntity", { enumerable: true, get: function () { return mobyo_apiconfig_entity_1.MobyoApiConfigEntity; } });
|
22
22
|
var origin_entity_1 = require("./origin.entity");
|
23
23
|
Object.defineProperty(exports, "OriginEntity", { enumerable: true, get: function () { return origin_entity_1.OriginEntity; } });
|
24
|
+
var payment_card_entity_1 = require("./payment-card.entity");
|
25
|
+
Object.defineProperty(exports, "PaymentCardEntity", { enumerable: true, get: function () { return payment_card_entity_1.PaymentCardEntity; } });
|
26
|
+
var payment_cash_entity_1 = require("./payment-cash.entity");
|
27
|
+
Object.defineProperty(exports, "PaymentCashEntity", { enumerable: true, get: function () { return payment_cash_entity_1.PaymentCashEntity; } });
|
28
|
+
var payment_method_option_entity_1 = require("./payment-method-option.entity");
|
29
|
+
Object.defineProperty(exports, "PaymentMethodOptionEntity", { enumerable: true, get: function () { return payment_method_option_entity_1.PaymentMethodOptionEntity; } });
|
24
30
|
var payment_method_entity_1 = require("./payment-method.entity");
|
25
31
|
Object.defineProperty(exports, "PaymentMethodEntity", { enumerable: true, get: function () { return payment_method_entity_1.PaymentMethodEntity; } });
|
32
|
+
var payment_pix_entity_1 = require("./payment-pix.entity");
|
33
|
+
Object.defineProperty(exports, "PaymentPixEntity", { enumerable: true, get: function () { return payment_pix_entity_1.PaymentPixEntity; } });
|
26
34
|
var payment_provider_agent_entity_1 = require("./payment-provider-agent.entity");
|
27
35
|
Object.defineProperty(exports, "PaymentProviderAgentEntity", { enumerable: true, get: function () { return payment_provider_agent_entity_1.PaymentProviderAgentEntity; } });
|
28
36
|
var payment_provider_entity_1 = require("./payment-provider.entity");
|
@@ -31,6 +39,10 @@ var payment_token_data_entity_1 = require("./payment-token-data.entity");
|
|
31
39
|
Object.defineProperty(exports, "PaymentTokenDataEntity", { enumerable: true, get: function () { return payment_token_data_entity_1.PaymentTokenDataEntity; } });
|
32
40
|
var payment_token_entity_1 = require("./payment-token.entity");
|
33
41
|
Object.defineProperty(exports, "PaymentTokenEntity", { enumerable: true, get: function () { return payment_token_entity_1.PaymentTokenEntity; } });
|
42
|
+
var payment_wallet_entity_1 = require("./payment-wallet.entity");
|
43
|
+
Object.defineProperty(exports, "PaymentWalletEntity", { enumerable: true, get: function () { return payment_wallet_entity_1.PaymentWalletEntity; } });
|
44
|
+
var payment_entity_1 = require("./payment.entity");
|
45
|
+
Object.defineProperty(exports, "PaymentEntity", { enumerable: true, get: function () { return payment_entity_1.PaymentEntity; } });
|
34
46
|
var rating_entity_1 = require("./rating.entity");
|
35
47
|
Object.defineProperty(exports, "RatingEntity", { enumerable: true, get: function () { return rating_entity_1.RatingEntity; } });
|
36
48
|
var sponsorship_value_entity_1 = require("./sponsorship-value.entity");
|
@@ -0,0 +1,22 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.PaymentCardEntity = void 0;
|
4
|
+
var PaymentCardEntity = /** @class */ (function () {
|
5
|
+
// #endregion Properties (3)
|
6
|
+
// #region Constructors (1)
|
7
|
+
function PaymentCardEntity(data) {
|
8
|
+
// #region Properties (3)
|
9
|
+
this.brand = '';
|
10
|
+
this.maskedNumber = '';
|
11
|
+
this.tokenId = '';
|
12
|
+
if (data) {
|
13
|
+
for (var key in data) {
|
14
|
+
if (data.hasOwnProperty(key) && key in this) {
|
15
|
+
this[key] = data[key];
|
16
|
+
}
|
17
|
+
}
|
18
|
+
}
|
19
|
+
}
|
20
|
+
return PaymentCardEntity;
|
21
|
+
}());
|
22
|
+
exports.PaymentCardEntity = PaymentCardEntity;
|
@@ -0,0 +1,20 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.PaymentCashEntity = void 0;
|
4
|
+
var PaymentCashEntity = /** @class */ (function () {
|
5
|
+
// #endregion Properties (1)
|
6
|
+
// #region Constructors (1)
|
7
|
+
function PaymentCashEntity(data) {
|
8
|
+
// #region Properties (1)
|
9
|
+
this.changeFor = 0;
|
10
|
+
if (data) {
|
11
|
+
for (var key in data) {
|
12
|
+
if (data.hasOwnProperty(key) && key in this) {
|
13
|
+
this[key] = data[key];
|
14
|
+
}
|
15
|
+
}
|
16
|
+
}
|
17
|
+
}
|
18
|
+
return PaymentCashEntity;
|
19
|
+
}());
|
20
|
+
exports.PaymentCashEntity = PaymentCashEntity;
|
@@ -0,0 +1,20 @@
|
|
1
|
+
import { PaymentChannelEnum } from '../enums/payment-channel.enum';
|
2
|
+
import { PaymentModeEnum } from '../enums/payment-mode.enum';
|
3
|
+
import { PaymentTypeEnum } from '../enums/payment-type.enum';
|
4
|
+
import { IPaymentMethodOption } from '../interfaces';
|
5
|
+
export declare class PaymentMethodOptionEntity implements IPaymentMethodOption {
|
6
|
+
active: boolean;
|
7
|
+
channel: PaymentChannelEnum;
|
8
|
+
createdAt: Date;
|
9
|
+
fee: number;
|
10
|
+
id: string;
|
11
|
+
index: number;
|
12
|
+
maxAmount: number;
|
13
|
+
minAmount: number;
|
14
|
+
mode: PaymentModeEnum;
|
15
|
+
name: string;
|
16
|
+
token: string;
|
17
|
+
type: PaymentTypeEnum;
|
18
|
+
updatedAt: Date;
|
19
|
+
constructor(data?: Partial<PaymentMethodOptionEntity>);
|
20
|
+
}
|
@@ -0,0 +1,35 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.PaymentMethodOptionEntity = void 0;
|
4
|
+
var payment_channel_enum_1 = require("../enums/payment-channel.enum");
|
5
|
+
var payment_mode_enum_1 = require("../enums/payment-mode.enum");
|
6
|
+
var payment_type_enum_1 = require("../enums/payment-type.enum");
|
7
|
+
var PaymentMethodOptionEntity = /** @class */ (function () {
|
8
|
+
// #endregion Properties (13)
|
9
|
+
// #region Constructors (1)
|
10
|
+
function PaymentMethodOptionEntity(data) {
|
11
|
+
// #region Properties (13)
|
12
|
+
this.active = false;
|
13
|
+
this.channel = payment_channel_enum_1.PaymentChannelEnum.AUTOMATION;
|
14
|
+
this.createdAt = new Date();
|
15
|
+
this.fee = 0;
|
16
|
+
this.id = '';
|
17
|
+
this.index = 0;
|
18
|
+
this.maxAmount = 0;
|
19
|
+
this.minAmount = 0;
|
20
|
+
this.mode = payment_mode_enum_1.PaymentModeEnum.MANUAL;
|
21
|
+
this.name = '';
|
22
|
+
this.token = '';
|
23
|
+
this.type = payment_type_enum_1.PaymentTypeEnum.CREDIT_CARD;
|
24
|
+
this.updatedAt = new Date();
|
25
|
+
if (data) {
|
26
|
+
for (var key in data) {
|
27
|
+
if (data.hasOwnProperty(key) && key in this) {
|
28
|
+
this[key] = data[key];
|
29
|
+
}
|
30
|
+
}
|
31
|
+
}
|
32
|
+
}
|
33
|
+
return PaymentMethodOptionEntity;
|
34
|
+
}());
|
35
|
+
exports.PaymentMethodOptionEntity = PaymentMethodOptionEntity;
|
@@ -1,19 +1,20 @@
|
|
1
|
-
import {
|
2
|
-
import {
|
3
|
-
import {
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
1
|
+
import { PaymentTypeEnum } from '..';
|
2
|
+
import { IPaymentMethod } from '../interfaces';
|
3
|
+
import { PaymentCardEntity } from './payment-card.entity';
|
4
|
+
import { PaymentCashEntity } from './payment-cash.entity';
|
5
|
+
import { PaymentPixEntity } from './payment-pix.entity';
|
6
|
+
import { PaymentWalletEntity } from './payment-wallet.entity';
|
7
|
+
export declare class PaymentMethodEntity implements IPaymentMethod {
|
8
|
+
card?: PaymentCardEntity | null;
|
9
|
+
cash?: PaymentCashEntity | null;
|
10
|
+
code: string;
|
11
|
+
currency: 'BRL';
|
9
12
|
id: string;
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
type: PaymentTypeEnum;
|
17
|
-
updatedAt: Date;
|
13
|
+
method: PaymentTypeEnum;
|
14
|
+
pix?: PaymentPixEntity | null;
|
15
|
+
prepaid: boolean;
|
16
|
+
type: 'ONLINE' | 'OFFLINE';
|
17
|
+
value: number;
|
18
|
+
wallet?: PaymentWalletEntity | null;
|
18
19
|
constructor(data?: Partial<PaymentMethodEntity>);
|
19
20
|
}
|
@@ -1,27 +1,23 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
3
|
exports.PaymentMethodEntity = void 0;
|
4
|
-
var
|
5
|
-
var payment_mode_enum_1 = require("../enums/payment-mode.enum");
|
6
|
-
var payment_type_enum_1 = require("../enums/payment-type.enum");
|
4
|
+
var __1 = require("..");
|
7
5
|
var PaymentMethodEntity = /** @class */ (function () {
|
8
|
-
// #endregion Properties (
|
6
|
+
// #endregion Properties (11)
|
9
7
|
// #region Constructors (1)
|
10
8
|
function PaymentMethodEntity(data) {
|
11
|
-
// #region Properties (
|
12
|
-
this.
|
13
|
-
this.
|
14
|
-
this.
|
15
|
-
this.
|
9
|
+
// #region Properties (11)
|
10
|
+
this.card = null;
|
11
|
+
this.cash = null;
|
12
|
+
this.code = '';
|
13
|
+
this.currency = 'BRL';
|
16
14
|
this.id = '';
|
17
|
-
this.
|
18
|
-
this.
|
19
|
-
this.
|
20
|
-
this.
|
21
|
-
this.
|
22
|
-
this.
|
23
|
-
this.type = payment_type_enum_1.PaymentTypeEnum.CREDIT_CARD;
|
24
|
-
this.updatedAt = new Date();
|
15
|
+
this.method = __1.PaymentTypeEnum.CASH;
|
16
|
+
this.pix = null;
|
17
|
+
this.prepaid = false;
|
18
|
+
this.type = 'OFFLINE';
|
19
|
+
this.value = 0;
|
20
|
+
this.wallet = null;
|
25
21
|
if (data) {
|
26
22
|
for (var key in data) {
|
27
23
|
if (data.hasOwnProperty(key) && key in this) {
|
@@ -0,0 +1,21 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.PaymentPixEntity = void 0;
|
4
|
+
var PaymentPixEntity = /** @class */ (function () {
|
5
|
+
// #endregion Properties (2)
|
6
|
+
// #region Constructors (1)
|
7
|
+
function PaymentPixEntity(data) {
|
8
|
+
// #region Properties (2)
|
9
|
+
this.pixKey = '';
|
10
|
+
this.urlQrImage = '';
|
11
|
+
if (data) {
|
12
|
+
for (var key in data) {
|
13
|
+
if (data.hasOwnProperty(key) && key in this) {
|
14
|
+
this[key] = data[key];
|
15
|
+
}
|
16
|
+
}
|
17
|
+
}
|
18
|
+
}
|
19
|
+
return PaymentPixEntity;
|
20
|
+
}());
|
21
|
+
exports.PaymentPixEntity = PaymentPixEntity;
|
@@ -0,0 +1,20 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.PaymentWalletEntity = void 0;
|
4
|
+
var PaymentWalletEntity = /** @class */ (function () {
|
5
|
+
// #endregion Properties (1)
|
6
|
+
// #region Constructors (1)
|
7
|
+
function PaymentWalletEntity(data) {
|
8
|
+
// #region Properties (1)
|
9
|
+
this.name = '';
|
10
|
+
if (data) {
|
11
|
+
for (var key in data) {
|
12
|
+
if (data.hasOwnProperty(key) && key in this) {
|
13
|
+
this[key] = data[key];
|
14
|
+
}
|
15
|
+
}
|
16
|
+
}
|
17
|
+
}
|
18
|
+
return PaymentWalletEntity;
|
19
|
+
}());
|
20
|
+
exports.PaymentWalletEntity = PaymentWalletEntity;
|
@@ -0,0 +1,8 @@
|
|
1
|
+
import { IPayment } from '../interfaces';
|
2
|
+
import { PaymentMethodEntity } from './payment-method.entity';
|
3
|
+
export declare class PaymentEntity implements IPayment {
|
4
|
+
methods: PaymentMethodEntity[];
|
5
|
+
pending: number;
|
6
|
+
prepaid: number;
|
7
|
+
constructor(data?: Partial<PaymentEntity>);
|
8
|
+
}
|
@@ -0,0 +1,29 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.PaymentEntity = void 0;
|
4
|
+
var payment_method_entity_1 = require("./payment-method.entity");
|
5
|
+
var PaymentEntity = /** @class */ (function () {
|
6
|
+
// #endregion Properties (3)
|
7
|
+
// #region Constructors (1)
|
8
|
+
function PaymentEntity(data) {
|
9
|
+
// #region Properties (3)
|
10
|
+
this.methods = [];
|
11
|
+
this.pending = 0;
|
12
|
+
this.prepaid = 0;
|
13
|
+
if (data) {
|
14
|
+
for (var key in data) {
|
15
|
+
if (data.hasOwnProperty(key) && key in this) {
|
16
|
+
this[key] = data[key];
|
17
|
+
}
|
18
|
+
}
|
19
|
+
if (data.methods) {
|
20
|
+
this.methods = data.methods.map(function (method) { return new payment_method_entity_1.PaymentMethodEntity(method); });
|
21
|
+
}
|
22
|
+
else {
|
23
|
+
this.methods = [];
|
24
|
+
}
|
25
|
+
}
|
26
|
+
}
|
27
|
+
return PaymentEntity;
|
28
|
+
}());
|
29
|
+
exports.PaymentEntity = PaymentEntity;
|
@@ -21,4 +21,5 @@ var PaymentTypeEnum;
|
|
21
21
|
PaymentTypeEnum["GIFT_CARD"] = "GIFT_CARD";
|
22
22
|
PaymentTypeEnum["VOUCHER"] = "VOUCHER";
|
23
23
|
PaymentTypeEnum["BILLING"] = "BILLING";
|
24
|
+
PaymentTypeEnum["BANK_SLIP"] = "BANK_SLIP";
|
24
25
|
})(PaymentTypeEnum || (exports.PaymentTypeEnum = PaymentTypeEnum = {}));
|
@@ -0,0 +1,18 @@
|
|
1
|
+
import { PaymentChannelEnum } from '../enums/payment-channel.enum';
|
2
|
+
import { PaymentModeEnum } from '../enums/payment-mode.enum';
|
3
|
+
import { PaymentTypeEnum } from '../enums/payment-type.enum';
|
4
|
+
export interface IPaymentMethodOption {
|
5
|
+
active: boolean;
|
6
|
+
channel: PaymentChannelEnum;
|
7
|
+
createdAt: Date;
|
8
|
+
fee: number;
|
9
|
+
id: string;
|
10
|
+
index: number;
|
11
|
+
maxAmount: number;
|
12
|
+
minAmount: number;
|
13
|
+
mode: PaymentModeEnum;
|
14
|
+
name: string;
|
15
|
+
token: string;
|
16
|
+
type: PaymentTypeEnum;
|
17
|
+
updatedAt: Date;
|
18
|
+
}
|
@@ -1,18 +1,18 @@
|
|
1
|
-
import {
|
2
|
-
import {
|
3
|
-
import {
|
1
|
+
import { PaymentTypeEnum } from '..';
|
2
|
+
import { IPaymentCard } from './i-payment-card';
|
3
|
+
import { IPaymentCash } from './i-payment-cash';
|
4
|
+
import { IPaymentPix } from './i-payment-pix';
|
5
|
+
import { IPaymentWallet } from './i-payment-wallet';
|
4
6
|
export interface IPaymentMethod {
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
7
|
+
card?: IPaymentCard | null;
|
8
|
+
cash?: IPaymentCash | null;
|
9
|
+
code: string;
|
10
|
+
currency: 'BRL';
|
9
11
|
id: string;
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
type: PaymentTypeEnum;
|
17
|
-
updatedAt: Date;
|
12
|
+
method: PaymentTypeEnum;
|
13
|
+
pix?: IPaymentPix | null;
|
14
|
+
prepaid: boolean;
|
15
|
+
type: 'ONLINE' | 'OFFLINE';
|
16
|
+
value: number;
|
17
|
+
wallet?: IPaymentWallet | null;
|
18
18
|
}
|
@@ -8,10 +8,16 @@ export { IDeliveryAreaFixed } from './i-delivery-area-fixed';
|
|
8
8
|
export { IMessagerChannel } from './i-messager-channel';
|
9
9
|
export { IMobyoApiConfig } from './i-mobyo-api-config';
|
10
10
|
export { IOrigin } from './i-origin';
|
11
|
+
export { IPayment } from './i-payment';
|
12
|
+
export { IPaymentCard } from './i-payment-card';
|
13
|
+
export { IPaymentCash } from './i-payment-cash';
|
11
14
|
export { IPaymentMethod } from './i-payment-method';
|
15
|
+
export { IPaymentMethodOption } from './i-payment-method-option';
|
16
|
+
export { IPaymentPix } from './i-payment-pix';
|
12
17
|
export { IPaymentProvider } from './i-payment-provider';
|
13
18
|
export { IPaymentProviderAgent } from './i-payment-provider-agent';
|
14
19
|
export { IPaymentToken } from './i-payment-token';
|
15
20
|
export { IPaymentTokenData } from './i-payment-token-data';
|
21
|
+
export { IPaymentWallet } from './i-payment-wallet';
|
16
22
|
export { IRating } from './i-rating';
|
17
23
|
export { ISponsorshipValue } from './i-sponsorship-value';
|
package/dist/package.json
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
import { AddressEntity,
|
1
|
+
import { AddressEntity, PaymentProviderEntity } from '../../general';
|
2
2
|
import { DocTypeEnum } from '../../general/enums';
|
3
3
|
import { IPartner } from '../interfaces';
|
4
4
|
export declare class PartnerEntity implements IPartner {
|
@@ -14,7 +14,6 @@ export declare class PartnerEntity implements IPartner {
|
|
14
14
|
logoUrl?: string;
|
15
15
|
name: string;
|
16
16
|
paymentProvider: PaymentProviderEntity;
|
17
|
-
paymentsMethods: PaymentMethodEntity[];
|
18
17
|
phoneNumber: string;
|
19
18
|
sandbox: boolean;
|
20
19
|
tags: string[];
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import { IAddress,
|
1
|
+
import { IAddress, IPaymentProvider } from '../../general';
|
2
2
|
import { DocTypeEnum } from '../../general/enums';
|
3
3
|
export interface IPartner {
|
4
4
|
active: boolean;
|
@@ -13,7 +13,6 @@ export interface IPartner {
|
|
13
13
|
logoUrl?: string;
|
14
14
|
name: string;
|
15
15
|
paymentProvider: IPaymentProvider;
|
16
|
-
paymentsMethods: IPaymentMethod[];
|
17
16
|
phoneNumber: string;
|
18
17
|
sandbox: boolean;
|
19
18
|
tags: string[];
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { FeatureEntity } from '../../feature';
|
2
|
-
import { CustomVariableEntity, IntervalTypeEnum } from '../../general';
|
2
|
+
import { CustomVariableEntity, IntervalTypeEnum, PaymentEntity } from '../../general';
|
3
3
|
import { InvoiceEntity } from '../../invoice';
|
4
4
|
import { SubscriptionStatusEnum } from '../enums';
|
5
5
|
import { ISubscription } from '../interfaces/i-subscription';
|
@@ -32,5 +32,6 @@ export declare class SubscriptionEntity implements ISubscription {
|
|
32
32
|
status: SubscriptionStatusEnum;
|
33
33
|
tags: string[];
|
34
34
|
updatedAt: Date;
|
35
|
+
payment: PaymentEntity;
|
35
36
|
constructor(data?: Partial<SubscriptionEntity>);
|
36
37
|
}
|
@@ -5,10 +5,10 @@ var general_1 = require("../../general");
|
|
5
5
|
var enums_1 = require("../enums");
|
6
6
|
var subscription_company_entity_1 = require("./subscription-company.entity");
|
7
7
|
var SubscriptionEntity = /** @class */ (function () {
|
8
|
-
// #endregion Properties (
|
8
|
+
// #endregion Properties (27)
|
9
9
|
// #region Constructors (1)
|
10
10
|
function SubscriptionEntity(data) {
|
11
|
-
// #region Properties (
|
11
|
+
// #region Properties (27)
|
12
12
|
this.amount = 0;
|
13
13
|
this.appId = '';
|
14
14
|
this.cancellationReason = '';
|
@@ -34,6 +34,7 @@ var SubscriptionEntity = /** @class */ (function () {
|
|
34
34
|
this.status = enums_1.SubscriptionStatusEnum.PENDING;
|
35
35
|
this.tags = [];
|
36
36
|
this.updatedAt = new Date();
|
37
|
+
this.payment = new general_1.PaymentEntity();
|
37
38
|
if (data) {
|
38
39
|
for (var key in data) {
|
39
40
|
if (data.hasOwnProperty(key) && key in this) {
|
@@ -1,5 +1,6 @@
|
|
1
1
|
import { IFeature } from '../../feature';
|
2
2
|
import { ICustomVariable, IntervalTypeEnum } from '../../general';
|
3
|
+
import { IPayment } from '../../general/interfaces/i-payment';
|
3
4
|
import { IInvoice } from '../../invoice';
|
4
5
|
import { SubscriptionStatusEnum } from '../enums';
|
5
6
|
import { ISubscriptionCompany } from './i-subscription-company';
|
@@ -17,6 +18,7 @@ export interface ISubscription {
|
|
17
18
|
features: IFeature[];
|
18
19
|
id: string;
|
19
20
|
interval: number;
|
21
|
+
payment: IPayment;
|
20
22
|
intervalType: IntervalTypeEnum;
|
21
23
|
invoices: IInvoice[];
|
22
24
|
items: ISubscriptionItem[];
|