1/19/1
This commit is contained in:
@@ -27,6 +27,7 @@ class HomeCaptainController extends GetxController {
|
||||
String totalMoneyInSEFER = '0';
|
||||
String totalDurationToday = '0';
|
||||
Timer? timer;
|
||||
late LatLng myLocation;
|
||||
String totalPoints = '0';
|
||||
String countRefuse = '0';
|
||||
bool mapType = false;
|
||||
@@ -146,7 +147,7 @@ class HomeCaptainController extends GetxController {
|
||||
mapHomeCaptaiController = controller;
|
||||
controller.getVisibleRegion();
|
||||
controller.animateCamera(
|
||||
CameraUpdate.newLatLng(locationController.myLocation),
|
||||
CameraUpdate.newLatLng(Get.find<LocationController>().myLocation),
|
||||
);
|
||||
update();
|
||||
}
|
||||
@@ -181,6 +182,8 @@ class HomeCaptainController extends GetxController {
|
||||
@override
|
||||
void onInit() async {
|
||||
await addToken();
|
||||
// await Get.find<LocationController>().getLocation();
|
||||
|
||||
onButtonSelected();
|
||||
getPaymentToday();
|
||||
getAllPayment();
|
||||
@@ -188,6 +191,7 @@ class HomeCaptainController extends GetxController {
|
||||
onMapCreated(mapHomeCaptaiController!);
|
||||
getRefusedOrderByCaptain();
|
||||
totalPoints = Get.find<CaptainWalletController>().totalPoints;
|
||||
// LocationController().getLocation();
|
||||
super.onInit();
|
||||
}
|
||||
|
||||
|
||||
@@ -73,13 +73,13 @@ class MapDriverController extends GetxController {
|
||||
String? mapAPIKEY;
|
||||
final zones = <Zone>[];
|
||||
|
||||
void onMapCreated(GoogleMapController controller) {
|
||||
LocationController locationController = Get.find<LocationController>();
|
||||
myLocation = locationController.myLocation;
|
||||
void onMapCreated(GoogleMapController controller) async {
|
||||
myLocation = Get.find<LocationController>().location as LatLng;
|
||||
myLocation = myLocation;
|
||||
mapController = controller;
|
||||
controller.getVisibleRegion();
|
||||
controller.animateCamera(
|
||||
CameraUpdate.newLatLngZoom(myLocation, 17),
|
||||
CameraUpdate.newLatLng(myLocation),
|
||||
);
|
||||
update();
|
||||
|
||||
@@ -442,6 +442,7 @@ class MapDriverController extends GetxController {
|
||||
rideId = Get.arguments['rideId'];
|
||||
durationOfRideValue = Get.arguments['durationOfRideValue'];
|
||||
paymentAmount = Get.arguments['paymentAmount'];
|
||||
paymentMethod = Get.arguments['paymentMethod'];
|
||||
isHaveSteps = Get.arguments['isHaveSteps'];
|
||||
step0 = Get.arguments['step0'];
|
||||
step1 = Get.arguments['step1'];
|
||||
|
||||
Reference in New Issue
Block a user