pull/379/head
haroon amjad 1 month ago
parent a4e1ec4459
commit b78c83a32d

@ -211,7 +211,7 @@ class ApiClientImp implements ApiClient {
}
// body['TokenID'] = "@dm!n";
// body['PatientID'] = 5422188;
// body['PatientID'] = 1987471;
// body['PatientID'] = 53320;
// body['PatientTypeID'] = 1;
// body['PatientOutSA'] = 0;

@ -209,12 +209,12 @@ class LabViewModel extends ChangeNotifier {
final result = await labRepo.getLabResultReportPDF(labOrder: labOrder);
result.fold(
(failure) async => await errorHandlerService.handleError(
failure: failure,
onOkPressed: () {
onError!(failure.message);
},
),
// (failure) async => await errorHandlerService.handleError(
(failure) async {
if (onError != null) {
onError(failure.message);
}
},
(apiResponse) {
if (apiResponse.messageStatus == 2) {
onError!(apiResponse.errorMessage!);

@ -0,0 +1,13 @@
import 'package:flutter/material.dart';
import 'package:hmg_patient_app_new/core/app_state.dart';
import 'package:hmg_patient_app_new/services/error_handler_service.dart';
class MyFatoorahViewModel extends ChangeNotifier {
final AppState appState;
final ErrorHandlerService errorHandlerService;
MyFatoorahViewModel({
required this.appState,
required this.errorHandlerService,
});
}
Loading…
Cancel
Save