6/8/1
This commit is contained in:
@@ -63,13 +63,39 @@ class OrderHistory extends StatelessWidget {
|
||||
width: Get.width * .75,
|
||||
child: GoogleMap(
|
||||
initialCameraPosition: CameraPosition(
|
||||
target: Get.find<
|
||||
MapPassengerController>()
|
||||
.passengerLocation, // Assuming passenger location is available
|
||||
zoom: 15,
|
||||
target: LatLng(
|
||||
(double.parse(
|
||||
rides['start_location']
|
||||
.toString()
|
||||
.split(',')[0]) +
|
||||
double.parse(
|
||||
rides['end_location']
|
||||
.toString()
|
||||
.split(',')[0])) /
|
||||
2,
|
||||
(double.parse(
|
||||
rides['start_location']
|
||||
.toString()
|
||||
.split(',')[1]) +
|
||||
double.parse(
|
||||
rides['end_location']
|
||||
.toString()
|
||||
.split(',')[1])) /
|
||||
2,
|
||||
),
|
||||
zoom: 12,
|
||||
),
|
||||
// bounds: LatLngBounds(
|
||||
// northeast: LatLng(
|
||||
// double.parse(rides['end_location'].toString().split(',')[0]),
|
||||
// double.parse(rides['end_location'].toString().split(',')[1]),
|
||||
// ),
|
||||
// southwest: LatLng(
|
||||
// double.parse(rides['start_location'].toString().split(',')[0]),
|
||||
// double.parse(rides['start_location'].toString().split(',')[1]),
|
||||
// ),
|
||||
// ),
|
||||
zoomControlsEnabled: true,
|
||||
// liteModeEnabled: false,
|
||||
polylines: {
|
||||
Polyline(
|
||||
zIndex: 2,
|
||||
@@ -106,6 +132,7 @@ class OrderHistory extends StatelessWidget {
|
||||
width: 5,
|
||||
),
|
||||
},
|
||||
mapType: MapType.normal,
|
||||
),
|
||||
),
|
||||
Row(
|
||||
@@ -122,12 +149,17 @@ class OrderHistory extends StatelessWidget {
|
||||
),
|
||||
Text(
|
||||
rides['status'],
|
||||
style: rides['status'] !=
|
||||
style: rides['status'] ==
|
||||
'Canceled'.tr
|
||||
? AppStyle.subtitle.copyWith(
|
||||
color: AppColor.greenColor)
|
||||
: AppStyle.subtitle.copyWith(
|
||||
color: AppColor.redColor),
|
||||
color: AppColor.redColor)
|
||||
: rides['status'] == 'Finished'.tr
|
||||
? AppStyle.subtitle.copyWith(
|
||||
color:
|
||||
AppColor.greenColor)
|
||||
: AppStyle.subtitle.copyWith(
|
||||
color:
|
||||
AppColor.yellowColor),
|
||||
),
|
||||
Text(
|
||||
'${'Price is'.tr} ${rides['price']}',
|
||||
|
||||
Reference in New Issue
Block a user