diff --git a/ios/Flutter/.last_build_id b/ios/Flutter/.last_build_id index 9694297e..3aa2cd1e 100644 --- a/ios/Flutter/.last_build_id +++ b/ios/Flutter/.last_build_id @@ -1 +1 @@ -067d482a9455eae7d109c3ac5a36de46 \ No newline at end of file +3f3d14a0ae775b56806906c2cb14a1f0 \ No newline at end of file diff --git a/ios/Runner/Helper/HMGPlatformBridge.swift b/ios/Runner/Helper/HMGPlatformBridge.swift index ba7fefbd..f897188c 100644 --- a/ios/Runner/Helper/HMGPlatformBridge.swift +++ b/ios/Runner/Helper/HMGPlatformBridge.swift @@ -40,8 +40,11 @@ class HMGPlatformBridge{ }else if methodCall.method == "isHMGNetworkAvailable"{ self.isHMGNetworkAvailable(methodCall:methodCall, result: result) - }else if methodCall.method == "unRegisterHmgGeofences"{ + }else if methodCall.method == "registerHmgGeofences"{ self.registerHmgGeofences(result: result) + + }else if methodCall.method == "unRegisterHmgGeofences"{ + self.unRegisterHmgGeofences(result: result) } print("") diff --git a/ios/Runner/Helper/HMG_Geofence.swift b/ios/Runner/Helper/HMG_Geofence.swift index 16247980..85892d3e 100644 --- a/ios/Runner/Helper/HMG_Geofence.swift +++ b/ios/Runner/Helper/HMG_Geofence.swift @@ -73,7 +73,7 @@ class HMG_Geofence:NSObject{ func unRegisterAll(){ for region in locationManager.monitoredRegions { - locationManager.stopMonitoring(for: circularRegion) + locationManager.stopMonitoring(for: region) } } diff --git a/lib/core/service/geofencing/GeofencingServices.dart b/lib/core/service/geofencing/GeofencingServices.dart index 4946f2c2..e8308480 100644 --- a/lib/core/service/geofencing/GeofencingServices.dart +++ b/lib/core/service/geofencing/GeofencingServices.dart @@ -56,10 +56,10 @@ class GeofencingServices extends BaseService { } addTestingGeoZones(List zones) { - zones.add({"GEOF_ID": 12, "Description": "ZiK Home", "Latitude": "24.691136", "Longitude": "46.650116", "Radius": 100, "Type": 1}); - zones.add({"GEOF_ID": 13, "Description": "CS Office", "Latitude": "24.7087913", "Longitude": "46.6656461", "Radius": 100, "Type": 1}); - zones.add({"GEOF_ID": 14, "Description": "Mahmoud Shrouf Home", "Latitude": "24.777577", "Longitude": "46.652675", "Radius": 100, "Type": 1}); - zones.add({"GEOF_ID": 14, "Description": "Panorama Mall", "Latitude": "24.692453", "Longitude": "46.669168", "Radius": 450, "Type": 1}); - zones.add({"GEOF_ID": 16, "Description": "Saudi Architects Crossing", "Latitude": "24.698375", "Longitude": "46.668567", "Radius": 140, "Type": 1}); + // zones.add({"GEOF_ID": 12, "Description": "ZiK Home", "Latitude": "24.691136", "Longitude": "46.650116", "Radius": 100, "Type": 1}); + // zones.add({"GEOF_ID": 13, "Description": "CS Office", "Latitude": "24.7087913", "Longitude": "46.6656461", "Radius": 100, "Type": 1}); + // zones.add({"GEOF_ID": 14, "Description": "Mahmoud Shrouf Home", "Latitude": "24.777577", "Longitude": "46.652675", "Radius": 100, "Type": 1}); + // zones.add({"GEOF_ID": 14, "Description": "Panorama Mall", "Latitude": "24.692453", "Longitude": "46.669168", "Radius": 450, "Type": 1}); + // zones.add({"GEOF_ID": 16, "Description": "Saudi Architects Crossing", "Latitude": "24.698375", "Longitude": "46.668567", "Radius": 140, "Type": 1}); } } diff --git a/lib/uitl/PlatformBridge.dart b/lib/uitl/PlatformBridge.dart index 146ab853..3ad91cdd 100644 --- a/lib/uitl/PlatformBridge.dart +++ b/lib/uitl/PlatformBridge.dart @@ -135,7 +135,7 @@ class PlatformBridge { void showLoading(String message, bool show) async { print("Invoking platform method: $show_loading_method"); try { - final int result = await platform.invokeMethod(show_loading_method, [message, show]); + var result = await platform.invokeMethod(show_loading_method, [message, show]); } on PlatformException catch (e) { print(e); } @@ -143,10 +143,10 @@ class PlatformBridge { // GEO Fences void registerHmgGeofences() async { - final int result = await platform.invokeMethod(register_Hmg_Geofences); + var result = await platform.invokeMethod(register_Hmg_Geofences); } void unRegisterHmgGeofences() async { - final int result = await platform.invokeMethod(un_register_Hmg_Geofences); + var result = await platform.invokeMethod(un_register_Hmg_Geofences); } }