integrasi edit device, penyesuaian UI jadi vertical dan penambahan UI list monitoring

This commit is contained in:
2024-05-31 17:21:39 +07:00
parent b2c1020c22
commit a6c77fe052
23 changed files with 1512 additions and 866 deletions

View File

@@ -81,6 +81,15 @@ export class BuildingService {
return this.http.get<any>(url, { headers });
}
getMasterListData(): Observable<any> {
const url = `https://kapi.absys.ninja/hemat/header-param/list`;
const headers = new HttpHeaders({
'Content-Type': 'application/json',
'x-api-key': 'j2yaYvPSQcsEEmHh3NEobfiXyyXmmnHT'
});
return this.http.get<any>(url, { headers });
}
getMasterData(page: number = 1, limit: number = 100): Observable<any> {
const url = `https://kapi.absys.ninja/hemat/header-param?page=${page}&limit=${limit}`;
const headers = new HttpHeaders({
@@ -194,4 +203,22 @@ export class BuildingService {
});
return this.http.post<any>(url, data, { headers });
}
getBuildingRoomList(page: number = 1, limit: number = 100): Observable<any> {
const url = `https://kapi.absys.ninja/hemat/room-building?page=${page}&limit=${limit}`;
const headers = new HttpHeaders({
'Content-Type': 'application/json',
'x-api-key': 'j2yaYvPSQcsEEmHh3NEobfiXyyXmmnHT'
});
return this.http.get<any>(url, { headers });
}
putDevice(data: any, id: any): Observable<any> {
const url = `https://kapi.absys.ninja/hemat/devices/${id}`;
const headers = new HttpHeaders({
'Content-Type': 'application/json',
'x-api-key': 'j2yaYvPSQcsEEmHh3NEobfiXyyXmmnHT'
});
return this.http.put<any>(url, data, { headers });
}
}