@myclub_se/data-access 1.9.0 → 2.1.0
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/esm2020/lib/api-models/api-activity-location-group.mjs +2 -0
- package/esm2020/lib/api-models/api-booking-calendar-slot.mjs +1 -1
- package/esm2020/lib/api-models/api-invoice/api-payment-attempt-create.mjs +3 -2
- package/esm2020/lib/api-models/index.mjs +2 -1
- package/esm2020/lib/interfaces/email-recipient.interface.mjs +2 -0
- package/esm2020/lib/interfaces/index.mjs +3 -1
- package/esm2020/lib/interfaces/sms-recipient.interface.mjs +2 -0
- package/esm2020/lib/models/activity-location-group.mjs +11 -0
- package/esm2020/lib/models/booking-calendar-slot.mjs +14 -2
- package/esm2020/lib/models/email.mjs +1 -1
- package/esm2020/lib/models/index.mjs +2 -2
- package/esm2020/lib/services/activity.service.mjs +22 -2
- package/esm2020/lib/services/booking-calendar.service.mjs +16 -2
- package/esm2020/lib/services/email.service.mjs +1 -1
- package/esm2020/lib/services/factories/activity-location-group-factory.mjs +6 -0
- package/esm2020/lib/services/factories/booking-calendar-slot-factory.mjs +3 -2
- package/esm2020/lib/services/factories/payment-attempt-factory.mjs +2 -2
- package/esm2020/lib/services/invoice/payment-attempt.service.mjs +5 -5
- package/fesm2015/myclub_se-data-access.mjs +73 -18
- package/fesm2015/myclub_se-data-access.mjs.map +1 -1
- package/fesm2020/myclub_se-data-access.mjs +72 -18
- package/fesm2020/myclub_se-data-access.mjs.map +1 -1
- package/lib/api-models/api-activity-location-group.d.ts +9 -0
- package/lib/api-models/api-booking-calendar-slot.d.ts +6 -0
- package/lib/api-models/api-invoice/api-payment-attempt-create.d.ts +2 -1
- package/lib/api-models/index.d.ts +1 -0
- package/lib/interfaces/email-recipient.interface.d.ts +4 -0
- package/lib/interfaces/index.d.ts +2 -0
- package/lib/interfaces/sms-recipient.interface.d.ts +4 -0
- package/lib/models/activity-location-group.d.ts +10 -0
- package/lib/models/booking-calendar-slot.d.ts +13 -1
- package/lib/models/email.d.ts +3 -3
- package/lib/models/index.d.ts +1 -1
- package/lib/services/activity.service.d.ts +5 -0
- package/lib/services/booking-calendar.service.d.ts +4 -4
- package/lib/services/email.service.d.ts +4 -3
- package/lib/services/factories/activity-location-group-factory.d.ts +3 -0
- package/lib/services/invoice/payment-attempt.service.d.ts +2 -2
- package/package.json +1 -1
- package/esm2020/lib/models/email-recipient.mjs +0 -7
- package/lib/models/email-recipient.d.ts +0 -5
|
@@ -12,11 +12,11 @@ export class PaymentAttemptService {
|
|
|
12
12
|
constructor(apiService) {
|
|
13
13
|
this.apiService = apiService;
|
|
14
14
|
}
|
|
15
|
-
createMemberPaymentAttempt(memberId, invoiceId, type) {
|
|
16
|
-
return this.createPaymentAttempt(Role.MemberAdmin, MEMBER_PAYMENTS_PATH, { memberId, invoiceId }, new ApiPaymentAttemptCreate(invoiceId, type));
|
|
15
|
+
createMemberPaymentAttempt(memberId, invoiceId, type, phoneNumber = '') {
|
|
16
|
+
return this.createPaymentAttempt(Role.MemberAdmin, MEMBER_PAYMENTS_PATH, { memberId, invoiceId }, new ApiPaymentAttemptCreate(invoiceId, type, phoneNumber));
|
|
17
17
|
}
|
|
18
|
-
createPublicPaymentAttempt(invoiceId, token, type) {
|
|
19
|
-
return this.createPaymentAttempt(Role.Public, PUBLIC_PAYMENTS_PATH, { invoiceId, token }, new ApiPaymentAttemptCreate(invoiceId, type));
|
|
18
|
+
createPublicPaymentAttempt(invoiceId, token, type, phoneNumber = '') {
|
|
19
|
+
return this.createPaymentAttempt(Role.Public, PUBLIC_PAYMENTS_PATH, { invoiceId, token }, new ApiPaymentAttemptCreate(invoiceId, type, phoneNumber));
|
|
20
20
|
}
|
|
21
21
|
getMemberPaymentAttempt(memberId, invoiceId, id) {
|
|
22
22
|
return this.getPaymentAttempt(Role.MemberAdmin, MEMBER_PAYMENT_PATH, { memberId, invoiceId, id: id.toString() });
|
|
@@ -48,4 +48,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.11", ngImpo
|
|
|
48
48
|
providedIn: 'root'
|
|
49
49
|
}]
|
|
50
50
|
}], ctorParameters: function () { return [{ type: i1.ApiService }]; } });
|
|
51
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
51
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicGF5bWVudC1hdHRlbXB0LnNlcnZpY2UuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9kYXRhLWFjY2Vzcy9zcmMvbGliL3NlcnZpY2VzL2ludm9pY2UvcGF5bWVudC1hdHRlbXB0LnNlcnZpY2UudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLFVBQVUsRUFBRSxNQUFNLGVBQWUsQ0FBQztBQUUzQyxPQUFPLEVBQWtCLElBQUksRUFBRSxXQUFXLEVBQUUsTUFBTSxjQUFjLENBQUM7QUFDakUsT0FBTyxFQUFxQix1QkFBdUIsRUFBa0IsTUFBTSxrQkFBa0IsQ0FBQztBQUU5RixPQUFPLEVBQUUscUJBQXFCLEVBQUUsTUFBTSxjQUFjLENBQUM7OztBQUVyRCxNQUFNLG1CQUFtQixHQUFHLHFEQUFxRCxDQUFDO0FBQ2xGLE1BQU0sb0JBQW9CLEdBQUcsaURBQWlELENBQUM7QUFDL0UsTUFBTSxtQkFBbUIsR0FBRyxrREFBa0QsQ0FBQztBQUMvRSxNQUFNLG9CQUFvQixHQUFHLDhDQUE4QyxDQUFDO0FBTTVFLE1BQU0sT0FBTyxxQkFBcUI7SUFDaEMsWUFBb0IsVUFBc0I7UUFBdEIsZUFBVSxHQUFWLFVBQVUsQ0FBWTtJQUFHLENBQUM7SUFFOUMsMEJBQTBCLENBQUMsUUFBZ0IsRUFBRSxTQUFpQixFQUFFLElBQXdCLEVBQUUsY0FBc0IsRUFBRTtRQUNoSCxP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6 +138,17 @@ class ActivityLocation {
|
|
|
138
138
|
}
|
|
139
139
|
}
|
|
140
140
|
|
|
141
|
+
class ActivityLocationGroup {
|
|
142
|
+
constructor(id, club_id, section_id, active, name, locations) {
|
|
143
|
+
this.id = id;
|
|
144
|
+
this.club_id = club_id;
|
|
145
|
+
this.section_id = section_id;
|
|
146
|
+
this.active = active;
|
|
147
|
+
this.name = name;
|
|
148
|
+
this.locations = locations;
|
|
149
|
+
}
|
|
150
|
+
}
|
|
151
|
+
|
|
141
152
|
class ActivitySettings {
|
|
142
153
|
constructor(dayOptions, hourOptions, inviteGroupOptions, inviteSettingsOptions, maxAttendanceOptions, meetUpTimeOptions, remindReceiverOptions, repeatOptions, repeatTypeOptions) {
|
|
143
154
|
this.dayOptions = dayOptions;
|
|
@@ -246,18 +257,24 @@ class BookingCalendar {
|
|
|
246
257
|
}
|
|
247
258
|
|
|
248
259
|
class BookingCalendarSlot {
|
|
249
|
-
constructor(id, calendar_id, location_id, color, day, end_time, location_name, number_of_available_sessions, sessions, start_time, type) {
|
|
260
|
+
constructor(id, calendar_id, location_id, color, day, end_time, group_id, location_name, number_of_available_sessions, sessions, start_time, type, repeat, update_repeating, repeat_num, repeat_to_day, repeat_type) {
|
|
250
261
|
this.id = id;
|
|
251
262
|
this.calendar_id = calendar_id;
|
|
252
263
|
this.location_id = location_id;
|
|
253
264
|
this.color = color;
|
|
254
265
|
this.day = day;
|
|
255
266
|
this.end_time = end_time;
|
|
267
|
+
this.group_id = group_id;
|
|
256
268
|
this.location_name = location_name;
|
|
257
269
|
this.number_of_available_sessions = number_of_available_sessions;
|
|
258
270
|
this.sessions = sessions;
|
|
259
271
|
this.start_time = start_time;
|
|
260
272
|
this.type = type;
|
|
273
|
+
this.repeat = repeat;
|
|
274
|
+
this.update_repeating = update_repeating;
|
|
275
|
+
this.repeat_num = repeat_num;
|
|
276
|
+
this.repeat_to_day = repeat_to_day;
|
|
277
|
+
this.repeat_type = repeat_type;
|
|
261
278
|
}
|
|
262
279
|
static asFormGroup(slot) {
|
|
263
280
|
return new FormGroup({
|
|
@@ -266,9 +283,15 @@ class BookingCalendarSlot {
|
|
|
266
283
|
location_id: new FormControl((slot === null || slot === void 0 ? void 0 : slot.location_id) || '', Validators.required),
|
|
267
284
|
day: new FormControl((slot === null || slot === void 0 ? void 0 : slot.day) || '', Validators.required),
|
|
268
285
|
end_time: new FormControl((slot === null || slot === void 0 ? void 0 : slot.end_time) || '', Validators.required),
|
|
286
|
+
group_id: new FormControl((slot === null || slot === void 0 ? void 0 : slot.group_id) || null, { nonNullable: false }),
|
|
269
287
|
number_of_available_sessions: new FormControl((slot === null || slot === void 0 ? void 0 : slot.number_of_available_sessions) || 0, Validators.required),
|
|
270
288
|
start_time: new FormControl((slot === null || slot === void 0 ? void 0 : slot.start_time) || '', Validators.required),
|
|
271
289
|
type: new FormControl((slot === null || slot === void 0 ? void 0 : slot.type) || '', Validators.required),
|
|
290
|
+
repeat: new FormControl((slot === null || slot === void 0 ? void 0 : slot.repeat) || 'none'),
|
|
291
|
+
repeat_num: new FormControl((slot === null || slot === void 0 ? void 0 : slot.repeat_num) || 6, Validators.max(24)),
|
|
292
|
+
repeat_to_day: new FormControl((slot === null || slot === void 0 ? void 0 : slot.repeat_to_day) || ''),
|
|
293
|
+
repeat_type: new FormControl((slot === null || slot === void 0 ? void 0 : slot.repeat_type) || ''),
|
|
294
|
+
update_repeating: new FormControl(typeof (slot === null || slot === void 0 ? void 0 : slot.update_repeating) !== 'undefined' ? slot === null || slot === void 0 ? void 0 : slot.update_repeating : false)
|
|
272
295
|
});
|
|
273
296
|
}
|
|
274
297
|
}
|
|
@@ -578,13 +601,6 @@ class Email {
|
|
|
578
601
|
}
|
|
579
602
|
}
|
|
580
603
|
|
|
581
|
-
class EmailRecipient {
|
|
582
|
-
constructor(id, name) {
|
|
583
|
-
this.id = id;
|
|
584
|
-
this.name = name;
|
|
585
|
-
}
|
|
586
|
-
}
|
|
587
|
-
|
|
588
604
|
class Event {
|
|
589
605
|
constructor(id, activity_id, activity_type, base_background_color, base_color, base_name, calendar_name, description, end, invitation_id, invitation_response, location, meet_up_place, meet_up_time, member_id, start, title, type) {
|
|
590
606
|
this.id = id;
|
|
@@ -1379,6 +1395,7 @@ const memberTeamThroughFactory = (apiMemberTeamThrough) => new MemberTeamThrough
|
|
|
1379
1395
|
const newsFactory = (apiNews) => new News(apiNews.id, apiNews.club_id, apiNews.created, apiNews.created_by_id, apiNews.section_id, apiNews.team_id, apiNews.active_to, apiNews.author, apiNews.ingress, apiNews.news_image, apiNews.news_image_text, apiNews.published_date, apiNews.read, apiNews.show_on_my_pages, apiNews.show_on_webpage, apiNews.text, apiNews.title, apiNews.updated, apiNews.urls ? imageUrlsFactory(apiNews.urls) : null);
|
|
1380
1396
|
|
|
1381
1397
|
const paymentAttemptFactory = (apiPaymentAttempt) => {
|
|
1398
|
+
var _a;
|
|
1382
1399
|
let paymentAttemptData = null;
|
|
1383
1400
|
if (apiPaymentAttempt.type === 'mondido') {
|
|
1384
1401
|
const data = apiPaymentAttempt.payment_data;
|
|
@@ -1389,7 +1406,7 @@ const paymentAttemptFactory = (apiPaymentAttempt) => {
|
|
|
1389
1406
|
}
|
|
1390
1407
|
else if (apiPaymentAttempt.type === 'swish') {
|
|
1391
1408
|
paymentAttemptData = {
|
|
1392
|
-
paymentRequestToken: apiPaymentAttempt.payment_data.payment_request_token
|
|
1409
|
+
paymentRequestToken: (_a = apiPaymentAttempt.payment_data) === null || _a === void 0 ? void 0 : _a.payment_request_token
|
|
1393
1410
|
};
|
|
1394
1411
|
}
|
|
1395
1412
|
else {
|
|
@@ -1463,6 +1480,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.11", ngImpo
|
|
|
1463
1480
|
}]
|
|
1464
1481
|
}], ctorParameters: function () { return [{ type: ApiService }]; } });
|
|
1465
1482
|
|
|
1483
|
+
const activityLocationGroupFactory = (apiActivityLocationGroup) => {
|
|
1484
|
+
return new ActivityLocationGroup(apiActivityLocationGroup.id, apiActivityLocationGroup.club_id, apiActivityLocationGroup.section_id, apiActivityLocationGroup.active, apiActivityLocationGroup.name, apiActivityLocationGroup.locations && apiActivityLocationGroup.locations.length ? apiActivityLocationGroup.locations.map((apiActivityLocation) => activityLocationFactory(apiActivityLocation)) : []);
|
|
1485
|
+
};
|
|
1486
|
+
|
|
1466
1487
|
const MEMBER_ACTIVITY_INVITE_PATH = ':memberId/activities/:activityInviteId/';
|
|
1467
1488
|
const MEMBER_ACTIVITY_INVITES_PATH = ':memberId/activities/';
|
|
1468
1489
|
const MEMBER_CALENDAR_PATH = ':memberId/activities/calendar/';
|
|
@@ -1475,10 +1496,12 @@ const TEAM_ACTIVITY_NEW_PATH = ':teamId/activities/new/';
|
|
|
1475
1496
|
const TEAM_ACTIVITY_PARTICIPANTS_PATH = ':teamId/activities/:activityId/participants/';
|
|
1476
1497
|
const TEAM_ACTIVITY_PATH = ':teamId/activities/:id/';
|
|
1477
1498
|
const TEAM_ACTIVITY_SETTINGS_PATH = ':teamId/activities/settings/';
|
|
1499
|
+
const CLUB_ACTIVITY_SETTINGS_PATH = ':clubId/activities/settings/';
|
|
1478
1500
|
const TEAM_ACTIVITY_TYPES_PATH = ':teamId/activities/types/';
|
|
1479
1501
|
const TEAM_CALENDAR_PATH = ':teamId/activities/calendar/';
|
|
1480
1502
|
const TEAM_ACTIVITY_LOCATIONS_PATH = ':teamId/activities/locations/';
|
|
1481
1503
|
const CLUB_ACTIVITY_LOCATIONS_PATH = ':clubId/activities/locations/';
|
|
1504
|
+
const CLUB_ACTIVITY_LOCATION_GROUPS_PATH = ':clubId/activities/locations/groups/';
|
|
1482
1505
|
class ActivityService {
|
|
1483
1506
|
constructor(apiService) {
|
|
1484
1507
|
this.apiService = apiService;
|
|
@@ -1571,6 +1594,16 @@ class ActivityService {
|
|
|
1571
1594
|
this.activityLocationCollection = activityLocationCollection;
|
|
1572
1595
|
}));
|
|
1573
1596
|
}
|
|
1597
|
+
getClubActivityLocationGroups(clubId) {
|
|
1598
|
+
if (this.activityLocationGroupResponseDate && this.activityLocationGroupResponseDate > sub(new Date(), { hours: 1 })) {
|
|
1599
|
+
return of(this.activityLocationGroupCollection);
|
|
1600
|
+
}
|
|
1601
|
+
return this.apiService
|
|
1602
|
+
.getCollection(activityLocationGroupFactory, Role.ClubAdmin, CLUB_ACTIVITY_LOCATION_GROUPS_PATH, { clubId }, { params: { limit: 'null' } }).pipe(tap((activityLocationGroupCollection) => {
|
|
1603
|
+
this.activityLocationGroupResponseDate = new Date();
|
|
1604
|
+
this.activityLocationGroupCollection = activityLocationGroupCollection;
|
|
1605
|
+
}));
|
|
1606
|
+
}
|
|
1574
1607
|
getTeamActivityNew(teamId) {
|
|
1575
1608
|
return this.apiService
|
|
1576
1609
|
.getResource(activityFactory, Role.TeamAdmin, TEAM_ACTIVITY_NEW_PATH, { teamId });
|
|
@@ -1588,6 +1621,12 @@ class ActivityService {
|
|
|
1588
1621
|
teamId
|
|
1589
1622
|
});
|
|
1590
1623
|
}
|
|
1624
|
+
getClubActivitySettings(clubId) {
|
|
1625
|
+
return this.apiService
|
|
1626
|
+
.getResource(activitySettingsFactory, Role.ClubAdmin, CLUB_ACTIVITY_SETTINGS_PATH, {
|
|
1627
|
+
clubId,
|
|
1628
|
+
});
|
|
1629
|
+
}
|
|
1591
1630
|
getTeamActivityTypes(teamId) {
|
|
1592
1631
|
if (this.activityTypeResponseDate && this.activityTypeResponseDate > sub(new Date(), { hours: 1 })) {
|
|
1593
1632
|
return of(this.activityTypeCollection);
|
|
@@ -1650,7 +1689,8 @@ class ActivityService {
|
|
|
1650
1689
|
}
|
|
1651
1690
|
updateTeamActivityParticipants(teamId, activityId, members) {
|
|
1652
1691
|
return this.apiService
|
|
1653
|
-
.postResource(() => {
|
|
1692
|
+
.postResource(() => {
|
|
1693
|
+
}, Role.TeamAdmin, TEAM_ACTIVITY_PARTICIPANTS_PATH, {
|
|
1654
1694
|
teamId,
|
|
1655
1695
|
activityId
|
|
1656
1696
|
}, {
|
|
@@ -1683,12 +1723,13 @@ const bookingCalendarFactory = (apiBookingCalendar) => new BookingCalendar(apiBo
|
|
|
1683
1723
|
|
|
1684
1724
|
const bookingCalendarSlotSessionFactory = (apiBookingSlotSession) => new BookingCalendarSlotSession(apiBookingSlotSession.id, apiBookingSlotSession.section_id, apiBookingSlotSession.slot_id, apiBookingSlotSession.team_id, apiBookingSlotSession.end_time, apiBookingSlotSession.section_name, apiBookingSlotSession.start_time, apiBookingSlotSession.team_name);
|
|
1685
1725
|
|
|
1686
|
-
const bookingCalendarSlotFactory = (apiBookingSlot) => new BookingCalendarSlot(apiBookingSlot.id, apiBookingSlot.calendar_id, apiBookingSlot.location_id, apiBookingSlot.color, apiBookingSlot.day, apiBookingSlot.end_time, apiBookingSlot.location_name, apiBookingSlot.number_of_available_sessions, apiBookingSlot.sessions && apiBookingSlot.sessions.length ? apiBookingSlot.sessions.map((apiBookingSlotSession) => bookingCalendarSlotSessionFactory(apiBookingSlotSession)) : [], apiBookingSlot.start_time, apiBookingSlot.type);
|
|
1726
|
+
const bookingCalendarSlotFactory = (apiBookingSlot) => new BookingCalendarSlot(apiBookingSlot.id, apiBookingSlot.calendar_id, apiBookingSlot.location_id, apiBookingSlot.color, apiBookingSlot.day, apiBookingSlot.end_time, apiBookingSlot.group_id, apiBookingSlot.location_name, apiBookingSlot.number_of_available_sessions, apiBookingSlot.sessions && apiBookingSlot.sessions.length ? apiBookingSlot.sessions.map((apiBookingSlotSession) => bookingCalendarSlotSessionFactory(apiBookingSlotSession)) : [], apiBookingSlot.start_time, apiBookingSlot.type, 'none', false, 6, format(new Date(), 'yyyy-MM-dd'), 'repeat_until');
|
|
1687
1727
|
|
|
1688
1728
|
const CLUB_BOOKING_CALENDARS_PATH = ':clubId/activities/calendars/';
|
|
1689
1729
|
const CLUB_BOOKING_CALENDAR_PATH = ':clubId/activities/calendars/:id/';
|
|
1690
1730
|
const CLUB_BOOKING_CALENDAR_SLOTS_PATH = ':clubId/activities/slots/';
|
|
1691
1731
|
const CLUB_BOOKING_CALENDAR_SLOT_PATH = ':clubId/activities/slots/:id/';
|
|
1732
|
+
const CLUB_BOOKING_CALENDAR_REPEATABLE_SLOT_PATH = ':clubId/activities/slots/:id/all/';
|
|
1692
1733
|
const CLUB_BOOKING_CALENDAR_SLOT_SESSIONS_PATH = ':clubId/activities/sessions/';
|
|
1693
1734
|
const CLUB_BOOKING_CALENDAR_SLOT_SESSION_PATH = ':clubId/activities/sessions/:id/';
|
|
1694
1735
|
class BookingCalendarService {
|
|
@@ -1740,7 +1781,7 @@ class BookingCalendarService {
|
|
|
1740
1781
|
clubId,
|
|
1741
1782
|
}, slot);
|
|
1742
1783
|
}
|
|
1743
|
-
getClubBookingCalendarSlots(clubId, startDate = null, endDate = null) {
|
|
1784
|
+
getClubBookingCalendarSlots(clubId, startDate = null, endDate = null, calendarIds = null, locationIds = null) {
|
|
1744
1785
|
const params = { limit: 'null' };
|
|
1745
1786
|
if (startDate) {
|
|
1746
1787
|
params['day__gte'] = startDate;
|
|
@@ -1748,6 +1789,12 @@ class BookingCalendarService {
|
|
|
1748
1789
|
if (endDate) {
|
|
1749
1790
|
params['day__lte'] = endDate;
|
|
1750
1791
|
}
|
|
1792
|
+
if (calendarIds && calendarIds.length) {
|
|
1793
|
+
params['calendar_id'] = calendarIds.join(',');
|
|
1794
|
+
}
|
|
1795
|
+
if (locationIds && locationIds.length) {
|
|
1796
|
+
params['location_id'] = locationIds.join(',');
|
|
1797
|
+
}
|
|
1751
1798
|
return this.apiService
|
|
1752
1799
|
.getCollection(bookingCalendarSlotFactory, Role.ClubAdmin, CLUB_BOOKING_CALENDAR_SLOTS_PATH, { clubId }, {
|
|
1753
1800
|
params
|
|
@@ -1771,6 +1818,13 @@ class BookingCalendarService {
|
|
|
1771
1818
|
id
|
|
1772
1819
|
});
|
|
1773
1820
|
}
|
|
1821
|
+
deleteClubBookingCalendarSlotRepeatable(clubId, id) {
|
|
1822
|
+
return this.apiService
|
|
1823
|
+
.deleteResource(Role.ClubAdmin, CLUB_BOOKING_CALENDAR_REPEATABLE_SLOT_PATH, {
|
|
1824
|
+
clubId,
|
|
1825
|
+
id
|
|
1826
|
+
});
|
|
1827
|
+
}
|
|
1774
1828
|
// endregion
|
|
1775
1829
|
// region Booking calendar slot session
|
|
1776
1830
|
createClubBookingCalendarSlotSession(clubId, session) {
|
|
@@ -2134,9 +2188,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.11", ngImpo
|
|
|
2134
2188
|
}], ctorParameters: function () { return [{ type: ApiService }]; } });
|
|
2135
2189
|
|
|
2136
2190
|
class ApiPaymentAttemptCreate {
|
|
2137
|
-
constructor(invoice_id, type) {
|
|
2191
|
+
constructor(invoice_id, type, telephone_number) {
|
|
2138
2192
|
this.invoice_id = invoice_id;
|
|
2139
2193
|
this.type = type;
|
|
2194
|
+
this.telephone_number = telephone_number;
|
|
2140
2195
|
}
|
|
2141
2196
|
}
|
|
2142
2197
|
|
|
@@ -2148,11 +2203,11 @@ class PaymentAttemptService {
|
|
|
2148
2203
|
constructor(apiService) {
|
|
2149
2204
|
this.apiService = apiService;
|
|
2150
2205
|
}
|
|
2151
|
-
createMemberPaymentAttempt(memberId, invoiceId, type) {
|
|
2152
|
-
return this.createPaymentAttempt(Role.MemberAdmin, MEMBER_PAYMENTS_PATH, { memberId, invoiceId }, new ApiPaymentAttemptCreate(invoiceId, type));
|
|
2206
|
+
createMemberPaymentAttempt(memberId, invoiceId, type, phoneNumber = '') {
|
|
2207
|
+
return this.createPaymentAttempt(Role.MemberAdmin, MEMBER_PAYMENTS_PATH, { memberId, invoiceId }, new ApiPaymentAttemptCreate(invoiceId, type, phoneNumber));
|
|
2153
2208
|
}
|
|
2154
|
-
createPublicPaymentAttempt(invoiceId, token, type) {
|
|
2155
|
-
return this.createPaymentAttempt(Role.Public, PUBLIC_PAYMENTS_PATH, { invoiceId, token }, new ApiPaymentAttemptCreate(invoiceId, type));
|
|
2209
|
+
createPublicPaymentAttempt(invoiceId, token, type, phoneNumber = '') {
|
|
2210
|
+
return this.createPaymentAttempt(Role.Public, PUBLIC_PAYMENTS_PATH, { invoiceId, token }, new ApiPaymentAttemptCreate(invoiceId, type, phoneNumber));
|
|
2156
2211
|
}
|
|
2157
2212
|
getMemberPaymentAttempt(memberId, invoiceId, id) {
|
|
2158
2213
|
return this.getPaymentAttempt(Role.MemberAdmin, MEMBER_PAYMENT_PATH, { memberId, invoiceId, id: id.toString() });
|
|
@@ -2871,5 +2926,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.11", ngImpo
|
|
|
2871
2926
|
* Generated bundle index. Do not edit.
|
|
2872
2927
|
*/
|
|
2873
2928
|
|
|
2874
|
-
export { APP, Activity, ActivityExtraMember, ActivityInvite, ActivityLocation, ActivityService, ActivitySettings, ActivityType, Auth, AuthMember, AuthSection, AuthService, AuthTeam, AuthTeamSection, AuthenticatedGuard, Authentication, AuthenticationInterceptor, AuthenticationService, BookingCalendar, BookingCalendarService, BookingCalendarSlot, BookingCalendarSlotSession, Calendar, CalendarEvent, Card, CardDeal, CardLogo, CardLogoUrls, CardMemberTicket, CardTheme, CardTicket, CardTicketLocation, Club, ClubImage, ClubSection, ClubService, Collection, ConstantService, Contact, CreditCard, DataAccessModule, Directory, Email,
|
|
2929
|
+
export { APP, Activity, ActivityExtraMember, ActivityInvite, ActivityLocation, ActivityLocationGroup, ActivityService, ActivitySettings, ActivityType, Auth, AuthMember, AuthSection, AuthService, AuthTeam, AuthTeamSection, AuthenticatedGuard, Authentication, AuthenticationInterceptor, AuthenticationService, BookingCalendar, BookingCalendarService, BookingCalendarSlot, BookingCalendarSlotSession, Calendar, CalendarEvent, Card, CardDeal, CardLogo, CardLogoUrls, CardMemberTicket, CardTheme, CardTicket, CardTicketLocation, Club, ClubImage, ClubSection, ClubService, Collection, ConstantService, Contact, CreditCard, DataAccessModule, Directory, Email, EmailService, Event, ExternalLink, ExternalLinkService, FileObject, FileService, GeneralImage, Giro, HandleGrantTokenGuard, HomeTeam, ImageUrls, InvoiceService, Member, MemberActivityInvite, MemberAttribute, MemberCard, MemberCardService, MemberContact, MemberFee, MemberFunction, MemberInvoice, MemberInvoiceRow, MemberPublicForm, MemberPublicFormService, MemberService, MemberTeam, MemberTeamThrough, MemberValidationSettings, News, NewsService, Partner, PaymentAttempt, PaymentAttemptService, Role, SearchClub, SearchMember, SearchMemberCard, SearchMemberInvoice, SearchTeam, Section, SectionService, Swish, SwishQrCode, TeamService, Token, TokenService, USER_NOTIFICATIONS_PATH, UnpaidMemberInvoice, User, UserNotification, UserNotificationService, UserService, Zimpler };
|
|
2875
2930
|
//# sourceMappingURL=myclub_se-data-access.mjs.map
|