Skip to content

Commit

Permalink
fix insights docs
Browse files Browse the repository at this point in the history
  • Loading branch information
DenysVuika committed Sep 28, 2023
1 parent 0ee5bb9 commit 306cc25
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,8 @@ export class AnalyticsReportListComponent implements OnInit {

/**
* Reload the component
*
* @param reportId report id
*/
reload(reportId?: number) {
this.reset();
Expand All @@ -88,8 +90,11 @@ export class AnalyticsReportListComponent implements OnInit {

/**
* Get the report list
*
* @param appId application id
* @param reportId report id
*/
getReportList(appId: number, reportId?: number) {
getReportList(appId: number, reportId?: number): void {
this.analyticsService.getReportList(appId).subscribe(
(res: ReportParametersModel[]) => {
if (res && res.length === 0) {
Expand Down Expand Up @@ -133,6 +138,8 @@ export class AnalyticsReportListComponent implements OnInit {

/**
* Check if the report list is empty
*
* @returns `true` if report list is empty, otherwise `false`
*/
isReportsEmpty(): boolean {
return this.reports === undefined || (this.reports && this.reports.length === 0);
Expand All @@ -141,7 +148,7 @@ export class AnalyticsReportListComponent implements OnInit {
/**
* Select the current report
*
* @param report
* @param report report model
*/
selectReport(report: any) {
this.currentReport = report;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,9 @@ export class AnalyticsService {

/**
* Retrieve all the Deployed app
*
* @param appId application id
* @returns list or report parameter models
*/
getReportList(appId: number): Observable<ReportParametersModel[]> {
return from(this.reportApi.getReportList())
Expand All @@ -72,7 +75,8 @@ export class AnalyticsService {
/**
* Retrieve Report by name
*
* @param reportName - string - The name of report
* @param reportName - The name of report
* @returns report model
*/
getReportByName(reportName: string): Observable<any> {
return from(this.reportApi.getReportList())
Expand Down

0 comments on commit 306cc25

Please sign in to comment.