@hubs101/js-api-skd-client 1.0.10351 → 1.0.10352
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/lib/api/event/index.d.ts +0 -1
- package/lib/api/event/index.js +1 -7
- package/lib/index.js +0 -6
- package/lib/types/base.d.ts +0 -2
- package/lib/utils/base.js +1 -1
- package/package.json +1 -1
package/lib/api/event/index.d.ts
CHANGED
|
@@ -108,4 +108,3 @@ export declare const _updatePortfolio: (basePath: string, token: string, portfol
|
|
|
108
108
|
value: File;
|
|
109
109
|
}[]) => Promise<any>;
|
|
110
110
|
export declare const _fetchPortfolioDetails: (basePath: string, token: string, portfolioId: string) => Promise<Portfolio>;
|
|
111
|
-
export declare const _fetchPortfolioEvents: (basePath: string, token: string, portfolioId: string) => Promise<Event[]>;
|
package/lib/api/event/index.js
CHANGED
|
@@ -10,7 +10,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
12
|
exports._fetchMyBookings = exports._createBooking = exports._checkBooking = exports._resendBookingEmail = exports._resendTicketEmail = exports._fetchEventAttendeeActions = exports._fetchEventGroups = exports._unpinExhibition = exports._pinExhibition = exports._unpinDocument = exports._pinDocument = exports._reportExhibitionAction = exports._deleteDocument = exports._updateDocument = exports._createDocument = exports._assignDocumentToEvent = exports._fetchEventDocuments = exports._fetchUserRegistrationsEvents = exports._fetchEventStreams = exports._fetchEventLocations = exports._deleteLocation = exports._updateLocation = exports._createLocation = exports._fetchExhibitionDetails = exports._deleteDiscount = exports._updateDiscount = exports._createDiscount = exports._fetchEventDiscounts = exports._deleteTicket = exports._updateTicket = exports._createTicket = exports._deleteOption = exports._updateOption = exports._createOption = exports._deleteGroup = exports._updateGroup = exports._createGroup = exports._importAgenda = exports._fetchAttendeesAvailabilities = exports._updateEventTemplates = exports._fetchEventTemplates = exports._fetchEventNotifications = exports._sendSingleNotification = exports._sendNotification = exports._fetchEventDetails = exports._fetchExhibitions = exports._fetchEventsForAccount = exports._fetchTickets = exports._fetchAccounts = exports._fetchEventRegistrations = void 0;
|
|
13
|
-
exports.
|
|
13
|
+
exports._fetchPortfolioDetails = exports._updatePortfolio = exports._createPortfolio = exports._unassignPortfolio = exports._assignPortfolio = exports._deletePortfolio = exports._fetchPortfolios = exports._deleteExhibition = exports._updateExhibition = exports._importExhibition = exports._createExhibition = exports._fetchMyExhibitions = exports._fetchAllExhibitions = exports._deleteStream = exports._updateStream = exports._createStream = exports._fetchYoutubeContent = exports._fetchZoomContent = exports._createEvent = exports._unassignPaymentAccount = exports._assignPaymentAccount = exports._fetchEventOptions = exports._fetchEventTickets = exports._updateEvent = exports._deletePage = exports._updatePage = exports._createPage = exports._fetchEventPages = exports._updateAccountWithFiles = exports._fetchMySessions = exports._fetchEditableEvents = exports._fetchSpeakers = exports._fetchAccountDetails = exports._eventInvitationRegistration = exports._createFreeTrialAccount = exports._fetchEventOrderedTickets = exports._confirmBooking = exports._fetchEventBookings = exports._acceptInternTicket = exports._acceptTicket = exports._postTicketDetails = exports._fetchTicketDetails = exports._assignTicket = exports._fetchAccountBookings = void 0;
|
|
14
14
|
const api_1 = require("../../utils/api");
|
|
15
15
|
const base_1 = require("../../utils/base");
|
|
16
16
|
const _fetchEventRegistrations = (basePath, token, eventId) => __awaiter(void 0, void 0, void 0, function* () {
|
|
@@ -593,9 +593,3 @@ const _fetchPortfolioDetails = (basePath, token, portfolioId) => __awaiter(void
|
|
|
593
593
|
return portfolioDetails;
|
|
594
594
|
});
|
|
595
595
|
exports._fetchPortfolioDetails = _fetchPortfolioDetails;
|
|
596
|
-
const _fetchPortfolioEvents = (basePath, token, portfolioId) => __awaiter(void 0, void 0, void 0, function* () {
|
|
597
|
-
const base = (0, base_1.getBasePath)(basePath);
|
|
598
|
-
const { data: portfolioEvents } = yield (0, api_1.getRequest)(`${base.PORTFOLIOS}/${portfolioId}/events`, token);
|
|
599
|
-
return (portfolioEvents === null || portfolioEvents === void 0 ? void 0 : portfolioEvents.data) || portfolioEvents;
|
|
600
|
-
});
|
|
601
|
-
exports._fetchPortfolioEvents = _fetchPortfolioEvents;
|
package/lib/index.js
CHANGED
|
@@ -865,10 +865,6 @@ function EventAPIProvider(props) {
|
|
|
865
865
|
(0, api_1.validateConfig)(config);
|
|
866
866
|
return (0, event_1._fetchPortfolioDetails)(config.baseUrl, config.token, portfolioId);
|
|
867
867
|
}), [config, config.baseUrl, config.token]);
|
|
868
|
-
const fetchPortfolioEvents = react_1.default.useCallback((portfolioId) => __awaiter(this, void 0, void 0, function* () {
|
|
869
|
-
(0, api_1.validateConfig)(config);
|
|
870
|
-
return (0, event_1._fetchPortfolioEvents)(config.baseUrl, config.token, portfolioId);
|
|
871
|
-
}), [config, config.baseUrl, config.token]);
|
|
872
868
|
return (react_1.default.createElement(EventAPIContext_1.default.Provider, { value: {
|
|
873
869
|
config,
|
|
874
870
|
init,
|
|
@@ -1070,7 +1066,6 @@ function EventAPIProvider(props) {
|
|
|
1070
1066
|
createPortfolio,
|
|
1071
1067
|
updatePortfolio,
|
|
1072
1068
|
fetchPortfolioDetails,
|
|
1073
|
-
fetchPortfolioEvents,
|
|
1074
1069
|
} }, props.children));
|
|
1075
1070
|
}
|
|
1076
1071
|
exports.EventAPIProvider = EventAPIProvider;
|
|
@@ -1273,6 +1268,5 @@ exports.BaseAPI = {
|
|
|
1273
1268
|
createPortfolio: event_1._createPortfolio,
|
|
1274
1269
|
updatePortfolio: event_1._updatePortfolio,
|
|
1275
1270
|
fetchPortfolioDetails: event_1._fetchPortfolioDetails,
|
|
1276
|
-
fetchPortfolioEvents: event_1._fetchPortfolioEvents,
|
|
1277
1271
|
};
|
|
1278
1272
|
exports.useAPIContext = EventAPIContext_1.useAPIContext;
|
package/lib/types/base.d.ts
CHANGED
|
@@ -291,7 +291,6 @@ export type BaseAPIType = {
|
|
|
291
291
|
value: File;
|
|
292
292
|
}[]) => Promise<Portfolio>;
|
|
293
293
|
fetchPortfolioDetails: (basePath: string, token: string, portfolioId: string) => Promise<Portfolio>;
|
|
294
|
-
fetchPortfolioEvents: (basePath: string, token: string, portfolioId: string) => Promise<Event[]>;
|
|
295
294
|
};
|
|
296
295
|
export type EventAPIType = {
|
|
297
296
|
config: BaseAPIConfigType;
|
|
@@ -512,7 +511,6 @@ export type EventAPIType = {
|
|
|
512
511
|
value: File;
|
|
513
512
|
}[]) => Promise<Portfolio>;
|
|
514
513
|
fetchPortfolioDetails: (portfolioId: string) => Promise<Portfolio>;
|
|
515
|
-
fetchPortfolioEvents: (portfolioId: string) => Promise<Event[]>;
|
|
516
514
|
};
|
|
517
515
|
export type BaseAPIConfigType = {
|
|
518
516
|
baseUrl?: string;
|
package/lib/utils/base.js
CHANGED
|
@@ -57,7 +57,7 @@ const getBasePath = (basePath) => {
|
|
|
57
57
|
TICKETS: `${authorizedBasePath}/tickets`,
|
|
58
58
|
DISCOUNTS: `${authorizedBasePath}/discounts`,
|
|
59
59
|
PAYMENT_ACCOUNTS: `${authorizedBasePath}/payment-accounts`,
|
|
60
|
-
PUBLIC_EVENTS: basePath ? `${
|
|
60
|
+
PUBLIC_EVENTS: basePath ? `${publicBasePath}/events` : "/public/events",
|
|
61
61
|
STREAMS: `${authorizedBasePath}/streams`,
|
|
62
62
|
ACCOUNT_TRIAL: `${unauthorizedBasePath}/accounts/trial`,
|
|
63
63
|
INVITATION: `${unauthorizedBasePath}/invitation`,
|