@vertikalx/vtx-backend-client 2.0.0-dev-carlos.8 → 2.0.0-dev-geo.6
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/libs/vtx-backend-client/package.json +1 -1
- package/libs/vtx-backend-client/src/api/vtx-base-api.d.ts +0 -1
- package/libs/vtx-backend-client/src/api/vtx-base-api.js +13 -41
- package/libs/vtx-backend-client/src/api/vtx-base-api.js.map +1 -1
- package/libs/vtx-backend-client/src/client/schema.d.ts +4 -3
- package/libs/vtx-backend-client/src/client/schema.js.map +1 -1
- package/libs/vtx-backend-client/src/client/types.d.ts +2 -2
- package/libs/vtx-backend-client/src/client/types.js +6 -6
- package/libs/vtx-backend-client/src/client/types.js.map +1 -1
- package/package.json +1 -1
- package/src/api/vtx-base-api.d.ts +0 -1
- package/src/api/vtx-base-api.js +13 -41
- package/src/api/vtx-base-api.js.map +1 -1
- package/src/client/schema.d.ts +4 -3
- package/src/client/schema.js.map +1 -1
- package/src/client/types.d.ts +2 -2
- package/src/client/types.js +6 -6
- package/src/client/types.js.map +1 -1
- package/tsconfig.lib.tsbuildinfo +1 -1
|
@@ -114,5 +114,4 @@ export declare class VTXBaseAPI {
|
|
|
114
114
|
addCompetitionBudget(input: AddCompetitionBudgetDto): Promise<ITypedBackendResponse<Boolean>>;
|
|
115
115
|
editCompetitionBudget(input: EditCompetitionBudgetDto): Promise<ITypedBackendResponse<Boolean>>;
|
|
116
116
|
editCampaignBudget(input: EditCampaignBudgetDto): Promise<ITypedBackendResponse<Boolean>>;
|
|
117
|
-
getDonationsByAthlete(): Promise<ITypedBackendResponse<Receipt[]>>;
|
|
118
117
|
}
|
package/src/api/vtx-base-api.js
CHANGED
|
@@ -1989,6 +1989,7 @@ class VTXBaseAPI {
|
|
|
1989
1989
|
trainer: true,
|
|
1990
1990
|
trainerUrl: true,
|
|
1991
1991
|
aboutMe: true,
|
|
1992
|
+
biography: true,
|
|
1992
1993
|
followStats: {
|
|
1993
1994
|
followers: true,
|
|
1994
1995
|
followed: true,
|
|
@@ -4594,7 +4595,7 @@ class VTXBaseAPI {
|
|
|
4594
4595
|
scores: {
|
|
4595
4596
|
vtxScore: true,
|
|
4596
4597
|
},
|
|
4597
|
-
|
|
4598
|
+
profilePicture: {
|
|
4598
4599
|
url: true,
|
|
4599
4600
|
},
|
|
4600
4601
|
currentCampaign: {
|
|
@@ -5147,6 +5148,7 @@ class VTXBaseAPI {
|
|
|
5147
5148
|
trainer: true,
|
|
5148
5149
|
trainerUrl: true,
|
|
5149
5150
|
aboutMe: true,
|
|
5151
|
+
biography: true,
|
|
5150
5152
|
followStats: {
|
|
5151
5153
|
followers: true,
|
|
5152
5154
|
followed: true,
|
|
@@ -6367,9 +6369,18 @@ class VTXBaseAPI {
|
|
|
6367
6369
|
},
|
|
6368
6370
|
participationDate: true,
|
|
6369
6371
|
},
|
|
6370
|
-
|
|
6372
|
+
profilePicture: {
|
|
6371
6373
|
url: true,
|
|
6372
6374
|
},
|
|
6375
|
+
currentCampaign: {
|
|
6376
|
+
_id: true,
|
|
6377
|
+
budgetMode: true,
|
|
6378
|
+
status: true,
|
|
6379
|
+
title: true,
|
|
6380
|
+
motivation: true,
|
|
6381
|
+
website: true,
|
|
6382
|
+
endingDate: true,
|
|
6383
|
+
}
|
|
6373
6384
|
};
|
|
6374
6385
|
const fields = {
|
|
6375
6386
|
athletes: fieldsAthlete,
|
|
@@ -7261,7 +7272,6 @@ class VTXBaseAPI {
|
|
|
7261
7272
|
fundsRequired: true,
|
|
7262
7273
|
initialFundsObtained: true,
|
|
7263
7274
|
status: true,
|
|
7264
|
-
budgetMode: true,
|
|
7265
7275
|
endingDate: true,
|
|
7266
7276
|
budget: true,
|
|
7267
7277
|
competitions: true,
|
|
@@ -7411,44 +7421,6 @@ class VTXBaseAPI {
|
|
|
7411
7421
|
}
|
|
7412
7422
|
return retValue;
|
|
7413
7423
|
}
|
|
7414
|
-
async getDonationsByAthlete() {
|
|
7415
|
-
const client = (0, client_1.createClient)({
|
|
7416
|
-
url: this.backendUrl + '/graphql',
|
|
7417
|
-
headers: this.headers,
|
|
7418
|
-
});
|
|
7419
|
-
let retValue = { data: [] };
|
|
7420
|
-
const fields = {
|
|
7421
|
-
receiptId: true,
|
|
7422
|
-
campaignName: true,
|
|
7423
|
-
athleteName: true,
|
|
7424
|
-
donorName: true,
|
|
7425
|
-
amount: true,
|
|
7426
|
-
currency: true,
|
|
7427
|
-
dateIssued: true,
|
|
7428
|
-
confirmed: true,
|
|
7429
|
-
message: true
|
|
7430
|
-
};
|
|
7431
|
-
try {
|
|
7432
|
-
const response = await client.query({
|
|
7433
|
-
getDonationsByAthlete: {
|
|
7434
|
-
...fields
|
|
7435
|
-
},
|
|
7436
|
-
});
|
|
7437
|
-
retValue = (0, response_builder_1.buildResponse)(response, 'getDonationsByAthlete', (r) => {
|
|
7438
|
-
const isResponseOk = !!response?.getDonationsByAthlete &&
|
|
7439
|
-
Array.isArray(response.getDonationsByAthlete);
|
|
7440
|
-
return isResponseOk;
|
|
7441
|
-
});
|
|
7442
|
-
if (!retValue.data) {
|
|
7443
|
-
retValue.data = [];
|
|
7444
|
-
}
|
|
7445
|
-
}
|
|
7446
|
-
catch (err) {
|
|
7447
|
-
retValue = (0, response_builder_1.buildErrorResponse)(err);
|
|
7448
|
-
retValue.data = [];
|
|
7449
|
-
}
|
|
7450
|
-
return retValue;
|
|
7451
|
-
}
|
|
7452
7424
|
}
|
|
7453
7425
|
exports.VTXBaseAPI = VTXBaseAPI;
|
|
7454
7426
|
VTXBaseAPI.Logger = {
|