Services/shows: add function to remove show

This commit is contained in:
Toast 2025-02-04 14:14:44 +01:00
parent bd10e76379
commit 1b19988279
2 changed files with 9 additions and 0 deletions

View file

@ -4,6 +4,7 @@ import {Observable} from 'rxjs';
import {ShowsApiResponse} from '../../interfaces/shows-api-response';
import {ShowsApiCreation} from '../../interfaces/shows-api-creation';
import {ShowsApiIdResponse} from '../../interfaces/shows-api-id-response';
import {ShowsApiDeletion} from '../../interfaces/shows-api-deletion';
@Injectable({
providedIn: 'root'
@ -29,4 +30,8 @@ export class ShowsApiService {
sendShow(newShow: {}) {
return this.http.post<ShowsApiCreation>(this.showsEndpoint, newShow)
}
deleteShw(id: string): Observable<ShowsApiDeletion> {
return this.http.delete<ShowsApiDeletion>(this.showsEndpoint + "id/" + id)
}
}