AP-65 (#87)
All checks were successful
Backend Deploy / build (push) Successful in 22s
Backend Build and Test / build (push) Successful in 2m11s

closes #65

Reviewed-on: #87
This commit was merged in pull request #87.
This commit is contained in:
2025-05-26 09:52:10 +02:00
parent 550933db11
commit e7b4adfa95
6 changed files with 56 additions and 15 deletions

View File

@@ -15,7 +15,15 @@ export class AllowanceService {
return this.http.get<Allowance[]>(`${this.url}/user/${userId}/allowance`);
}
getAllowanceById(allowanceId: number, userId: number): Observable<Allowance> {
return this.http.get<Allowance>(`${this.url}/user/${userId}/allowance/${allowanceId}`);
}
createAllowance(allowance: Partial<Allowance>, userId: number) {
this.http.post(`${this.url}/user/${userId}/allowance`, allowance).subscribe();
}
updateAllowance(allowance: Partial<Allowance>, allowanceId: number, userId: number) {
this.http.put(`${this.url}/user/${userId}/allowance/${allowanceId}`, allowance).subscribe();
}
}