@doctocar/tooling 0.3.1-30 → 0.3.1-32
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.
- package/dist/errors/enums/cloudFunctions/entities/RedeemPromoCodeForEntityErrorCodes.enum.d.ts +1 -1
- package/dist/errors/enums/cloudFunctions/entities/RedeemPromoCodeForEntityErrorCodes.enum.js +1 -1
- package/dist/firebase/cloudFunctions/enums/testUsers/TestUsersEmails.enum.d.ts +1 -0
- package/dist/firebase/cloudFunctions/enums/testUsers/TestUsersEmails.enum.js +1 -0
- package/dist/firebase/cloudFunctions/enums/testUsers/TestUsersScenarios.enum.d.ts +1 -0
- package/dist/firebase/cloudFunctions/enums/testUsers/TestUsersScenarios.enum.js +1 -0
- package/dist/firebase/cloudFunctions/maps/testUsers/TestUsersEmailsScenariosMap.js +1 -0
- package/dist/firebase/firestore/constants/index.d.ts +2 -2
- package/dist/firebase/firestore/constants/index.js +2 -2
- package/dist/firebase/firestore/constants/platformBalances/firestorePlatformBalancesSchemaVersion.enum.d.ts +1 -0
- package/dist/firebase/firestore/constants/platformBalances/firestorePlatformBalancesSchemaVersion.enum.js +4 -0
- package/dist/firebase/firestore/constants/platformBalances/index.d.ts +1 -0
- package/dist/firebase/firestore/constants/platformBalances/index.js +17 -0
- package/dist/firebase/firestore/constants/platformBalancesLedgerEntry/firestorePlatformBalancesLedgerEntrySchemaVersion.enum.d.ts +1 -0
- package/dist/firebase/firestore/constants/platformBalancesLedgerEntry/firestorePlatformBalancesLedgerEntrySchemaVersion.enum.js +4 -0
- package/dist/firebase/firestore/constants/platformBalancesLedgerEntry/index.d.ts +1 -0
- package/dist/firebase/firestore/constants/platformBalancesLedgerEntry/index.js +17 -0
- package/dist/firebase/firestore/enums/FirestoreCollections.enum.d.ts +2 -2
- package/dist/firebase/firestore/enums/FirestoreCollections.enum.js +2 -2
- package/dist/firebase/firestore/enums/index.d.ts +1 -1
- package/dist/firebase/firestore/enums/index.js +1 -1
- package/dist/firebase/firestore/enums/platformBalancesLedgerEntry/PlatformBalancesLedgerEntryContextReferenceType.enum.d.ts +6 -0
- package/dist/firebase/firestore/enums/platformBalancesLedgerEntry/PlatformBalancesLedgerEntryContextReferenceType.enum.js +10 -0
- package/dist/firebase/firestore/enums/platformBalancesLedgerEntry/PlatformBalancesLedgerEntryReason.enum.d.ts +10 -0
- package/dist/firebase/firestore/enums/platformBalancesLedgerEntry/PlatformBalancesLedgerEntryReason.enum.js +14 -0
- package/dist/firebase/firestore/enums/platformBalancesLedgerEntry/PlatformBalancesLedgerEntryType.enum.d.ts +4 -0
- package/dist/firebase/firestore/enums/platformBalancesLedgerEntry/PlatformBalancesLedgerEntryType.enum.js +8 -0
- package/dist/firebase/firestore/enums/platformBalancesLedgerEntry/index.d.ts +3 -0
- package/dist/firebase/firestore/enums/platformBalancesLedgerEntry/index.js +19 -0
- package/dist/firebase/firestore/maps/FirestoreCollectionDocumentTypeMap.d.ts +3 -3
- package/dist/firebase/firestore/types/entities/FirestoreEntityDocument.type.d.ts +1 -1
- package/dist/firebase/firestore/types/index.d.ts +2 -2
- package/dist/firebase/firestore/types/index.js +2 -2
- package/dist/firebase/firestore/types/platformBalances/FirestorePlatformBalancesDocument.type.d.ts +17 -0
- package/dist/firebase/firestore/types/platformBalances/FirestorePlatformBalancesDocument.type.js +2 -0
- package/dist/firebase/firestore/types/platformBalances/index.d.ts +1 -0
- package/dist/firebase/firestore/types/platformBalances/index.js +17 -0
- package/dist/firebase/firestore/types/platformBalancesLedgerEntryDocument/FirestorePlatformBalancesLedgerEntryDocument.type.d.ts +21 -0
- package/dist/firebase/firestore/types/platformBalancesLedgerEntryDocument/FirestorePlatformBalancesLedgerEntryDocument.type.js +2 -0
- package/dist/firebase/firestore/types/platformBalancesLedgerEntryDocument/index.d.ts +1 -0
- package/dist/firebase/firestore/types/platformBalancesLedgerEntryDocument/index.js +17 -0
- package/dist/firebase/firestore/utils/stubs/entities/firestoreEntityDocumentStub.js +1 -1
- package/dist/firebase/firestore/utils/stubs/index.d.ts +2 -2
- package/dist/firebase/firestore/utils/stubs/index.js +2 -2
- package/dist/firebase/firestore/utils/stubs/platformBalances/firestorePlatformBalancesDocumentStub.d.ts +2 -0
- package/dist/firebase/firestore/utils/stubs/platformBalances/firestorePlatformBalancesDocumentStub.js +24 -0
- package/dist/firebase/firestore/utils/stubs/platformBalances/index.d.ts +1 -0
- package/dist/firebase/firestore/utils/stubs/platformBalances/index.js +17 -0
- package/dist/firebase/firestore/utils/stubs/platformBalancesLedgerEntry/firestorePlatformBalancesLedgerEntryDocumentStub.d.ts +2 -0
- package/dist/firebase/firestore/utils/stubs/platformBalancesLedgerEntry/firestorePlatformBalancesLedgerEntryDocumentStub.js +27 -0
- package/dist/firebase/firestore/utils/stubs/platformBalancesLedgerEntry/index.d.ts +1 -0
- package/dist/firebase/firestore/utils/stubs/platformBalancesLedgerEntry/index.js +17 -0
- package/package.json +1 -1
package/dist/errors/enums/cloudFunctions/entities/RedeemPromoCodeForEntityErrorCodes.enum.d.ts
CHANGED
|
@@ -12,7 +12,7 @@ export declare enum RedeemPromoCodeForEntityErrorCodes {
|
|
|
12
12
|
PROMO_CODE_MAX_REDEMPTIONS_REACHED = "PROMO_CODE_MAX_REDEMPTIONS_REACHED",
|
|
13
13
|
PROMO_CODE_FIRST_ORDER_ONLY_NOT_ELIGIBLE = "PROMO_CODE_FIRST_ORDER_ONLY_NOT_ELIGIBLE",
|
|
14
14
|
PROMO_CODE_ALREADY_REDEEMED_BY_ENTITY = "PROMO_CODE_ALREADY_REDEEMED_BY_ENTITY",
|
|
15
|
-
|
|
15
|
+
PLATFORM_BALANCES_DOCUMENT_NOT_FOUND = "PLATFORM_BALANCES_DOCUMENT_NOT_FOUND",
|
|
16
16
|
ERROR_CREDITING_ENTITY = "ERROR_CREDITING_ENTITY",
|
|
17
17
|
ERROR_REDEEMING_PROMO_CODE = "ERROR_REDEEMING_PROMO_CODE"
|
|
18
18
|
}
|
package/dist/errors/enums/cloudFunctions/entities/RedeemPromoCodeForEntityErrorCodes.enum.js
CHANGED
|
@@ -16,7 +16,7 @@ var RedeemPromoCodeForEntityErrorCodes;
|
|
|
16
16
|
RedeemPromoCodeForEntityErrorCodes["PROMO_CODE_MAX_REDEMPTIONS_REACHED"] = "PROMO_CODE_MAX_REDEMPTIONS_REACHED";
|
|
17
17
|
RedeemPromoCodeForEntityErrorCodes["PROMO_CODE_FIRST_ORDER_ONLY_NOT_ELIGIBLE"] = "PROMO_CODE_FIRST_ORDER_ONLY_NOT_ELIGIBLE";
|
|
18
18
|
RedeemPromoCodeForEntityErrorCodes["PROMO_CODE_ALREADY_REDEEMED_BY_ENTITY"] = "PROMO_CODE_ALREADY_REDEEMED_BY_ENTITY";
|
|
19
|
-
RedeemPromoCodeForEntityErrorCodes["
|
|
19
|
+
RedeemPromoCodeForEntityErrorCodes["PLATFORM_BALANCES_DOCUMENT_NOT_FOUND"] = "PLATFORM_BALANCES_DOCUMENT_NOT_FOUND";
|
|
20
20
|
RedeemPromoCodeForEntityErrorCodes["ERROR_CREDITING_ENTITY"] = "ERROR_CREDITING_ENTITY";
|
|
21
21
|
RedeemPromoCodeForEntityErrorCodes["ERROR_REDEEMING_PROMO_CODE"] = "ERROR_REDEEMING_PROMO_CODE";
|
|
22
22
|
})(RedeemPromoCodeForEntityErrorCodes || (exports.RedeemPromoCodeForEntityErrorCodes = RedeemPromoCodeForEntityErrorCodes = {}));
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
export declare enum TestUsersEmails {
|
|
2
2
|
CUSTOMER_USER_WITH_ONBOARDED_PERSONAL_ENTITY = "test.cust.perso@dctest.fr",
|
|
3
|
+
CUSTOMER_USER_WITH_ONBOARDED_SAS_COMPANY_ENTITY = "test.cust.sas@dctest.fr",
|
|
3
4
|
SERVICE_PROVIDER_USER_WITH_ONBOARDED_SOLO_COMPANY = "test.sp.solo@dctest.fr"
|
|
4
5
|
}
|
|
@@ -5,5 +5,6 @@ const constants_1 = require("../../constants");
|
|
|
5
5
|
var TestUsersEmails;
|
|
6
6
|
(function (TestUsersEmails) {
|
|
7
7
|
TestUsersEmails["CUSTOMER_USER_WITH_ONBOARDED_PERSONAL_ENTITY"] = "test.cust.perso@dctest.fr";
|
|
8
|
+
TestUsersEmails["CUSTOMER_USER_WITH_ONBOARDED_SAS_COMPANY_ENTITY"] = "test.cust.sas@dctest.fr";
|
|
8
9
|
TestUsersEmails["SERVICE_PROVIDER_USER_WITH_ONBOARDED_SOLO_COMPANY"] = "test.sp.solo@dctest.fr";
|
|
9
10
|
})(TestUsersEmails || (exports.TestUsersEmails = TestUsersEmails = {}));
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
export declare enum TestUsersScenarios {
|
|
2
2
|
CUSTOMER_USER_WITH_ONBOARDED_PERSONAL_ENTITY = "CUSTOMER_USER_WITH_ONBOARDED_PERSONAL_ENTITY",
|
|
3
|
+
CUSTOMER_USER_WITH_ONBOARDED_SAS_COMPANY_ENTITY = "CUSTOMER_USER_WITH_ONBOARDED_SAS_COMPANY_ENTITY",
|
|
3
4
|
SERVICE_PROVIDER_USER_WITH_ONBOARDED_SOLO_COMPANY = "SERVICE_PROVIDER_USER_WITH_ONBOARDED_SOLO_COMPANY"
|
|
4
5
|
}
|
|
@@ -4,5 +4,6 @@ exports.TestUsersScenarios = void 0;
|
|
|
4
4
|
var TestUsersScenarios;
|
|
5
5
|
(function (TestUsersScenarios) {
|
|
6
6
|
TestUsersScenarios["CUSTOMER_USER_WITH_ONBOARDED_PERSONAL_ENTITY"] = "CUSTOMER_USER_WITH_ONBOARDED_PERSONAL_ENTITY";
|
|
7
|
+
TestUsersScenarios["CUSTOMER_USER_WITH_ONBOARDED_SAS_COMPANY_ENTITY"] = "CUSTOMER_USER_WITH_ONBOARDED_SAS_COMPANY_ENTITY";
|
|
7
8
|
TestUsersScenarios["SERVICE_PROVIDER_USER_WITH_ONBOARDED_SOLO_COMPANY"] = "SERVICE_PROVIDER_USER_WITH_ONBOARDED_SOLO_COMPANY";
|
|
8
9
|
})(TestUsersScenarios || (exports.TestUsersScenarios = TestUsersScenarios = {}));
|
|
@@ -4,5 +4,6 @@ exports.TestUsersEmailsScenariosMap = void 0;
|
|
|
4
4
|
const enums_1 = require("../../enums");
|
|
5
5
|
exports.TestUsersEmailsScenariosMap = {
|
|
6
6
|
[enums_1.TestUsersEmails.CUSTOMER_USER_WITH_ONBOARDED_PERSONAL_ENTITY]: enums_1.TestUsersScenarios.CUSTOMER_USER_WITH_ONBOARDED_PERSONAL_ENTITY,
|
|
7
|
+
[enums_1.TestUsersEmails.CUSTOMER_USER_WITH_ONBOARDED_SAS_COMPANY_ENTITY]: enums_1.TestUsersScenarios.CUSTOMER_USER_WITH_ONBOARDED_SAS_COMPANY_ENTITY,
|
|
7
8
|
[enums_1.TestUsersEmails.SERVICE_PROVIDER_USER_WITH_ONBOARDED_SOLO_COMPANY]: enums_1.TestUsersScenarios.SERVICE_PROVIDER_USER_WITH_ONBOARDED_SOLO_COMPANY,
|
|
8
9
|
};
|
|
@@ -9,6 +9,6 @@ export * from "./orderIdempotencyWindowInMs.constant";
|
|
|
9
9
|
export * from "./maximumSlotCapacity.constant";
|
|
10
10
|
export * from "./walletLedgerEntry";
|
|
11
11
|
export * from "./wallets";
|
|
12
|
-
export * from "./
|
|
13
|
-
export * from "./
|
|
12
|
+
export * from "./platformBalancesLedgerEntry";
|
|
13
|
+
export * from "./platformBalances";
|
|
14
14
|
export * from "./sandboxDocumentIdPrefix.constant";
|
|
@@ -25,6 +25,6 @@ __exportStar(require("./orderIdempotencyWindowInMs.constant"), exports);
|
|
|
25
25
|
__exportStar(require("./maximumSlotCapacity.constant"), exports);
|
|
26
26
|
__exportStar(require("./walletLedgerEntry"), exports);
|
|
27
27
|
__exportStar(require("./wallets"), exports);
|
|
28
|
-
__exportStar(require("./
|
|
29
|
-
__exportStar(require("./
|
|
28
|
+
__exportStar(require("./platformBalancesLedgerEntry"), exports);
|
|
29
|
+
__exportStar(require("./platformBalances"), exports);
|
|
30
30
|
__exportStar(require("./sandboxDocumentIdPrefix.constant"), exports);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const FIRESTORE_PLATFORM_BALANCES_SCHEMA_VERSION: 1;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./firestorePlatformBalancesSchemaVersion.enum";
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./firestorePlatformBalancesSchemaVersion.enum"), exports);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const FIRESTORE_PLATFORM_BALANCES_LEDGER_ENTRY_SCHEMA_VERSION: 1;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./firestorePlatformBalancesLedgerEntrySchemaVersion.enum";
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./firestorePlatformBalancesLedgerEntrySchemaVersion.enum"), exports);
|
|
@@ -31,8 +31,8 @@ export declare enum FirestoreCollections {
|
|
|
31
31
|
WALLETS = "wallets",
|
|
32
32
|
WALLETS_LEDGER_ENTRIES = "wallets_ledger_entries",
|
|
33
33
|
WALLETS_WITHDRAWAL_INTENTS = "wallets_withdrawal_intents",
|
|
34
|
-
|
|
35
|
-
|
|
34
|
+
PLATFORM_BALANCES = "platform_balances",
|
|
35
|
+
PLATFORM_BALANCES_LEDGER_ENTRIES = "platform_balances_ledger_entries",
|
|
36
36
|
FUNCTIONS_DEPLOYMENT_RUNS = "functions_deployment_runs",
|
|
37
37
|
MARKETPLACE_FINANCIAL_REPORTS = "marketplace_financial_reports"
|
|
38
38
|
}
|
|
@@ -35,8 +35,8 @@ var FirestoreCollections;
|
|
|
35
35
|
FirestoreCollections["WALLETS"] = "wallets";
|
|
36
36
|
FirestoreCollections["WALLETS_LEDGER_ENTRIES"] = "wallets_ledger_entries";
|
|
37
37
|
FirestoreCollections["WALLETS_WITHDRAWAL_INTENTS"] = "wallets_withdrawal_intents";
|
|
38
|
-
FirestoreCollections["
|
|
39
|
-
FirestoreCollections["
|
|
38
|
+
FirestoreCollections["PLATFORM_BALANCES"] = "platform_balances";
|
|
39
|
+
FirestoreCollections["PLATFORM_BALANCES_LEDGER_ENTRIES"] = "platform_balances_ledger_entries";
|
|
40
40
|
FirestoreCollections["FUNCTIONS_DEPLOYMENT_RUNS"] = "functions_deployment_runs";
|
|
41
41
|
FirestoreCollections["MARKETPLACE_FINANCIAL_REPORTS"] = "marketplace_financial_reports";
|
|
42
42
|
})(FirestoreCollections || (exports.FirestoreCollections = FirestoreCollections = {}));
|
|
@@ -16,7 +16,7 @@ export * from "./operation";
|
|
|
16
16
|
export * from "./promoCode";
|
|
17
17
|
export * from "./walletLedgerEntry";
|
|
18
18
|
export * from "./walletWithdrawalIntents";
|
|
19
|
-
export * from "./
|
|
19
|
+
export * from "./platformBalancesLedgerEntry";
|
|
20
20
|
export * from "./ordersIssues";
|
|
21
21
|
export * from "./marketplaceFinancialReports";
|
|
22
22
|
export * from "./entities";
|
|
@@ -32,7 +32,7 @@ __exportStar(require("./operation"), exports);
|
|
|
32
32
|
__exportStar(require("./promoCode"), exports);
|
|
33
33
|
__exportStar(require("./walletLedgerEntry"), exports);
|
|
34
34
|
__exportStar(require("./walletWithdrawalIntents"), exports);
|
|
35
|
-
__exportStar(require("./
|
|
35
|
+
__exportStar(require("./platformBalancesLedgerEntry"), exports);
|
|
36
36
|
__exportStar(require("./ordersIssues"), exports);
|
|
37
37
|
__exportStar(require("./marketplaceFinancialReports"), exports);
|
|
38
38
|
__exportStar(require("./entities"), exports);
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.PlatformBalancesLedgerEntryContextReferenceType = void 0;
|
|
4
|
+
var PlatformBalancesLedgerEntryContextReferenceType;
|
|
5
|
+
(function (PlatformBalancesLedgerEntryContextReferenceType) {
|
|
6
|
+
PlatformBalancesLedgerEntryContextReferenceType["ORDER"] = "order";
|
|
7
|
+
PlatformBalancesLedgerEntryContextReferenceType["PROMO_CODE"] = "promo_code";
|
|
8
|
+
PlatformBalancesLedgerEntryContextReferenceType["REFERRAL"] = "referral";
|
|
9
|
+
PlatformBalancesLedgerEntryContextReferenceType["SUPPORT"] = "support";
|
|
10
|
+
})(PlatformBalancesLedgerEntryContextReferenceType || (exports.PlatformBalancesLedgerEntryContextReferenceType = PlatformBalancesLedgerEntryContextReferenceType = {}));
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export declare enum PlatformBalancesLedgerEntryReason {
|
|
2
|
+
REFERRAL_REWARD = "referral_reward",
|
|
3
|
+
PROMO_REWARD = "promo_reward",
|
|
4
|
+
CASHBACK = "cashback",
|
|
5
|
+
BOOKING_USAGE = "booking_usage",
|
|
6
|
+
BOOKING_REFUND = "booking_refund",
|
|
7
|
+
MANUAL_ADJUSTMENT = "manual_adjustment",
|
|
8
|
+
CUSTOMER_SUPPORT_COMPENSATION = "customer_support_compensation",
|
|
9
|
+
EXPIRED = "expired"
|
|
10
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.PlatformBalancesLedgerEntryReason = void 0;
|
|
4
|
+
var PlatformBalancesLedgerEntryReason;
|
|
5
|
+
(function (PlatformBalancesLedgerEntryReason) {
|
|
6
|
+
PlatformBalancesLedgerEntryReason["REFERRAL_REWARD"] = "referral_reward";
|
|
7
|
+
PlatformBalancesLedgerEntryReason["PROMO_REWARD"] = "promo_reward";
|
|
8
|
+
PlatformBalancesLedgerEntryReason["CASHBACK"] = "cashback";
|
|
9
|
+
PlatformBalancesLedgerEntryReason["BOOKING_USAGE"] = "booking_usage";
|
|
10
|
+
PlatformBalancesLedgerEntryReason["BOOKING_REFUND"] = "booking_refund";
|
|
11
|
+
PlatformBalancesLedgerEntryReason["MANUAL_ADJUSTMENT"] = "manual_adjustment";
|
|
12
|
+
PlatformBalancesLedgerEntryReason["CUSTOMER_SUPPORT_COMPENSATION"] = "customer_support_compensation";
|
|
13
|
+
PlatformBalancesLedgerEntryReason["EXPIRED"] = "expired";
|
|
14
|
+
})(PlatformBalancesLedgerEntryReason || (exports.PlatformBalancesLedgerEntryReason = PlatformBalancesLedgerEntryReason = {}));
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.PlatformBalancesLedgerEntryType = void 0;
|
|
4
|
+
var PlatformBalancesLedgerEntryType;
|
|
5
|
+
(function (PlatformBalancesLedgerEntryType) {
|
|
6
|
+
PlatformBalancesLedgerEntryType["CREDIT"] = "credit";
|
|
7
|
+
PlatformBalancesLedgerEntryType["DEBIT"] = "debit";
|
|
8
|
+
})(PlatformBalancesLedgerEntryType || (exports.PlatformBalancesLedgerEntryType = PlatformBalancesLedgerEntryType = {}));
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./PlatformBalancesLedgerEntryType.enum"), exports);
|
|
18
|
+
__exportStar(require("./PlatformBalancesLedgerEntryReason.enum"), exports);
|
|
19
|
+
__exportStar(require("./PlatformBalancesLedgerEntryContextReferenceType.enum"), exports);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { FirestoreCollections } from "../enums";
|
|
2
|
-
import type { FirestoreBookedSlotDocument, FirestoreDailyMetricsDocument, FirestoreDebugPublicConfigDocument, FirestoreDeviceTokenDocument, FirestoreEmailsBlacklistDocument, FirestoreEmailsSoftBounceDocument, FirestoreEntityDocument, FirestoreEntityMemberDocument, FirestoreEntityMemberInviteDocument, FirestoreEntityUniqueKeyDocument, FirestoreFunctionsDeploymentRunsDocument, FirestoreGlobalMetricsDocument, FirestoreInvoiceCounterDocument, FirestoreMarketplaceFinancialReportsDocument, FirestoreMessageDocument, FirestoreNotificationEventDeliveryStateDocument, FirestoreNotificationEventsPublicConfigDocument, FirestoreOnTaskExecutionStateDocument, FirestoreOrderDocument, FirestoreOrderIssueDocument, FirestoreOrderReviewDocument, FirestoreOrdersPublicConfigDocument, FirestorePaymentIntentDocument, FirestorePlatformPublicConfigDocument, FirestorePricingPublicConfigDocument, FirestoreServiceProviderUserPublicDocument, FirestorePromoCodeDocument, FirestorePromoCodeRedemptionDocument, FirestoreRateLimitDocument, FirestoreServicesPublicConfigDocument, FirestoreSlotDocument, FirestoreUserDocument, FirestoreUserUploadRateLimitDocument, FirestoreVehicleDocument,
|
|
2
|
+
import type { FirestoreBookedSlotDocument, FirestoreDailyMetricsDocument, FirestoreDebugPublicConfigDocument, FirestoreDeviceTokenDocument, FirestoreEmailsBlacklistDocument, FirestoreEmailsSoftBounceDocument, FirestoreEntityDocument, FirestoreEntityMemberDocument, FirestoreEntityMemberInviteDocument, FirestoreEntityUniqueKeyDocument, FirestoreFunctionsDeploymentRunsDocument, FirestoreGlobalMetricsDocument, FirestoreInvoiceCounterDocument, FirestoreMarketplaceFinancialReportsDocument, FirestoreMessageDocument, FirestoreNotificationEventDeliveryStateDocument, FirestoreNotificationEventsPublicConfigDocument, FirestoreOnTaskExecutionStateDocument, FirestoreOrderDocument, FirestoreOrderIssueDocument, FirestoreOrderReviewDocument, FirestoreOrdersPublicConfigDocument, FirestorePaymentIntentDocument, FirestorePlatformPublicConfigDocument, FirestorePricingPublicConfigDocument, FirestoreServiceProviderUserPublicDocument, FirestorePromoCodeDocument, FirestorePromoCodeRedemptionDocument, FirestoreRateLimitDocument, FirestoreServicesPublicConfigDocument, FirestoreSlotDocument, FirestoreUserDocument, FirestoreUserUploadRateLimitDocument, FirestoreVehicleDocument, FirestorePlatformBalancesDocument, FirestorePlatformBalancesLedgerEntryDocument, FirestoreWalletsDocument, FirestoreWalletsLedgerEntryDocument, FirestoreWalletsWithdrawalIntentsDocument } from "../types";
|
|
3
3
|
type FirestoreCollectionDocumentTypeMapBase = {
|
|
4
4
|
[FirestoreCollections.USERS]: FirestoreUserDocument;
|
|
5
5
|
[FirestoreCollections.DEVICE_TOKENS]: FirestoreDeviceTokenDocument;
|
|
@@ -7,8 +7,8 @@ type FirestoreCollectionDocumentTypeMapBase = {
|
|
|
7
7
|
[FirestoreCollections.WALLETS]: FirestoreWalletsDocument;
|
|
8
8
|
[FirestoreCollections.WALLETS_LEDGER_ENTRIES]: FirestoreWalletsLedgerEntryDocument;
|
|
9
9
|
[FirestoreCollections.WALLETS_WITHDRAWAL_INTENTS]: FirestoreWalletsWithdrawalIntentsDocument;
|
|
10
|
-
[FirestoreCollections.
|
|
11
|
-
[FirestoreCollections.
|
|
10
|
+
[FirestoreCollections.PLATFORM_BALANCES]: FirestorePlatformBalancesDocument;
|
|
11
|
+
[FirestoreCollections.PLATFORM_BALANCES_LEDGER_ENTRIES]: FirestorePlatformBalancesLedgerEntryDocument;
|
|
12
12
|
[FirestoreCollections.SLOTS]: FirestoreSlotDocument;
|
|
13
13
|
[FirestoreCollections.BOOKED_SLOTS]: FirestoreBookedSlotDocument;
|
|
14
14
|
[FirestoreCollections.MESSAGES]: FirestoreMessageDocument;
|
|
@@ -30,8 +30,8 @@ export * from "./notificationEvent";
|
|
|
30
30
|
export * from "./wallets";
|
|
31
31
|
export * from "./walletsLedgerEntryDocument";
|
|
32
32
|
export * from "./walletsWithdrawalIntents";
|
|
33
|
-
export * from "./
|
|
34
|
-
export * from "./
|
|
33
|
+
export * from "./platformBalances";
|
|
34
|
+
export * from "./platformBalancesLedgerEntryDocument";
|
|
35
35
|
export * from "./functionsDeploymentRuns";
|
|
36
36
|
export * from "./marketplaceFinancialReports";
|
|
37
37
|
export * from "./entities";
|
|
@@ -46,8 +46,8 @@ __exportStar(require("./notificationEvent"), exports);
|
|
|
46
46
|
__exportStar(require("./wallets"), exports);
|
|
47
47
|
__exportStar(require("./walletsLedgerEntryDocument"), exports);
|
|
48
48
|
__exportStar(require("./walletsWithdrawalIntents"), exports);
|
|
49
|
-
__exportStar(require("./
|
|
50
|
-
__exportStar(require("./
|
|
49
|
+
__exportStar(require("./platformBalances"), exports);
|
|
50
|
+
__exportStar(require("./platformBalancesLedgerEntryDocument"), exports);
|
|
51
51
|
__exportStar(require("./functionsDeploymentRuns"), exports);
|
|
52
52
|
__exportStar(require("./marketplaceFinancialReports"), exports);
|
|
53
53
|
__exportStar(require("./entities"), exports);
|
package/dist/firebase/firestore/types/platformBalances/FirestorePlatformBalancesDocument.type.d.ts
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import type { SupportedIsoCurrency } from "../../../../enums";
|
|
2
|
+
import type { FirestoreTimestamp } from "../FirestoreTimestamp.type";
|
|
3
|
+
export type FirestorePlatformBalancesDocument = {
|
|
4
|
+
schemaVersion: number;
|
|
5
|
+
ownerEntityId: string;
|
|
6
|
+
currency: SupportedIsoCurrency;
|
|
7
|
+
balances: {
|
|
8
|
+
availableInCents: number;
|
|
9
|
+
pendingInCents: number;
|
|
10
|
+
lifetimeEarnedInCents: number;
|
|
11
|
+
lifetimeSpentInCents: number;
|
|
12
|
+
updatedAt: FirestoreTimestamp;
|
|
13
|
+
};
|
|
14
|
+
createdAt: FirestoreTimestamp;
|
|
15
|
+
updatedAt: FirestoreTimestamp;
|
|
16
|
+
isTest: boolean;
|
|
17
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./FirestorePlatformBalancesDocument.type";
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./FirestorePlatformBalancesDocument.type"), exports);
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import type { SupportedIsoCurrency } from "../../../../enums";
|
|
2
|
+
import type { PlatformBalancesLedgerEntryContextReferenceType, PlatformBalancesLedgerEntryReason, PlatformBalancesLedgerEntryType } from "../../enums";
|
|
3
|
+
import type { FirestoreTimestamp } from "../FirestoreTimestamp.type";
|
|
4
|
+
export type FirestorePlatformBalancesLedgerEntryDocument = {
|
|
5
|
+
createdAt: FirestoreTimestamp;
|
|
6
|
+
effectiveAt: FirestoreTimestamp;
|
|
7
|
+
schemaVersion: number;
|
|
8
|
+
platformBalancesDocumentId: string;
|
|
9
|
+
type: PlatformBalancesLedgerEntryType;
|
|
10
|
+
reason: PlatformBalancesLedgerEntryReason;
|
|
11
|
+
amountInCents: number;
|
|
12
|
+
balanceBeforeInCents: number;
|
|
13
|
+
balanceAfterInCents: number;
|
|
14
|
+
currency: SupportedIsoCurrency;
|
|
15
|
+
context?: {
|
|
16
|
+
referenceId: string;
|
|
17
|
+
referenceType: PlatformBalancesLedgerEntryContextReferenceType;
|
|
18
|
+
metadata?: Record<string, string | number | boolean>;
|
|
19
|
+
};
|
|
20
|
+
isTest: boolean;
|
|
21
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./FirestorePlatformBalancesLedgerEntryDocument.type";
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./FirestorePlatformBalancesLedgerEntryDocument.type"), exports);
|
|
@@ -22,8 +22,8 @@ export * from "./ordersReviews";
|
|
|
22
22
|
export * from "./walletsLedgerEntry";
|
|
23
23
|
export * from "./wallets";
|
|
24
24
|
export * from "./walletsWithdrawalIntents";
|
|
25
|
-
export * from "./
|
|
26
|
-
export * from "./
|
|
25
|
+
export * from "./platformBalancesLedgerEntry";
|
|
26
|
+
export * from "./platformBalances";
|
|
27
27
|
export * from "./functionsDeploymentRuns";
|
|
28
28
|
export * from "./marketplaceFinancialReports";
|
|
29
29
|
export * from "./entities";
|
|
@@ -38,8 +38,8 @@ __exportStar(require("./ordersReviews"), exports);
|
|
|
38
38
|
__exportStar(require("./walletsLedgerEntry"), exports);
|
|
39
39
|
__exportStar(require("./wallets"), exports);
|
|
40
40
|
__exportStar(require("./walletsWithdrawalIntents"), exports);
|
|
41
|
-
__exportStar(require("./
|
|
42
|
-
__exportStar(require("./
|
|
41
|
+
__exportStar(require("./platformBalancesLedgerEntry"), exports);
|
|
42
|
+
__exportStar(require("./platformBalances"), exports);
|
|
43
43
|
__exportStar(require("./functionsDeploymentRuns"), exports);
|
|
44
44
|
__exportStar(require("./marketplaceFinancialReports"), exports);
|
|
45
45
|
__exportStar(require("./entities"), exports);
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.firestorePlatformBalancesDocumentStub = firestorePlatformBalancesDocumentStub;
|
|
4
|
+
const enums_1 = require("../../../../../enums");
|
|
5
|
+
const constants_1 = require("../../../constants");
|
|
6
|
+
const firestoreTimestampStub_1 = require("../firestoreTimestampStub");
|
|
7
|
+
function firestorePlatformBalancesDocumentStub(overwrite = {}) {
|
|
8
|
+
return {
|
|
9
|
+
schemaVersion: constants_1.FIRESTORE_PLATFORM_BALANCES_SCHEMA_VERSION,
|
|
10
|
+
ownerEntityId: "entity-12345",
|
|
11
|
+
currency: enums_1.SupportedIsoCurrency.EUR,
|
|
12
|
+
balances: {
|
|
13
|
+
availableInCents: 5_000,
|
|
14
|
+
pendingInCents: 1_000,
|
|
15
|
+
lifetimeEarnedInCents: 10_000,
|
|
16
|
+
lifetimeSpentInCents: 2_000,
|
|
17
|
+
updatedAt: (0, firestoreTimestampStub_1.firestoreTimestampStub)(),
|
|
18
|
+
},
|
|
19
|
+
createdAt: (0, firestoreTimestampStub_1.firestoreTimestampStub)(),
|
|
20
|
+
updatedAt: (0, firestoreTimestampStub_1.firestoreTimestampStub)(),
|
|
21
|
+
isTest: true,
|
|
22
|
+
...overwrite,
|
|
23
|
+
};
|
|
24
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./firestorePlatformBalancesDocumentStub";
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./firestorePlatformBalancesDocumentStub"), exports);
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.firestorePlatformBalancesLedgerEntryDocumentStub = firestorePlatformBalancesLedgerEntryDocumentStub;
|
|
4
|
+
const enums_1 = require("../../../../../enums");
|
|
5
|
+
const constants_1 = require("../../../constants");
|
|
6
|
+
const enums_2 = require("../../../enums");
|
|
7
|
+
const firestoreTimestampStub_1 = require("../firestoreTimestampStub");
|
|
8
|
+
function firestorePlatformBalancesLedgerEntryDocumentStub(overwrite = {}) {
|
|
9
|
+
return {
|
|
10
|
+
createdAt: (0, firestoreTimestampStub_1.firestoreTimestampStub)(),
|
|
11
|
+
effectiveAt: (0, firestoreTimestampStub_1.firestoreTimestampStub)(),
|
|
12
|
+
schemaVersion: constants_1.FIRESTORE_PLATFORM_BALANCES_LEDGER_ENTRY_SCHEMA_VERSION,
|
|
13
|
+
platformBalancesDocumentId: "platform-balances-12345",
|
|
14
|
+
type: enums_2.PlatformBalancesLedgerEntryType.CREDIT,
|
|
15
|
+
reason: enums_2.PlatformBalancesLedgerEntryReason.REFERRAL_REWARD,
|
|
16
|
+
amountInCents: 1_000,
|
|
17
|
+
balanceBeforeInCents: 5_000,
|
|
18
|
+
balanceAfterInCents: 6_000,
|
|
19
|
+
currency: enums_1.SupportedIsoCurrency.EUR,
|
|
20
|
+
context: {
|
|
21
|
+
referenceId: "referral-12345",
|
|
22
|
+
referenceType: enums_2.PlatformBalancesLedgerEntryContextReferenceType.REFERRAL,
|
|
23
|
+
},
|
|
24
|
+
isTest: true,
|
|
25
|
+
...overwrite,
|
|
26
|
+
};
|
|
27
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./firestorePlatformBalancesLedgerEntryDocumentStub";
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./firestorePlatformBalancesLedgerEntryDocumentStub"), exports);
|