Renamed groups to roles in the frontend
Working: Account Cost Centre Employee Product Group Product Role User Client
This commit is contained in:
1 parent
cd764be49c
commit
6dbab6442f
50 files changed
+272
-295
No files matched your search
@@ -19,7 +19,7 @@ export class CostCentreService {
|
||||
}
|
||||
|
||||
get(id: string): Observable<CostCentre> {
|
||||
const getUrl: string = (id === null) ? `${url}/new` : `${url}/${id}`;
|
||||
const getUrl: string = (id === null) ? `${url}` : `${url}/${id}`;
|
||||
return <Observable<CostCentre>>this.http.get<CostCentre>(getUrl)
|
||||
.pipe(
|
||||
catchError(this.log.handleError(serviceName, `get id=${id}`))
|
||||
@@ -27,15 +27,14 @@ export class CostCentreService {
|
||||
}
|
||||
|
||||
list(): Observable<CostCentre[]> {
|
||||
const options = {params: new HttpParams().set('l', '')};
|
||||
return <Observable<CostCentre[]>>this.http.get<CostCentre[]>(url, options)
|
||||
return <Observable<CostCentre[]>>this.http.get<CostCentre[]>(`${url}/list`)
|
||||
.pipe(
|
||||
catchError(this.log.handleError(serviceName, 'list'))
|
||||
);
|
||||
}
|
||||
|
||||
save(costCentre: CostCentre): Observable<CostCentre> {
|
||||
return <Observable<CostCentre>>this.http.post<CostCentre>(`${url}/new`, costCentre, httpOptions)
|
||||
return <Observable<CostCentre>>this.http.post<CostCentre>(`${url}`, costCentre, httpOptions)
|
||||
.pipe(
|
||||
catchError(this.log.handleError(serviceName, 'save'))
|
||||
);
|
||||
|
||||
Reference in new issue
Block a user