3/30/3
This commit is contained in:
@@ -1664,7 +1664,8 @@ class MapPassengerController extends GetxController {
|
||||
// }
|
||||
// Add new markers
|
||||
// Example: Add a marker for each item in a list
|
||||
for (var item in carsLocationByPassenger) {
|
||||
// for (var item in carsLocationByPassenger) {
|
||||
for (var i = 0; dataCarsLocationByPassenger['message'].length; i++) {
|
||||
// if (previousLocationOfDrivers != null) {
|
||||
// angleDegrees = calculateAngleBetweenLocations(
|
||||
// previousLocationOfDrivers, currentLocationOfDrivers);
|
||||
@@ -1674,12 +1675,23 @@ class MapPassengerController extends GetxController {
|
||||
// print('currentLocationOfDrivers $currentLocationOfDrivers');
|
||||
// }
|
||||
final marker = Marker(
|
||||
infoWindow: InfoWindow(title: '${item.latitude} minutes'),
|
||||
markerId: MarkerId(durationToPassenger.toString()),
|
||||
position: LatLng(item.latitude, item.longitude),
|
||||
rotation: item.headingList
|
||||
// Other properties for the marker, such as icon, info window, etc.
|
||||
);
|
||||
position: LatLng(
|
||||
double.parse(
|
||||
datadriverCarsLocationToPassengerAfterApplied['message'][i]
|
||||
['latitude']),
|
||||
double.parse(
|
||||
datadriverCarsLocationToPassengerAfterApplied['message'][i]
|
||||
['longitude'])),
|
||||
icon: carIcon,
|
||||
markerId: MarkerId(
|
||||
datadriverCarsLocationToPassengerAfterApplied['message'][i]
|
||||
['longitude']
|
||||
.toString()),
|
||||
rotation: double.parse(
|
||||
datadriverCarsLocationToPassengerAfterApplied['message'][i]
|
||||
['heading']),
|
||||
// Other properties for the marker, such as icon, info window, etc.
|
||||
);
|
||||
markers.add(marker);
|
||||
update();
|
||||
}
|
||||
|
||||
@@ -27,7 +27,7 @@ class PassengerLocationMapPage extends StatelessWidget {
|
||||
const PassengerInfoWindow(),
|
||||
driverEndRideBar(),
|
||||
const SosConnect(),
|
||||
speedCircle(),
|
||||
speedCircle(),
|
||||
const GoogleMapApp(),
|
||||
PricesWindow(),
|
||||
],
|
||||
|
||||
@@ -116,7 +116,7 @@ GetBuilder<MapPassengerController> leftMainMenuIcons() {
|
||||
// .showNotification('Order', 'hi this is', 'tone1');
|
||||
// Get.to(() => DriverCallPage());
|
||||
// print(controller.carLocationsModels);
|
||||
controller.getKazanPercent();
|
||||
// controller.getKazanPercent();
|
||||
// PassengerCallPage(
|
||||
// channelName: '',
|
||||
// token: '',
|
||||
|
||||
Reference in New Issue
Block a user