Skip to content

Commit

Permalink
fix bug: number of reports that display in calendar view is the same …
Browse files Browse the repository at this point in the history
…as the limit, offset from list view.
  • Loading branch information
pphetra committed Nov 4, 2023
1 parent 183f355 commit 8691459
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions components/report/listViewModel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -101,9 +101,17 @@ export class ReportListViewModel extends BaseViewModel {

async fetch(force?: boolean): Promise<void> {
this.isLoading = true;

let limit = this.limit;
let offset = this.offset;
if (this.isCalendarView) {
limit = 500;
offset = 0;
}

const result = await this.reportService.fetchReports(
this.limit,
this.offset,
limit,
offset,
this.filter,
force
);
Expand Down

0 comments on commit 8691459

Please sign in to comment.