4/2/1
This commit is contained in:
@@ -47,9 +47,9 @@ class MapPassengerController extends GetxController {
|
||||
List<LatLng> bounds = [];
|
||||
List placesStart = [];
|
||||
List<String> driversToken = [];
|
||||
LatLng previousLocationOfDrivers = LatLng(0, 0);
|
||||
LatLng previousLocationOfDrivers = const LatLng(0, 0);
|
||||
double angleDegrees = 0;
|
||||
LatLng currentLocationOfDrivers = LatLng(0, 0);
|
||||
LatLng currentLocationOfDrivers = const LatLng(0, 0);
|
||||
List<TextEditingController> allTextEditingPlaces = [];
|
||||
List placesDestination = [];
|
||||
List wayPoint0 = [];
|
||||
@@ -598,7 +598,6 @@ class MapPassengerController extends GetxController {
|
||||
rideTimerBegin = false;
|
||||
isRideFinished = true;
|
||||
update();
|
||||
|
||||
}
|
||||
|
||||
void tripFinishedFromDriver() async {
|
||||
@@ -670,7 +669,8 @@ class MapPassengerController extends GetxController {
|
||||
remainingTime = 0;
|
||||
// isCancelRidePageShown = true;
|
||||
update();
|
||||
rideIsBeginPassengerTimer();runWhenRideIsBegin();
|
||||
rideIsBeginPassengerTimer();
|
||||
runWhenRideIsBegin();
|
||||
}
|
||||
|
||||
void cancelTimerToPassengerFromDriverAfterApplied() {
|
||||
@@ -832,6 +832,7 @@ class MapPassengerController extends GetxController {
|
||||
startNameAddress,
|
||||
endNameAddress,
|
||||
box.read(BoxName.carType),
|
||||
kazan.toStringAsFixed(0),
|
||||
];
|
||||
print(body);
|
||||
FirebaseMessagesController().sendNotificationToDriverMapPolyline(
|
||||
@@ -908,6 +909,7 @@ class MapPassengerController extends GetxController {
|
||||
startNameAddress,
|
||||
endNameAddress,
|
||||
box.read(BoxName.carType),
|
||||
kazan.toStringAsFixed(0),
|
||||
];
|
||||
print('driversToken');
|
||||
print(driversToken);
|
||||
@@ -1133,7 +1135,7 @@ class MapPassengerController extends GetxController {
|
||||
}
|
||||
}
|
||||
|
||||
LatLng driverLocationToPassenger = LatLng(32, 35);
|
||||
LatLng driverLocationToPassenger = const LatLng(32, 35);
|
||||
Future getDriverCarsLocationToPassengerAfterApplied() async {
|
||||
driverCarsLocationToPassengerAfterApplied = [];
|
||||
|
||||
@@ -1187,8 +1189,8 @@ class MapPassengerController extends GetxController {
|
||||
void clearMarkersExceptStartEnd() {
|
||||
Set<Marker> markersToRemove = markers
|
||||
.where((marker) =>
|
||||
marker.markerId != MarkerId("start") &&
|
||||
marker.markerId != MarkerId("end"))
|
||||
marker.markerId != const MarkerId("start") &&
|
||||
marker.markerId != const MarkerId("end"))
|
||||
.toSet();
|
||||
|
||||
for (Marker marker in markersToRemove) {
|
||||
@@ -1201,10 +1203,10 @@ class MapPassengerController extends GetxController {
|
||||
clearMarkersExceptStartEnd();
|
||||
// for (var i = 0; i < driverCarsLocationToPassengerAfterApplied.length; i++) {
|
||||
LatLng driverPosition = LatLng(
|
||||
double.parse(
|
||||
datadriverCarsLocationToPassengerAfterApplied[0]['latitude']),
|
||||
double.parse(
|
||||
datadriverCarsLocationToPassengerAfterApplied[0]['longitude']));
|
||||
double.parse(datadriverCarsLocationToPassengerAfterApplied['message'][0]
|
||||
['latitude']),
|
||||
double.parse(datadriverCarsLocationToPassengerAfterApplied['message'][0]
|
||||
['longitude']));
|
||||
final driverAcceptedMarker = Marker(
|
||||
markerId: const MarkerId('driverToPassengers'),
|
||||
position: driverPosition,
|
||||
@@ -1921,14 +1923,14 @@ class MapPassengerController extends GetxController {
|
||||
data[0]["start_location"]['lat'], data[0]["start_location"]['lng']);
|
||||
markers.add(
|
||||
Marker(
|
||||
markerId: MarkerId('start'),
|
||||
markerId: const MarkerId('start'),
|
||||
position: newStartPointLocation,
|
||||
icon: startIcon,
|
||||
),
|
||||
);
|
||||
markers.add(
|
||||
Marker(
|
||||
markerId: MarkerId('end'),
|
||||
markerId: const MarkerId('end'),
|
||||
position: LatLng(
|
||||
data[0]["end_location"]['lat'], data[0]["end_location"]['lng']),
|
||||
icon: endIcon,
|
||||
|
||||
Reference in New Issue
Block a user