Add System component with table display for custom and all beans

This commit is contained in:
liosha84
2025-06-19 18:36:09 +03:00
parent 4e7af10940
commit ab36ee35b4
24 changed files with 919 additions and 57 deletions
@@ -0,0 +1,22 @@
import { Injectable } from '@angular/core';
import {HttpClient} from '@angular/common/http';
import {Observable} from 'rxjs';
import {Tutorial} from '../models/tutorial.model';
import {Bean} from '../models/Bean';
@Injectable({
providedIn: 'root'
})
export class SystemService {
baseUrl : string = 'http://localhost:8080/api/system';
constructor(private http: HttpClient) { }
getAllBeans(): Observable<Bean[]> {
return this.http.get<Bean[]>(this.baseUrl+"/beans");
}
getCustomBeans(): Observable<Bean[]> {
return this.http.get<Bean[]>(this.baseUrl+"/beans/custom");
}
}