Update to Stores VersionID 22.0

pull/376/head
haroon amjad 2 months ago
parent 67bdc6123b
commit a02af3897f

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

@ -301,7 +301,7 @@ class ApiConsts {
static String googleCloudStorageENTranslationFileBaseURL = "https://storage.googleapis.com/hmg-patientapp-translations"; static String googleCloudStorageENTranslationFileBaseURL = "https://storage.googleapis.com/hmg-patientapp-translations";
// ************ static values for Api **************** // ************ static values for Api ****************
static final double appVersionID = 21.9; static final double appVersionID = 22.0;
// static final double appVersionID = 50.7; // static final double appVersionID = 50.7;
static final int appChannelId = 3; static final int appChannelId = 3;

@ -11,7 +11,7 @@ import 'package:hmg_patient_app_new/features/insurance/models/resp_models/upload
import 'package:hmg_patient_app_new/services/logger_service.dart'; import 'package:hmg_patient_app_new/services/logger_service.dart';
abstract class InsuranceRepo { abstract class InsuranceRepo {
Future<Either<Failure, GenericApiModel<List<PatientInsuranceDetailsResponseModel>>>> getPatientInsuranceDetails(); Future<Either<Failure, GenericApiModel<List<PatientInsuranceDetailsResponseModel>>>> getPatientInsuranceDetails({bool isFromHomePage = false});
Future<Either<Failure, GenericApiModel<List<PatientInsuranceCardHistoryResponseModel>>>> getPatientInsuranceCardHistory(); Future<Either<Failure, GenericApiModel<List<PatientInsuranceCardHistoryResponseModel>>>> getPatientInsuranceCardHistory();
@ -35,8 +35,10 @@ class InsuranceRepoImp implements InsuranceRepo {
InsuranceRepoImp({required this.loggerService, required this.apiClient}); InsuranceRepoImp({required this.loggerService, required this.apiClient});
@override @override
Future<Either<Failure, GenericApiModel<List<PatientInsuranceDetailsResponseModel>>>> getPatientInsuranceDetails() async { Future<Either<Failure, GenericApiModel<List<PatientInsuranceDetailsResponseModel>>>> getPatientInsuranceDetails({bool isFromHomePage = false}) async {
Map<String, dynamic> mapDevice = {}; Map<String, dynamic> mapDevice = {
"IsFromHomePage": isFromHomePage
};
try { try {
GenericApiModel<List<PatientInsuranceDetailsResponseModel>>? apiResponse; GenericApiModel<List<PatientInsuranceDetailsResponseModel>>? apiResponse;

@ -32,11 +32,11 @@ class InsuranceViewModel extends ChangeNotifier {
InsuranceViewModel({required this.insuranceRepo, required this.errorHandlerService}); InsuranceViewModel({required this.insuranceRepo, required this.errorHandlerService});
initInsuranceProvider() { initInsuranceProvider({bool isFromHomePage = false}) {
if (isInsuranceDataToBeLoaded) { if (isInsuranceDataToBeLoaded) {
patientInsuranceList.clear(); patientInsuranceList.clear();
isInsuranceLoading = true; isInsuranceLoading = true;
getPatientInsuranceDetails(); getPatientInsuranceDetails(isFromHomePage: isFromHomePage);
} }
patientInsuranceCardHistoryList.clear(); patientInsuranceCardHistoryList.clear();
isInsuranceHistoryLoading = true; isInsuranceHistoryLoading = true;
@ -76,12 +76,12 @@ class InsuranceViewModel extends ChangeNotifier {
notifyListeners(); notifyListeners();
} }
Future<void> getPatientInsuranceDetails({Function(dynamic)? onSuccess, Function(String)? onError}) async { Future<void> getPatientInsuranceDetails({bool isFromHomePage = false, Function(dynamic)? onSuccess, Function(String)? onError}) async {
if (!isInsuranceDataToBeLoaded) { if (!isInsuranceDataToBeLoaded) {
return; return;
} }
final result = await insuranceRepo.getPatientInsuranceDetails(); final result = await insuranceRepo.getPatientInsuranceDetails(isFromHomePage: isFromHomePage);
result.fold( result.fold(
// (failure) async => await errorHandlerService.handleError(failure: failure), // (failure) async => await errorHandlerService.handleError(failure: failure),

@ -174,7 +174,7 @@ class _LandingPageState extends State<LandingPage> {
notificationsViewModel.initNotificationsViewModel(); notificationsViewModel.initNotificationsViewModel();
if (Utils.havePrivilege(122)) { if (Utils.havePrivilege(122)) {
insuranceViewModel.initInsuranceProvider(); insuranceViewModel.initInsuranceProvider(isFromHomePage: true);
} }
if (!appState.isRatedVisible) { if (!appState.isRatedVisible) {

@ -2,8 +2,8 @@ name: hmg_patient_app_new
description: "New HMG Patient App" description: "New HMG Patient App"
publish_to: 'none' # Remove this line if you wish to publish to pub.dev publish_to: 'none' # Remove this line if you wish to publish to pub.dev
#version: 0.0.45+46 version: 0.0.48+49
version: 0.0.15+2 #version: 0.0.16+1
environment: environment:
sdk: ">=3.6.0 <4.0.0" sdk: ">=3.6.0 <4.0.0"

Loading…
Cancel
Save