11/15/2
This commit is contained in:
@@ -11,7 +11,7 @@ import '../../functions/crud.dart';
|
|||||||
|
|
||||||
class OrderRequestController extends GetxController {
|
class OrderRequestController extends GetxController {
|
||||||
double progress = 0;
|
double progress = 0;
|
||||||
int duration = 25;
|
int duration = 15;
|
||||||
int remainingTime = 0;
|
int remainingTime = 0;
|
||||||
String countRefuse = '0';
|
String countRefuse = '0';
|
||||||
bool applied = false;
|
bool applied = false;
|
||||||
@@ -84,6 +84,7 @@ class OrderRequestController extends GetxController {
|
|||||||
|
|
||||||
void refuseOrder(String driverID, orderID) async {
|
void refuseOrder(String driverID, orderID) async {
|
||||||
await CRUD().postFromDialogue(link: AppLink.addDriverOrder, payload: {
|
await CRUD().postFromDialogue(link: AppLink.addDriverOrder, payload: {
|
||||||
|
//TODO need review
|
||||||
'driver_id': box.read(BoxName.driverID).toString(),
|
'driver_id': box.read(BoxName.driverID).toString(),
|
||||||
// box.read(BoxName.driverID).toString(),
|
// box.read(BoxName.driverID).toString(),
|
||||||
'order_id': orderID,
|
'order_id': orderID,
|
||||||
|
|||||||
@@ -1,18 +1,15 @@
|
|||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
import 'package:get/get.dart';
|
import 'package:get/get.dart';
|
||||||
import 'package:google_maps_flutter/google_maps_flutter.dart';
|
|
||||||
import 'package:ride/constant/colors.dart';
|
import 'package:ride/constant/colors.dart';
|
||||||
import 'package:ride/constant/style.dart';
|
|
||||||
import 'package:ride/controller/home/map_passenger_controller.dart';
|
import 'package:ride/controller/home/map_passenger_controller.dart';
|
||||||
import 'package:ride/views/home/map_widget.dart/cancel_raide_page.dart';
|
import 'package:ride/views/home/map_widget.dart/cancel_raide_page.dart';
|
||||||
import 'package:ride/views/home/map_widget.dart/ride_begin_passenger.dart';
|
import 'package:ride/views/home/map_widget.dart/ride_begin_passenger.dart';
|
||||||
import 'package:ride/views/widgets/elevated_btn.dart';
|
|
||||||
import 'package:ride/views/widgets/mycircular.dart';
|
|
||||||
|
|
||||||
import '../../controller/home/menu_controller.dart';
|
import '../../controller/home/menu_controller.dart';
|
||||||
import 'map_widget.dart/buttom_sheet_map_show.dart';
|
import 'map_widget.dart/buttom_sheet_map_show.dart';
|
||||||
import 'map_widget.dart/cash_confirm_bottom_page.dart';
|
import 'map_widget.dart/cash_confirm_bottom_page.dart';
|
||||||
import 'map_widget.dart/driver_card_from_passenger.dart';
|
import 'map_widget.dart/driver_card_from_passenger.dart';
|
||||||
|
import 'map_widget.dart/google_map_passenger_widget.dart';
|
||||||
import 'map_widget.dart/left_main_menu_icons.dart';
|
import 'map_widget.dart/left_main_menu_icons.dart';
|
||||||
import 'map_widget.dart/main_bottom_Menu_map.dart';
|
import 'map_widget.dart/main_bottom_Menu_map.dart';
|
||||||
import 'map_widget.dart/map_menu_widget.dart';
|
import 'map_widget.dart/map_menu_widget.dart';
|
||||||
@@ -32,240 +29,7 @@ class MapPagePassenger extends StatelessWidget {
|
|||||||
body: SafeArea(
|
body: SafeArea(
|
||||||
child: Stack(
|
child: Stack(
|
||||||
children: [
|
children: [
|
||||||
GetBuilder<MapPassengerController>(
|
const GoogleMapPassengerWidget(),
|
||||||
builder: (controller) => controller.isLoading
|
|
||||||
? const MyCircularProgressIndicator()
|
|
||||||
: GoogleMap(
|
|
||||||
onMapCreated: controller.onMapCreated,
|
|
||||||
cameraTargetBounds:
|
|
||||||
CameraTargetBounds(controller.boundsdata),
|
|
||||||
minMaxZoomPreference: const MinMaxZoomPreference(6, 18),
|
|
||||||
onLongPress: (argument) {
|
|
||||||
Get.defaultDialog(
|
|
||||||
title: 'Are you want to go to this site'.tr,
|
|
||||||
content: Column(
|
|
||||||
children: [
|
|
||||||
Text(
|
|
||||||
'${argument.latitude},${argument.longitude}'),
|
|
||||||
],
|
|
||||||
),
|
|
||||||
confirm: MyElevatedButton(
|
|
||||||
title: 'Ok'.tr,
|
|
||||||
onPressed: () async {
|
|
||||||
controller.clearPolyline();
|
|
||||||
if (controller.dataCarsLocationByPassenger !=
|
|
||||||
null) {
|
|
||||||
await controller.getMap(
|
|
||||||
'${controller.myLocation.latitude},${controller.myLocation.longitude}',
|
|
||||||
'${argument.latitude.toString()},${argument.longitude.toString()}');
|
|
||||||
|
|
||||||
Get.back();
|
|
||||||
controller.bottomSheet();
|
|
||||||
controller.showBottomSheet1();
|
|
||||||
} else {
|
|
||||||
Get.back();
|
|
||||||
Get.snackbar(
|
|
||||||
'We Are Sorry That we dont have cars in your Location!'
|
|
||||||
.tr,
|
|
||||||
'message',
|
|
||||||
colorText: AppColor.redColor,
|
|
||||||
duration: const Duration(seconds: 11),
|
|
||||||
instantInit: true,
|
|
||||||
snackPosition: SnackPosition.TOP,
|
|
||||||
titleText: Text(
|
|
||||||
'Error'.tr,
|
|
||||||
style: const TextStyle(
|
|
||||||
color: AppColor.redColor),
|
|
||||||
),
|
|
||||||
messageText: Text(
|
|
||||||
'We Are Sorry That we dont have cars in your Location!'
|
|
||||||
.tr,
|
|
||||||
style: AppStyle.title,
|
|
||||||
),
|
|
||||||
icon: const Icon(Icons.error),
|
|
||||||
shouldIconPulse: true,
|
|
||||||
maxWidth: double.infinity,
|
|
||||||
margin: const EdgeInsets.all(16),
|
|
||||||
padding: const EdgeInsets.all(16),
|
|
||||||
borderRadius: 8,
|
|
||||||
borderColor: AppColor.redColor,
|
|
||||||
borderWidth: 2,
|
|
||||||
backgroundColor: AppColor.secondaryColor,
|
|
||||||
leftBarIndicatorColor: AppColor.redColor,
|
|
||||||
boxShadows: [
|
|
||||||
BoxShadow(
|
|
||||||
color: Colors.black.withOpacity(0.25),
|
|
||||||
blurRadius: 4,
|
|
||||||
spreadRadius: 2,
|
|
||||||
offset: const Offset(0, 4),
|
|
||||||
),
|
|
||||||
],
|
|
||||||
backgroundGradient: const LinearGradient(
|
|
||||||
colors: [
|
|
||||||
AppColor.redColor,
|
|
||||||
AppColor.accentColor
|
|
||||||
],
|
|
||||||
begin: Alignment.topLeft,
|
|
||||||
end: Alignment.bottomRight,
|
|
||||||
),
|
|
||||||
// mainButton: TextButton(
|
|
||||||
// onPressed: () {
|
|
||||||
// controller.getCarsLocationByPassenger();
|
|
||||||
// },
|
|
||||||
// child: Text(
|
|
||||||
// 'Try Again'.tr,
|
|
||||||
// style: const TextStyle(
|
|
||||||
// color: AppColor.secondaryColor),
|
|
||||||
// ),
|
|
||||||
// ),
|
|
||||||
onTap: (GetSnackBar snackBar) {
|
|
||||||
// Do something when the snackbar is tapped.
|
|
||||||
},
|
|
||||||
isDismissible: true,
|
|
||||||
showProgressIndicator: false,
|
|
||||||
dismissDirection: DismissDirection.up,
|
|
||||||
progressIndicatorController: null,
|
|
||||||
progressIndicatorBackgroundColor:
|
|
||||||
Colors.transparent,
|
|
||||||
progressIndicatorValueColor: null,
|
|
||||||
snackStyle: SnackStyle.GROUNDED,
|
|
||||||
forwardAnimationCurve:
|
|
||||||
Curves.easeInToLinear,
|
|
||||||
reverseAnimationCurve: Curves.easeInOut,
|
|
||||||
animationDuration:
|
|
||||||
const Duration(milliseconds: 4000),
|
|
||||||
barBlur: 8,
|
|
||||||
overlayBlur: 0,
|
|
||||||
snackbarStatus: null,
|
|
||||||
overlayColor:
|
|
||||||
AppColor.primaryColor.withOpacity(0.5),
|
|
||||||
userInputForm: null,
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
//
|
|
||||||
}),
|
|
||||||
);
|
|
||||||
},
|
|
||||||
|
|
||||||
onTap: (argument) {
|
|
||||||
controller.hidePlaces();
|
|
||||||
|
|
||||||
// controller.changeBottomSheetShown();
|
|
||||||
// controller.bottomSheet();
|
|
||||||
},
|
|
||||||
initialCameraPosition: CameraPosition(
|
|
||||||
target: controller.myLocation,
|
|
||||||
zoom: 15,
|
|
||||||
),
|
|
||||||
markers: {
|
|
||||||
for (var carLocation
|
|
||||||
in controller.carsLocationByPassenger)
|
|
||||||
Marker(
|
|
||||||
// anchor: const Offset(4, 4),
|
|
||||||
position: carLocation,
|
|
||||||
icon: controller.carIcon,
|
|
||||||
markerId: MarkerId(carLocation.toString())),
|
|
||||||
for (var carLocation in controller
|
|
||||||
.driverCarsLocationToPassengerAfterApplied)
|
|
||||||
Marker(
|
|
||||||
// anchor: const Offset(4, 4),
|
|
||||||
position: carLocation,
|
|
||||||
icon: controller.carIcon,
|
|
||||||
markerId: MarkerId(carLocation.toString())),
|
|
||||||
Marker(
|
|
||||||
markerId: MarkerId('MyLocation'.tr),
|
|
||||||
position: controller.myLocation,
|
|
||||||
draggable: true,
|
|
||||||
icon: controller.markerIcon,
|
|
||||||
infoWindow: const InfoWindow(
|
|
||||||
title: 'Time',
|
|
||||||
// snippet: controller.durationFromDriverToPassenger
|
|
||||||
// .toString(),
|
|
||||||
),
|
|
||||||
onDragEnd: (value) {
|
|
||||||
print(value);
|
|
||||||
},
|
|
||||||
// infoWindow: InfoWindow(title: 'my location'.tr),
|
|
||||||
),
|
|
||||||
// Marker(
|
|
||||||
// markerId: MarkerId('Target'.tr),
|
|
||||||
// position: controller.myDestination,
|
|
||||||
// draggable: true,
|
|
||||||
// onDragEnd: (v) {
|
|
||||||
// print(v);
|
|
||||||
// },
|
|
||||||
// ),
|
|
||||||
},
|
|
||||||
polylines: {
|
|
||||||
Polyline(
|
|
||||||
zIndex: 2,
|
|
||||||
consumeTapEvents: true,
|
|
||||||
geodesic: true,
|
|
||||||
endCap: Cap.buttCap,
|
|
||||||
startCap: Cap.buttCap,
|
|
||||||
visible: true,
|
|
||||||
polylineId: const PolylineId('route'),
|
|
||||||
points: controller.polylineCoordinates,
|
|
||||||
color: AppColor.primaryColor,
|
|
||||||
width: 5,
|
|
||||||
),
|
|
||||||
// Polyline(
|
|
||||||
// zIndex: 2,
|
|
||||||
// consumeTapEvents: true,
|
|
||||||
// geodesic: true,
|
|
||||||
// endCap: Cap.buttCap,
|
|
||||||
// startCap: Cap.buttCap,
|
|
||||||
// visible: true,
|
|
||||||
// polylineId: PolylineId('g'),
|
|
||||||
// points: [
|
|
||||||
// LatLng(controller.southwest.latitude,
|
|
||||||
// controller.southwest.longitude),
|
|
||||||
// LatLng(controller.northeast.latitude,
|
|
||||||
// controller.northeast.longitude)
|
|
||||||
// ],
|
|
||||||
// color: AppColor.primaryColor,
|
|
||||||
// width: 5,
|
|
||||||
// ),
|
|
||||||
},
|
|
||||||
// circles: {
|
|
||||||
// Circle(
|
|
||||||
// circleId: const CircleId('kk'),
|
|
||||||
// center: controller.mylocation,
|
|
||||||
// radius: 60,
|
|
||||||
// fillColor: AppColor.primaryColor,)
|
|
||||||
// },
|
|
||||||
|
|
||||||
circles: <Circle>{
|
|
||||||
Circle(
|
|
||||||
circleId: const CircleId('circle_id'),
|
|
||||||
center: controller.myLocation,
|
|
||||||
radius: 100,
|
|
||||||
fillColor: Colors.blue.withOpacity(0.3),
|
|
||||||
strokeColor: Colors.blue,
|
|
||||||
strokeWidth: 2,
|
|
||||||
),
|
|
||||||
},
|
|
||||||
|
|
||||||
mapType: controller.mapType
|
|
||||||
? MapType.satellite
|
|
||||||
: MapType.normal,
|
|
||||||
myLocationButtonEnabled: true,
|
|
||||||
// liteModeEnabled: true, tiltGesturesEnabled: false,
|
|
||||||
|
|
||||||
// indoorViewEnabled: true,
|
|
||||||
trafficEnabled: controller.mapTrafficON,
|
|
||||||
buildingsEnabled: true,
|
|
||||||
mapToolbarEnabled: true,
|
|
||||||
onCameraMove: (position) {
|
|
||||||
controller.newMyLocation = position.target;
|
|
||||||
// print('my' + controller.mylocation.toString());
|
|
||||||
// print('new' + controller.newMylocation.toString());
|
|
||||||
},
|
|
||||||
myLocationEnabled: true,
|
|
||||||
// liteModeEnabled: true,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
leftMainMenuIcons(),
|
leftMainMenuIcons(),
|
||||||
const PickerIconOnMap(),
|
const PickerIconOnMap(),
|
||||||
// PickerAnimtionContainerFormPlaces(),
|
// PickerAnimtionContainerFormPlaces(),
|
||||||
@@ -274,7 +38,6 @@ class MapPagePassenger extends StatelessWidget {
|
|||||||
const MenuIconMapPageWidget(),
|
const MenuIconMapPageWidget(),
|
||||||
buttomSheetMapPage(),
|
buttomSheetMapPage(),
|
||||||
hexagonClipper(),
|
hexagonClipper(),
|
||||||
|
|
||||||
const CancelRidePageShow(),
|
const CancelRidePageShow(),
|
||||||
const CashConfirmPageShown(),
|
const CashConfirmPageShown(),
|
||||||
const PaymentMethodPage(),
|
const PaymentMethodPage(),
|
||||||
|
|||||||
242
lib/views/home/map_widget.dart/google_map_passenger_widget.dart
Normal file
242
lib/views/home/map_widget.dart/google_map_passenger_widget.dart
Normal file
@@ -0,0 +1,242 @@
|
|||||||
|
import 'package:flutter/material.dart';
|
||||||
|
import 'package:get/get.dart';
|
||||||
|
import 'package:google_maps_flutter/google_maps_flutter.dart';
|
||||||
|
|
||||||
|
import '../../../constant/colors.dart';
|
||||||
|
import '../../../constant/style.dart';
|
||||||
|
import '../../../controller/home/map_passenger_controller.dart';
|
||||||
|
import '../../widgets/elevated_btn.dart';
|
||||||
|
import '../../widgets/mycircular.dart';
|
||||||
|
|
||||||
|
class GoogleMapPassengerWidget extends StatelessWidget {
|
||||||
|
const GoogleMapPassengerWidget({
|
||||||
|
super.key,
|
||||||
|
});
|
||||||
|
|
||||||
|
@override
|
||||||
|
Widget build(BuildContext context) {
|
||||||
|
return GetBuilder<MapPassengerController>(
|
||||||
|
builder: (controller) => controller.isLoading
|
||||||
|
? const MyCircularProgressIndicator()
|
||||||
|
: GoogleMap(
|
||||||
|
onMapCreated: controller.onMapCreated,
|
||||||
|
cameraTargetBounds: CameraTargetBounds(controller.boundsdata),
|
||||||
|
minMaxZoomPreference: const MinMaxZoomPreference(6, 18),
|
||||||
|
onLongPress: (argument) {
|
||||||
|
Get.defaultDialog(
|
||||||
|
title: 'Are you want to go to this site'.tr,
|
||||||
|
content: Column(
|
||||||
|
children: [
|
||||||
|
Text('${argument.latitude},${argument.longitude}'),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
confirm: MyElevatedButton(
|
||||||
|
title: 'Ok'.tr,
|
||||||
|
onPressed: () async {
|
||||||
|
controller.clearPolyline();
|
||||||
|
if (controller.dataCarsLocationByPassenger != null) {
|
||||||
|
await controller.getMap(
|
||||||
|
'${controller.myLocation.latitude},${controller.myLocation.longitude}',
|
||||||
|
'${argument.latitude.toString()},${argument.longitude.toString()}');
|
||||||
|
|
||||||
|
Get.back();
|
||||||
|
controller.bottomSheet();
|
||||||
|
controller.showBottomSheet1();
|
||||||
|
} else {
|
||||||
|
Get.back();
|
||||||
|
Get.snackbar(
|
||||||
|
'We Are Sorry That we dont have cars in your Location!'
|
||||||
|
.tr,
|
||||||
|
'message',
|
||||||
|
colorText: AppColor.redColor,
|
||||||
|
duration: const Duration(seconds: 11),
|
||||||
|
instantInit: true,
|
||||||
|
snackPosition: SnackPosition.TOP,
|
||||||
|
titleText: Text(
|
||||||
|
'Error'.tr,
|
||||||
|
style: const TextStyle(color: AppColor.redColor),
|
||||||
|
),
|
||||||
|
messageText: Text(
|
||||||
|
'We Are Sorry That we dont have cars in your Location!'
|
||||||
|
.tr,
|
||||||
|
style: AppStyle.title,
|
||||||
|
),
|
||||||
|
icon: const Icon(Icons.error),
|
||||||
|
shouldIconPulse: true,
|
||||||
|
maxWidth: double.infinity,
|
||||||
|
margin: const EdgeInsets.all(16),
|
||||||
|
padding: const EdgeInsets.all(16),
|
||||||
|
borderRadius: 8,
|
||||||
|
borderColor: AppColor.redColor,
|
||||||
|
borderWidth: 2,
|
||||||
|
backgroundColor: AppColor.secondaryColor,
|
||||||
|
leftBarIndicatorColor: AppColor.redColor,
|
||||||
|
boxShadows: [
|
||||||
|
BoxShadow(
|
||||||
|
color: Colors.black.withOpacity(0.25),
|
||||||
|
blurRadius: 4,
|
||||||
|
spreadRadius: 2,
|
||||||
|
offset: const Offset(0, 4),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
backgroundGradient: const LinearGradient(
|
||||||
|
colors: [AppColor.redColor, AppColor.accentColor],
|
||||||
|
begin: Alignment.topLeft,
|
||||||
|
end: Alignment.bottomRight,
|
||||||
|
),
|
||||||
|
// mainButton: TextButton(
|
||||||
|
// onPressed: () {
|
||||||
|
// controller.getCarsLocationByPassenger();
|
||||||
|
// },
|
||||||
|
// child: Text(
|
||||||
|
// 'Try Again'.tr,
|
||||||
|
// style: const TextStyle(
|
||||||
|
// color: AppColor.secondaryColor),
|
||||||
|
// ),
|
||||||
|
// ),
|
||||||
|
onTap: (GetSnackBar snackBar) {
|
||||||
|
// Do something when the snackbar is tapped.
|
||||||
|
},
|
||||||
|
isDismissible: true,
|
||||||
|
showProgressIndicator: false,
|
||||||
|
dismissDirection: DismissDirection.up,
|
||||||
|
progressIndicatorController: null,
|
||||||
|
progressIndicatorBackgroundColor:
|
||||||
|
Colors.transparent,
|
||||||
|
progressIndicatorValueColor: null,
|
||||||
|
snackStyle: SnackStyle.GROUNDED,
|
||||||
|
forwardAnimationCurve: Curves.easeInToLinear,
|
||||||
|
reverseAnimationCurve: Curves.easeInOut,
|
||||||
|
animationDuration:
|
||||||
|
const Duration(milliseconds: 4000),
|
||||||
|
barBlur: 8,
|
||||||
|
overlayBlur: 0,
|
||||||
|
snackbarStatus: null,
|
||||||
|
overlayColor:
|
||||||
|
AppColor.primaryColor.withOpacity(0.5),
|
||||||
|
userInputForm: null,
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
//
|
||||||
|
}),
|
||||||
|
);
|
||||||
|
},
|
||||||
|
|
||||||
|
onTap: (argument) {
|
||||||
|
controller.hidePlaces();
|
||||||
|
|
||||||
|
// controller.changeBottomSheetShown();
|
||||||
|
// controller.bottomSheet();
|
||||||
|
},
|
||||||
|
initialCameraPosition: CameraPosition(
|
||||||
|
target: controller.myLocation,
|
||||||
|
zoom: 15,
|
||||||
|
),
|
||||||
|
markers: {
|
||||||
|
for (var carLocation in controller.carsLocationByPassenger)
|
||||||
|
Marker(
|
||||||
|
// anchor: const Offset(4, 4),
|
||||||
|
position: carLocation,
|
||||||
|
icon: controller.carIcon,
|
||||||
|
markerId: MarkerId(carLocation.toString())),
|
||||||
|
for (var carLocation
|
||||||
|
in controller.driverCarsLocationToPassengerAfterApplied)
|
||||||
|
Marker(
|
||||||
|
// anchor: const Offset(4, 4),
|
||||||
|
position: carLocation,
|
||||||
|
icon: controller.carIcon,
|
||||||
|
markerId: MarkerId(carLocation.toString())),
|
||||||
|
Marker(
|
||||||
|
markerId: MarkerId('MyLocation'.tr),
|
||||||
|
position: controller.myLocation,
|
||||||
|
draggable: true,
|
||||||
|
icon: controller.markerIcon,
|
||||||
|
infoWindow: const InfoWindow(
|
||||||
|
title: 'Time',
|
||||||
|
// snippet: controller.durationFromDriverToPassenger
|
||||||
|
// .toString(),
|
||||||
|
),
|
||||||
|
onDragEnd: (value) {
|
||||||
|
print(value);
|
||||||
|
},
|
||||||
|
// infoWindow: InfoWindow(title: 'my location'.tr),
|
||||||
|
),
|
||||||
|
// Marker(
|
||||||
|
// markerId: MarkerId('Target'.tr),
|
||||||
|
// position: controller.myDestination,
|
||||||
|
// draggable: true,
|
||||||
|
// onDragEnd: (v) {
|
||||||
|
// print(v);
|
||||||
|
// },
|
||||||
|
// ),
|
||||||
|
},
|
||||||
|
polylines: {
|
||||||
|
Polyline(
|
||||||
|
zIndex: 2,
|
||||||
|
consumeTapEvents: true,
|
||||||
|
geodesic: true,
|
||||||
|
endCap: Cap.buttCap,
|
||||||
|
startCap: Cap.buttCap,
|
||||||
|
visible: true,
|
||||||
|
polylineId: const PolylineId('route'),
|
||||||
|
points: controller.polylineCoordinates,
|
||||||
|
color: AppColor.primaryColor,
|
||||||
|
width: 5,
|
||||||
|
),
|
||||||
|
// Polyline(
|
||||||
|
// zIndex: 2,
|
||||||
|
// consumeTapEvents: true,
|
||||||
|
// geodesic: true,
|
||||||
|
// endCap: Cap.buttCap,
|
||||||
|
// startCap: Cap.buttCap,
|
||||||
|
// visible: true,
|
||||||
|
// polylineId: PolylineId('g'),
|
||||||
|
// points: [
|
||||||
|
// LatLng(controller.southwest.latitude,
|
||||||
|
// controller.southwest.longitude),
|
||||||
|
// LatLng(controller.northeast.latitude,
|
||||||
|
// controller.northeast.longitude)
|
||||||
|
// ],
|
||||||
|
// color: AppColor.primaryColor,
|
||||||
|
// width: 5,
|
||||||
|
// ),
|
||||||
|
},
|
||||||
|
// circles: {
|
||||||
|
// Circle(
|
||||||
|
// circleId: const CircleId('kk'),
|
||||||
|
// center: controller.mylocation,
|
||||||
|
// radius: 60,
|
||||||
|
// fillColor: AppColor.primaryColor,)
|
||||||
|
// },
|
||||||
|
|
||||||
|
circles: <Circle>{
|
||||||
|
Circle(
|
||||||
|
circleId: const CircleId('circle_id'),
|
||||||
|
center: controller.myLocation,
|
||||||
|
radius: 100,
|
||||||
|
fillColor: Colors.blue.withOpacity(0.3),
|
||||||
|
strokeColor: Colors.blue,
|
||||||
|
strokeWidth: 2,
|
||||||
|
),
|
||||||
|
},
|
||||||
|
|
||||||
|
mapType: controller.mapType ? MapType.satellite : MapType.normal,
|
||||||
|
myLocationButtonEnabled: true,
|
||||||
|
// liteModeEnabled: true, tiltGesturesEnabled: false,
|
||||||
|
|
||||||
|
// indoorViewEnabled: true,
|
||||||
|
trafficEnabled: controller.mapTrafficON,
|
||||||
|
buildingsEnabled: true,
|
||||||
|
mapToolbarEnabled: true,
|
||||||
|
onCameraMove: (position) {
|
||||||
|
controller.newMyLocation = position.target;
|
||||||
|
// print('my' + controller.mylocation.toString());
|
||||||
|
// print('new' + controller.newMylocation.toString());
|
||||||
|
},
|
||||||
|
myLocationEnabled: true,
|
||||||
|
// liteModeEnabled: true,
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -243,7 +243,7 @@ class OrderRequestPage extends StatelessWidget {
|
|||||||
FirebaseMessagesController()
|
FirebaseMessagesController()
|
||||||
.sendNotificationToPassengerToken(
|
.sendNotificationToPassengerToken(
|
||||||
'Refused Ride',
|
'Refused Ride',
|
||||||
arguments['DriverList'][9].toString(),
|
'${box.read(BoxName.nameDriver)} rejct your order.',
|
||||||
arguments['DriverList'][9].toString(),
|
arguments['DriverList'][9].toString(),
|
||||||
// box.read(BoxName.tokenDriver).toString(),
|
// box.read(BoxName.tokenDriver).toString(),
|
||||||
bodyToPassenger,
|
bodyToPassenger,
|
||||||
|
|||||||
Reference in New Issue
Block a user