12/31/2
This commit is contained in:
@@ -47,70 +47,85 @@ GetBuilder<MapPassengerController> buttomSheetMapPage() {
|
||||
],
|
||||
borderRadius: const BorderRadius.all(
|
||||
Radius.circular(15))),
|
||||
child: Row(
|
||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||
children: [
|
||||
SizedBox(
|
||||
width: Get.width * .15,
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.all(8.0),
|
||||
child: Image.asset(
|
||||
'assets/images/jeep.png',
|
||||
width: 50,
|
||||
fit: BoxFit.fill,
|
||||
repeat: ImageRepeat.repeatX,
|
||||
),
|
||||
),
|
||||
),
|
||||
SizedBox(
|
||||
width: Get.width * .55,
|
||||
child: Column(
|
||||
crossAxisAlignment:
|
||||
CrossAxisAlignment.start,
|
||||
mainAxisAlignment:
|
||||
MainAxisAlignment.spaceEvenly,
|
||||
children: [
|
||||
Text(
|
||||
'${'Your Ride Duration is '.tr}${controller.duration} minutes',
|
||||
style: AppStyle.subtitle,
|
||||
),
|
||||
Text(
|
||||
'${'You will be thier in'.tr} ${DateFormat('h:mm a').format(controller.newTime)}',
|
||||
style: AppStyle.subtitle,
|
||||
),
|
||||
Text(
|
||||
'${'You trip distance is'.tr} ${controller.distance} KM',
|
||||
style: AppStyle.subtitle,
|
||||
)
|
||||
],
|
||||
),
|
||||
),
|
||||
SizedBox(
|
||||
width: Get.width * .2,
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.only(
|
||||
right: 5, left: 5),
|
||||
child: Column(
|
||||
crossAxisAlignment:
|
||||
CrossAxisAlignment.center,
|
||||
children: [
|
||||
Text(
|
||||
'${'Fee is'.tr} \n${controller.totalPassenger.toStringAsFixed(2)}',
|
||||
style: AppStyle.subtitle,
|
||||
child: ListView.builder(
|
||||
itemCount:
|
||||
controller.dataCarsLocationByPassenger.length,
|
||||
itemBuilder: (BuildContext context, int index) {
|
||||
return Row(
|
||||
mainAxisAlignment:
|
||||
MainAxisAlignment.spaceBetween,
|
||||
children: [
|
||||
SizedBox(
|
||||
width: Get.width * .15,
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.all(8.0),
|
||||
child: Column(
|
||||
children: [
|
||||
Text(controller
|
||||
.dataCarsLocationByPassenger
|
||||
.toString()),
|
||||
Image.asset(
|
||||
'assets/images/jeep.png',
|
||||
width: 50,
|
||||
fit: BoxFit.fill,
|
||||
repeat: ImageRepeat.repeatX,
|
||||
),
|
||||
],
|
||||
),
|
||||
controller.promoTaken
|
||||
? const Icon(
|
||||
Icons.filter_vintage_rounded,
|
||||
color: AppColor.redColor,
|
||||
)
|
||||
: const SizedBox(
|
||||
height: 0,
|
||||
)
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
SizedBox(
|
||||
width: Get.width * .55,
|
||||
child: Column(
|
||||
crossAxisAlignment:
|
||||
CrossAxisAlignment.start,
|
||||
mainAxisAlignment:
|
||||
MainAxisAlignment.spaceEvenly,
|
||||
children: [
|
||||
Text(
|
||||
'${'Your Ride Duration is '.tr}${controller.duration} minutes',
|
||||
style: AppStyle.subtitle,
|
||||
),
|
||||
Text(
|
||||
'${'You will be thier in'.tr} ${DateFormat('h:mm a').format(controller.newTime)}',
|
||||
style: AppStyle.subtitle,
|
||||
),
|
||||
Text(
|
||||
'${'You trip distance is'.tr} ${controller.distance} KM',
|
||||
style: AppStyle.subtitle,
|
||||
)
|
||||
],
|
||||
),
|
||||
),
|
||||
SizedBox(
|
||||
width: Get.width * .2,
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.only(
|
||||
right: 5, left: 5),
|
||||
child: Column(
|
||||
crossAxisAlignment:
|
||||
CrossAxisAlignment.center,
|
||||
children: [
|
||||
Text(
|
||||
'${'Fee is'.tr} \n${controller.totalPassenger.toStringAsFixed(2)}',
|
||||
style: AppStyle.subtitle,
|
||||
),
|
||||
controller.promoTaken
|
||||
? const Icon(
|
||||
Icons
|
||||
.filter_vintage_rounded,
|
||||
color: AppColor.redColor,
|
||||
)
|
||||
: const SizedBox(
|
||||
height: 0,
|
||||
)
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
);
|
||||
},
|
||||
),
|
||||
),
|
||||
const SizedBox(
|
||||
|
||||
@@ -151,7 +151,7 @@ class GoogleMapPassengerWidget extends StatelessWidget {
|
||||
markerId: MarkerId('MyLocation'.tr),
|
||||
position: controller.newStartPointLocation,
|
||||
draggable: true,
|
||||
icon: controller.tripIcon,
|
||||
icon: controller.markerIcon,
|
||||
infoWindow: const InfoWindow(
|
||||
title: 'Time',
|
||||
// snippet: controller.durationFromDriverToPassenger
|
||||
@@ -166,7 +166,7 @@ class GoogleMapPassengerWidget extends StatelessWidget {
|
||||
markerId: MarkerId('Destination'.tr),
|
||||
position: controller.newMyLocation,
|
||||
draggable: true,
|
||||
icon: controller.tripIcon,
|
||||
icon: controller.markerIcon,
|
||||
infoWindow: const InfoWindow(
|
||||
title: 'Time',
|
||||
// snippet: controller.durationFromDriverToPassenger
|
||||
|
||||
@@ -82,15 +82,15 @@ class MainBottomMenuMap extends StatelessWidget {
|
||||
controller.startLocationFromMap =
|
||||
false;
|
||||
controller.isPickerShown = false;
|
||||
print(controller.myLocation);
|
||||
print(controller
|
||||
.newStartPointLocation);
|
||||
// print(controller.myLocation);
|
||||
// print(controller
|
||||
// .newStartPointLocation);
|
||||
} else {
|
||||
controller.newMyLocation =
|
||||
controller.newMyLocation;
|
||||
controller.isPickerShown = false;
|
||||
print(controller.myLocation);
|
||||
print(controller.newMyLocation);
|
||||
// print(controller.myLocation);
|
||||
// print(controller.newMyLocation);
|
||||
}
|
||||
|
||||
// await controller.getMap(
|
||||
|
||||
@@ -203,39 +203,43 @@ class IconMainPageMap extends StatelessWidget {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return GestureDetector(
|
||||
onTap: onTap,
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.all(4),
|
||||
child: Container(
|
||||
width: double.maxFinite,
|
||||
decoration: const BoxDecoration(
|
||||
borderRadius: BorderRadius.all(Radius.circular(16)),
|
||||
color: AppColor.secondaryColor,
|
||||
boxShadow: [
|
||||
BoxShadow(
|
||||
color: AppColor.accentColor,
|
||||
offset: Offset(3, 3),
|
||||
blurRadius: 0,
|
||||
spreadRadius: 0,
|
||||
blurStyle: BlurStyle.outer,
|
||||
),
|
||||
],
|
||||
),
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.all(8.0),
|
||||
child: Column(
|
||||
children: [
|
||||
Icon(icon),
|
||||
Text(
|
||||
title.tr,
|
||||
style: AppStyle.subtitle,
|
||||
return FutureBuilder(
|
||||
future: Future.delayed(const Duration(milliseconds: 400)),
|
||||
builder: (context, snapshot) {
|
||||
return GestureDetector(
|
||||
onTap: onTap,
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.all(4),
|
||||
child: Container(
|
||||
width: double.maxFinite,
|
||||
decoration: const BoxDecoration(
|
||||
borderRadius: BorderRadius.all(Radius.circular(16)),
|
||||
color: AppColor.secondaryColor,
|
||||
boxShadow: [
|
||||
BoxShadow(
|
||||
color: AppColor.accentColor,
|
||||
offset: Offset(3, 3),
|
||||
blurRadius: 0,
|
||||
spreadRadius: 0,
|
||||
blurStyle: BlurStyle.outer,
|
||||
),
|
||||
],
|
||||
),
|
||||
],
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.all(8.0),
|
||||
child: Column(
|
||||
children: [
|
||||
Icon(icon),
|
||||
Text(
|
||||
title.tr,
|
||||
style: AppStyle.subtitle,
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user