one api endpoint for admin/non-admin

This commit is contained in:
Thomas Ruoff
2021-06-16 23:18:24 +02:00
parent 498f212ee0
commit b6a1e45fcf
5 changed files with 28 additions and 77 deletions

View File

@@ -75,7 +75,7 @@ export async function createBill(
bookingUuid: string,
bill: Bill
): Promise<Bill> {
return fetch(`/api/admin/booking/${bookingUuid}/bill`, {
return fetch(`/api/booking/${bookingUuid}/bill`, {
method: 'POST',
body: bill,
})
@@ -85,7 +85,7 @@ export async function patchBill(
bookingUuid: string,
bill: Bill
): Promise<Bill> {
return fetch(`/api/admin/booking/${bookingUuid}/bill`, {
return fetch(`/api/booking/${bookingUuid}/bill`, {
method: 'POST',
body: bill,
})