@connectedxm/admin 1.4.13 → 1.4.14
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/index.d.mts +20 -6
- package/dist/index.d.ts +20 -6
- package/dist/index.js +10 -10
- package/dist/index.mjs +10 -10
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -448,6 +448,8 @@ interface BaseAnnouncement {
|
|
|
448
448
|
creatorId: string | null;
|
|
449
449
|
eventId: string | null;
|
|
450
450
|
groupId: string | null;
|
|
451
|
+
tierId: string | null;
|
|
452
|
+
channelId: string | null;
|
|
451
453
|
ticketId: string | null;
|
|
452
454
|
userId: string | null;
|
|
453
455
|
schedule: BaseSchedule;
|
|
@@ -471,6 +473,8 @@ interface Announcement extends BaseAnnouncement {
|
|
|
471
473
|
creator: BaseAccount | null;
|
|
472
474
|
event: BaseEvent | null;
|
|
473
475
|
group: BaseGroup | null;
|
|
476
|
+
tier: BaseTier | null;
|
|
477
|
+
channel: BaseChannel | null;
|
|
474
478
|
sponsorshipLevelId: string | null;
|
|
475
479
|
sponsorshipLevel: BaseLevel | null;
|
|
476
480
|
ticket: BaseEventPassType | null;
|
|
@@ -2755,6 +2759,8 @@ interface AnnouncementCreateInputs {
|
|
|
2755
2759
|
creatorId?: string | null;
|
|
2756
2760
|
eventId?: string | null;
|
|
2757
2761
|
groupId?: string | null;
|
|
2762
|
+
tierId?: string | null;
|
|
2763
|
+
channelId?: string | null;
|
|
2758
2764
|
accountId?: string | null;
|
|
2759
2765
|
email?: boolean;
|
|
2760
2766
|
push?: boolean;
|
|
@@ -2767,6 +2773,8 @@ interface AnnouncementUpdateInputs {
|
|
|
2767
2773
|
creatorId?: string | null;
|
|
2768
2774
|
eventId?: string | null;
|
|
2769
2775
|
groupId?: string | null;
|
|
2776
|
+
tierId?: string | null;
|
|
2777
|
+
channelId?: string | null;
|
|
2770
2778
|
accountId?: string | null;
|
|
2771
2779
|
email?: boolean;
|
|
2772
2780
|
push?: boolean;
|
|
@@ -5128,30 +5136,36 @@ declare const GetAnnouncementEmailReceipts: ({ announcementId, status, pageParam
|
|
|
5128
5136
|
*/
|
|
5129
5137
|
declare const useGetAnnouncementEmailReceipts: (announcementId?: string, status?: keyof typeof EmailReceiptStatus, params?: Omit<InfiniteQueryParams, "pageParam" | "queryClient" | "adminApiParams">, options?: InfiniteQueryOptions<Awaited<ReturnType<typeof GetAnnouncementEmailReceipts>>>) => _tanstack_react_query.UseInfiniteQueryResult<_tanstack_react_query.InfiniteData<ConnectedXMResponse<EmailReceipt[]>, number>, axios.AxiosError<ConnectedXMResponse<null>, any>>;
|
|
5130
5138
|
|
|
5139
|
+
interface AnnouncementFilters {
|
|
5140
|
+
eventId?: string;
|
|
5141
|
+
groupId?: string;
|
|
5142
|
+
tierId?: string;
|
|
5143
|
+
channelId?: string;
|
|
5144
|
+
accountId?: string;
|
|
5145
|
+
}
|
|
5131
5146
|
/**
|
|
5132
5147
|
* @category Keys
|
|
5133
5148
|
* @group Announcements
|
|
5134
5149
|
*/
|
|
5135
|
-
declare const ANNOUNCEMENTS_QUERY_KEY: (
|
|
5150
|
+
declare const ANNOUNCEMENTS_QUERY_KEY: (filters?: AnnouncementFilters) => string[];
|
|
5136
5151
|
/**
|
|
5137
5152
|
* @category Setters
|
|
5138
5153
|
* @group Announcements
|
|
5139
5154
|
*/
|
|
5140
|
-
declare const SET_ANNOUNCEMENTS_QUERY_DATA: (client: QueryClient, keyParams:
|
|
5155
|
+
declare const SET_ANNOUNCEMENTS_QUERY_DATA: (client: QueryClient, keyParams: Parameters<typeof ANNOUNCEMENTS_QUERY_KEY>, response: Awaited<ReturnType<typeof GetAnnouncements>>) => void;
|
|
5141
5156
|
interface GetAnnouncementsProps extends InfiniteQueryParams {
|
|
5142
|
-
|
|
5143
|
-
groupId?: string;
|
|
5157
|
+
filters?: AnnouncementFilters;
|
|
5144
5158
|
}
|
|
5145
5159
|
/**
|
|
5146
5160
|
* @category Queries
|
|
5147
5161
|
* @group Announcements
|
|
5148
5162
|
*/
|
|
5149
|
-
declare const GetAnnouncements: ({ pageParam, pageSize, orderBy, search,
|
|
5163
|
+
declare const GetAnnouncements: ({ pageParam, pageSize, orderBy, search, filters, adminApiParams, }: GetAnnouncementsProps) => Promise<ConnectedXMResponse<Announcement[]>>;
|
|
5150
5164
|
/**
|
|
5151
5165
|
* @category Hooks
|
|
5152
5166
|
* @group Announcements
|
|
5153
5167
|
*/
|
|
5154
|
-
declare const useGetAnnouncements: (
|
|
5168
|
+
declare const useGetAnnouncements: (filters?: AnnouncementFilters, params?: Omit<InfiniteQueryParams, "pageParam" | "queryClient" | "adminApiParams">, options?: InfiniteQueryOptions<Awaited<ReturnType<typeof GetAnnouncements>>>) => _tanstack_react_query.UseInfiniteQueryResult<_tanstack_react_query.InfiniteData<ConnectedXMResponse<Announcement[]>, number>, axios.AxiosError<ConnectedXMResponse<null>, any>>;
|
|
5155
5169
|
|
|
5156
5170
|
/**
|
|
5157
5171
|
* @category Key
|
package/dist/index.d.ts
CHANGED
|
@@ -448,6 +448,8 @@ interface BaseAnnouncement {
|
|
|
448
448
|
creatorId: string | null;
|
|
449
449
|
eventId: string | null;
|
|
450
450
|
groupId: string | null;
|
|
451
|
+
tierId: string | null;
|
|
452
|
+
channelId: string | null;
|
|
451
453
|
ticketId: string | null;
|
|
452
454
|
userId: string | null;
|
|
453
455
|
schedule: BaseSchedule;
|
|
@@ -471,6 +473,8 @@ interface Announcement extends BaseAnnouncement {
|
|
|
471
473
|
creator: BaseAccount | null;
|
|
472
474
|
event: BaseEvent | null;
|
|
473
475
|
group: BaseGroup | null;
|
|
476
|
+
tier: BaseTier | null;
|
|
477
|
+
channel: BaseChannel | null;
|
|
474
478
|
sponsorshipLevelId: string | null;
|
|
475
479
|
sponsorshipLevel: BaseLevel | null;
|
|
476
480
|
ticket: BaseEventPassType | null;
|
|
@@ -2755,6 +2759,8 @@ interface AnnouncementCreateInputs {
|
|
|
2755
2759
|
creatorId?: string | null;
|
|
2756
2760
|
eventId?: string | null;
|
|
2757
2761
|
groupId?: string | null;
|
|
2762
|
+
tierId?: string | null;
|
|
2763
|
+
channelId?: string | null;
|
|
2758
2764
|
accountId?: string | null;
|
|
2759
2765
|
email?: boolean;
|
|
2760
2766
|
push?: boolean;
|
|
@@ -2767,6 +2773,8 @@ interface AnnouncementUpdateInputs {
|
|
|
2767
2773
|
creatorId?: string | null;
|
|
2768
2774
|
eventId?: string | null;
|
|
2769
2775
|
groupId?: string | null;
|
|
2776
|
+
tierId?: string | null;
|
|
2777
|
+
channelId?: string | null;
|
|
2770
2778
|
accountId?: string | null;
|
|
2771
2779
|
email?: boolean;
|
|
2772
2780
|
push?: boolean;
|
|
@@ -5128,30 +5136,36 @@ declare const GetAnnouncementEmailReceipts: ({ announcementId, status, pageParam
|
|
|
5128
5136
|
*/
|
|
5129
5137
|
declare const useGetAnnouncementEmailReceipts: (announcementId?: string, status?: keyof typeof EmailReceiptStatus, params?: Omit<InfiniteQueryParams, "pageParam" | "queryClient" | "adminApiParams">, options?: InfiniteQueryOptions<Awaited<ReturnType<typeof GetAnnouncementEmailReceipts>>>) => _tanstack_react_query.UseInfiniteQueryResult<_tanstack_react_query.InfiniteData<ConnectedXMResponse<EmailReceipt[]>, number>, axios.AxiosError<ConnectedXMResponse<null>, any>>;
|
|
5130
5138
|
|
|
5139
|
+
interface AnnouncementFilters {
|
|
5140
|
+
eventId?: string;
|
|
5141
|
+
groupId?: string;
|
|
5142
|
+
tierId?: string;
|
|
5143
|
+
channelId?: string;
|
|
5144
|
+
accountId?: string;
|
|
5145
|
+
}
|
|
5131
5146
|
/**
|
|
5132
5147
|
* @category Keys
|
|
5133
5148
|
* @group Announcements
|
|
5134
5149
|
*/
|
|
5135
|
-
declare const ANNOUNCEMENTS_QUERY_KEY: (
|
|
5150
|
+
declare const ANNOUNCEMENTS_QUERY_KEY: (filters?: AnnouncementFilters) => string[];
|
|
5136
5151
|
/**
|
|
5137
5152
|
* @category Setters
|
|
5138
5153
|
* @group Announcements
|
|
5139
5154
|
*/
|
|
5140
|
-
declare const SET_ANNOUNCEMENTS_QUERY_DATA: (client: QueryClient, keyParams:
|
|
5155
|
+
declare const SET_ANNOUNCEMENTS_QUERY_DATA: (client: QueryClient, keyParams: Parameters<typeof ANNOUNCEMENTS_QUERY_KEY>, response: Awaited<ReturnType<typeof GetAnnouncements>>) => void;
|
|
5141
5156
|
interface GetAnnouncementsProps extends InfiniteQueryParams {
|
|
5142
|
-
|
|
5143
|
-
groupId?: string;
|
|
5157
|
+
filters?: AnnouncementFilters;
|
|
5144
5158
|
}
|
|
5145
5159
|
/**
|
|
5146
5160
|
* @category Queries
|
|
5147
5161
|
* @group Announcements
|
|
5148
5162
|
*/
|
|
5149
|
-
declare const GetAnnouncements: ({ pageParam, pageSize, orderBy, search,
|
|
5163
|
+
declare const GetAnnouncements: ({ pageParam, pageSize, orderBy, search, filters, adminApiParams, }: GetAnnouncementsProps) => Promise<ConnectedXMResponse<Announcement[]>>;
|
|
5150
5164
|
/**
|
|
5151
5165
|
* @category Hooks
|
|
5152
5166
|
* @group Announcements
|
|
5153
5167
|
*/
|
|
5154
|
-
declare const useGetAnnouncements: (
|
|
5168
|
+
declare const useGetAnnouncements: (filters?: AnnouncementFilters, params?: Omit<InfiniteQueryParams, "pageParam" | "queryClient" | "adminApiParams">, options?: InfiniteQueryOptions<Awaited<ReturnType<typeof GetAnnouncements>>>) => _tanstack_react_query.UseInfiniteQueryResult<_tanstack_react_query.InfiniteData<ConnectedXMResponse<Announcement[]>, number>, axios.AxiosError<ConnectedXMResponse<null>, any>>;
|
|
5155
5169
|
|
|
5156
5170
|
/**
|
|
5157
5171
|
* @category Key
|
package/dist/index.js
CHANGED
|
@@ -3695,10 +3695,12 @@ var useGetAdvertisementViews = (advertisementId = "", params = {}, options = {})
|
|
|
3695
3695
|
};
|
|
3696
3696
|
|
|
3697
3697
|
// src/queries/announcements/useGetAnnouncements.ts
|
|
3698
|
-
var ANNOUNCEMENTS_QUERY_KEY = (
|
|
3698
|
+
var ANNOUNCEMENTS_QUERY_KEY = (filters) => {
|
|
3699
3699
|
const keys = ["ANNOUNCEMENTS"];
|
|
3700
|
-
if (eventId) keys.push(eventId);
|
|
3701
|
-
if (groupId) keys.push(groupId);
|
|
3700
|
+
if (filters?.eventId) keys.push(filters.eventId);
|
|
3701
|
+
if (filters?.groupId) keys.push(filters.groupId);
|
|
3702
|
+
if (filters?.tierId) keys.push(filters.tierId);
|
|
3703
|
+
if (filters?.accountId) keys.push(filters.accountId);
|
|
3702
3704
|
return keys;
|
|
3703
3705
|
};
|
|
3704
3706
|
var SET_ANNOUNCEMENTS_QUERY_DATA = (client, keyParams, response) => {
|
|
@@ -3709,8 +3711,7 @@ var GetAnnouncements = async ({
|
|
|
3709
3711
|
pageSize,
|
|
3710
3712
|
orderBy,
|
|
3711
3713
|
search,
|
|
3712
|
-
|
|
3713
|
-
groupId,
|
|
3714
|
+
filters,
|
|
3714
3715
|
adminApiParams
|
|
3715
3716
|
}) => {
|
|
3716
3717
|
const adminApi = await GetAdminAPI(adminApiParams);
|
|
@@ -3720,16 +3721,15 @@ var GetAnnouncements = async ({
|
|
|
3720
3721
|
pageSize: pageSize || void 0,
|
|
3721
3722
|
orderBy: orderBy || void 0,
|
|
3722
3723
|
search: search || void 0,
|
|
3723
|
-
|
|
3724
|
-
groupId: groupId || void 0
|
|
3724
|
+
...filters
|
|
3725
3725
|
}
|
|
3726
3726
|
});
|
|
3727
3727
|
return data;
|
|
3728
3728
|
};
|
|
3729
|
-
var useGetAnnouncements = (
|
|
3729
|
+
var useGetAnnouncements = (filters, params = {}, options = {}) => {
|
|
3730
3730
|
return useConnectedInfiniteQuery(
|
|
3731
|
-
ANNOUNCEMENTS_QUERY_KEY(
|
|
3732
|
-
(params2) => GetAnnouncements({
|
|
3731
|
+
ANNOUNCEMENTS_QUERY_KEY(filters),
|
|
3732
|
+
(params2) => GetAnnouncements({ filters, ...params2 }),
|
|
3733
3733
|
params,
|
|
3734
3734
|
options,
|
|
3735
3735
|
"announcements"
|
package/dist/index.mjs
CHANGED
|
@@ -1541,10 +1541,12 @@ var useGetAdvertisementViews = (advertisementId = "", params = {}, options = {})
|
|
|
1541
1541
|
};
|
|
1542
1542
|
|
|
1543
1543
|
// src/queries/announcements/useGetAnnouncements.ts
|
|
1544
|
-
var ANNOUNCEMENTS_QUERY_KEY = (
|
|
1544
|
+
var ANNOUNCEMENTS_QUERY_KEY = (filters) => {
|
|
1545
1545
|
const keys = ["ANNOUNCEMENTS"];
|
|
1546
|
-
if (eventId) keys.push(eventId);
|
|
1547
|
-
if (groupId) keys.push(groupId);
|
|
1546
|
+
if (filters?.eventId) keys.push(filters.eventId);
|
|
1547
|
+
if (filters?.groupId) keys.push(filters.groupId);
|
|
1548
|
+
if (filters?.tierId) keys.push(filters.tierId);
|
|
1549
|
+
if (filters?.accountId) keys.push(filters.accountId);
|
|
1548
1550
|
return keys;
|
|
1549
1551
|
};
|
|
1550
1552
|
var SET_ANNOUNCEMENTS_QUERY_DATA = (client, keyParams, response) => {
|
|
@@ -1555,8 +1557,7 @@ var GetAnnouncements = async ({
|
|
|
1555
1557
|
pageSize,
|
|
1556
1558
|
orderBy,
|
|
1557
1559
|
search,
|
|
1558
|
-
|
|
1559
|
-
groupId,
|
|
1560
|
+
filters,
|
|
1560
1561
|
adminApiParams
|
|
1561
1562
|
}) => {
|
|
1562
1563
|
const adminApi = await GetAdminAPI(adminApiParams);
|
|
@@ -1566,16 +1567,15 @@ var GetAnnouncements = async ({
|
|
|
1566
1567
|
pageSize: pageSize || void 0,
|
|
1567
1568
|
orderBy: orderBy || void 0,
|
|
1568
1569
|
search: search || void 0,
|
|
1569
|
-
|
|
1570
|
-
groupId: groupId || void 0
|
|
1570
|
+
...filters
|
|
1571
1571
|
}
|
|
1572
1572
|
});
|
|
1573
1573
|
return data;
|
|
1574
1574
|
};
|
|
1575
|
-
var useGetAnnouncements = (
|
|
1575
|
+
var useGetAnnouncements = (filters, params = {}, options = {}) => {
|
|
1576
1576
|
return useConnectedInfiniteQuery(
|
|
1577
|
-
ANNOUNCEMENTS_QUERY_KEY(
|
|
1578
|
-
(params2) => GetAnnouncements({
|
|
1577
|
+
ANNOUNCEMENTS_QUERY_KEY(filters),
|
|
1578
|
+
(params2) => GetAnnouncements({ filters, ...params2 }),
|
|
1579
1579
|
params,
|
|
1580
1580
|
options,
|
|
1581
1581
|
"announcements"
|