read method

Future<void> read()

Implementation

Future<void> read() async {
  state.loading();
  await UServices.accounting.report(
    p: UAccountingReportParams(userId: user.value?.id, fromDate: startDate, toDate: endDate),
    onOk: (UResponse<UAccountingReportResponse> r) {
      report.value = r.result;
      state.loaded();
    },
    onError: (UEmptyResponse e) => setError(e.message),
    onException: setError,
  );
}