integrasi master building dan penyasuaian UI dashboard monitoring building

This commit is contained in:
2024-05-21 16:14:18 +07:00
parent bb10d57139
commit 608c53ab66
17 changed files with 884 additions and 2 deletions

View File

@@ -54,6 +54,15 @@ export class BuildingService {
return this.http.get<any>(url, { headers });
}
getMasterBuildingData(page: number = 1, limit: number = 100): Observable<any> {
const url = `https://kapi.absys.ninja/hemat/building?page=${page}&limit=${limit}`;
const headers = new HttpHeaders({
'Content-Type': 'application/json',
'x-api-key': 'j2yaYvPSQcsEEmHh3NEobfiXyyXmmnHT'
});
return this.http.get<any>(url, { headers });
}
postHeaderDetailParam(data: any): Observable<any> {
const url = `https://kapi.absys.ninja/hemat/header-detail-param`;
const headers = new HttpHeaders({
@@ -79,4 +88,21 @@ export class BuildingService {
});
return this.http.delete<any>(url, { headers });
}
postMasterBuildingParam(data: any): Observable<any> {
const url = `https://kapi.absys.ninja/hemat/building`;
const headers = new HttpHeaders({
'Content-Type': 'application/json',
'x-api-key': 'j2yaYvPSQcsEEmHh3NEobfiXyyXmmnHT'
});
return this.http.post<any>(url, data, { headers });
}
putMasterBuildingParam(data: any, id: any): Observable<any> {
const url = `https://kapi.absys.ninja/hemat/building/${id}`;
const headers = new HttpHeaders({
'Content-Type': 'application/json',
'x-api-key': 'j2yaYvPSQcsEEmHh3NEobfiXyyXmmnHT'
});
return this.http.put<any>(url, data, { headers });
}
}