9/24/1-backLocation
This commit is contained in:
@@ -53,7 +53,7 @@ class LocationController extends GetxController {
|
||||
} else if (latitude >= 29.904975 &&
|
||||
latitude <= 30.143372 &&
|
||||
longitude >= 30.787030 &&
|
||||
longitude <= 31.238843) {
|
||||
longitude <= 31.215009) {
|
||||
return 'Giza';
|
||||
} else if (latitude >= 30.396286 &&
|
||||
latitude <= 31.654458 &&
|
||||
@@ -61,7 +61,7 @@ class LocationController extends GetxController {
|
||||
longitude <= 32.626259) {
|
||||
return 'Alexandria';
|
||||
} else {
|
||||
return 'Outside';
|
||||
return 'Cairo';
|
||||
}
|
||||
}
|
||||
|
||||
@@ -102,15 +102,7 @@ class LocationController extends GetxController {
|
||||
endpoint = AppLink.addCarsLocationAlexandriaEndpoint;
|
||||
Log.print('Endpoint: $endpoint');
|
||||
break;
|
||||
case 'Outside':
|
||||
// Handle cases outside of Cairo, Giza, and Alexandria
|
||||
print('Location outside Cairo, Giza, or Alexandria');
|
||||
|
||||
box.write(BoxName.serverChosen, AppLink.seferCairoServer);
|
||||
endpoint = AppLink
|
||||
.addCarsLocationCairoEndpoint; // Fallback to Cairo endpoint
|
||||
Log.print('Fallback Endpoint: $endpoint');
|
||||
break;
|
||||
default:
|
||||
// Handle any other unexpected cases
|
||||
print('Unknown location area');
|
||||
|
||||
Reference in New Issue
Block a user