tickera-angular-components 0.0.1-dev.94 → 0.0.1-dev.96
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.
|
@@ -2551,13 +2551,20 @@ class PerformanceService {
|
|
|
2551
2551
|
constructor(apiService) {
|
|
2552
2552
|
this.apiService = apiService;
|
|
2553
2553
|
}
|
|
2554
|
-
fetchPerformances(showId, search) {
|
|
2554
|
+
fetchPerformances({ showId, roomMapId, hallId, search, page, limit, }) {
|
|
2555
2555
|
const queryParams = new URLSearchParams();
|
|
2556
2556
|
if (showId)
|
|
2557
2557
|
queryParams.append('show_id', showId.toString());
|
|
2558
|
+
if (roomMapId)
|
|
2559
|
+
queryParams.append('room_map_id', roomMapId.toString());
|
|
2560
|
+
if (hallId)
|
|
2561
|
+
queryParams.append('hall_id', hallId.toString());
|
|
2558
2562
|
if (search)
|
|
2559
2563
|
queryParams.append('search', search);
|
|
2560
|
-
|
|
2564
|
+
if (page)
|
|
2565
|
+
queryParams.append('page', page.toString());
|
|
2566
|
+
if (limit)
|
|
2567
|
+
queryParams.append('limit', limit.toString());
|
|
2561
2568
|
const queryString = queryParams.toString();
|
|
2562
2569
|
const apiRoute = `${PERFORMANCES_API_ROUTES.findAll}${queryString ? '?' + queryString : ''}`;
|
|
2563
2570
|
return this.apiService.get(apiRoute);
|
|
@@ -2576,7 +2583,7 @@ class PerformanceService {
|
|
|
2576
2583
|
return this.apiService.get(apiRoute);
|
|
2577
2584
|
}
|
|
2578
2585
|
loadPerformances({ showId, search } = {}) {
|
|
2579
|
-
this.fetchPerformances(showId, search).subscribe({
|
|
2586
|
+
this.fetchPerformances({ showId, search }).subscribe({
|
|
2580
2587
|
next: ({ data }) => {
|
|
2581
2588
|
this.performancesSubject.next(data?.performances ?? []);
|
|
2582
2589
|
},
|