From b3cf2d4fe22a1bb3bbda54eb55c1252b852a6a79 Mon Sep 17 00:00:00 2001 From: Hamza Aleghwairyeen Date: Thu, 11 Apr 2024 15:14:55 +0300 Subject: [PATCH] 4/11/2 --- .../home/captin/map_driver_controller.dart | 6 ++--- .../home/map_passenger_controller.dart | 22 +++++++++---------- lib/controller/local/translations.dart | 4 +--- .../passenger_info_window.dart | 2 +- .../map_widget.dart/apply_order_widget.dart | 8 +++---- .../map_widget.dart/ride_begin_passenger.dart | 11 ++++++---- 6 files changed, 27 insertions(+), 26 deletions(-) diff --git a/lib/controller/home/captin/map_driver_controller.dart b/lib/controller/home/captin/map_driver_controller.dart index d968040..bad4e1a 100644 --- a/lib/controller/home/captin/map_driver_controller.dart +++ b/lib/controller/home/captin/map_driver_controller.dart @@ -76,7 +76,7 @@ class MapDriverController extends GetxController { bool isRideFinished = false; bool isRideStarted = false; bool isPriceWindow = false; - double passengerInfoWindow = Get.height * .39; + double passengerInfoWindowHeight = Get.height * .4; double driverEndPage = 100; double progress = 0; double progressToPassenger = 0; @@ -161,7 +161,7 @@ class MapDriverController extends GetxController { void changeRideToBeginToPassenger() { isRideBegin = true; - passengerInfoWindow = Get.height * .22; + passengerInfoWindowHeight = Get.height * .22; update(); } @@ -807,7 +807,7 @@ class MapDriverController extends GetxController { void changePassengerInfoWindow() { isPassengerInfoWindow = !isPassengerInfoWindow; - passengerInfoWindow = isPassengerInfoWindow == true ? 200 : 0; + passengerInfoWindowHeight = isPassengerInfoWindow == true ? 200 : 0; update(); } diff --git a/lib/controller/home/map_passenger_controller.dart b/lib/controller/home/map_passenger_controller.dart index 941ed93..0582db2 100644 --- a/lib/controller/home/map_passenger_controller.dart +++ b/lib/controller/home/map_passenger_controller.dart @@ -142,8 +142,8 @@ class MapPassengerController extends GetxController { bool isWayPointStopsSheetUtilGetMap = false; double heightBottomSheetShown = 0; double cashConfirmPageShown = 250; - late String driverId; - late String gender; + late String driverId = ''; + late String gender = ''; double widthMapTypeAndTraffic = 50; double paymentPageShown = Get.height * .6; late LatLng southwest; @@ -686,7 +686,7 @@ class MapPassengerController extends GetxController { remainingTimeToPassengerFromDriverAfterApplied = 0; remainingTimeDriverWaitPassenger5Minute = 0; rideTimerBegin = true; - statusRide == 'Begin'; + statusRide = 'Begin'; isDriverInPassengerWay = false; isDriverArrivePassenger = false; update(); @@ -834,14 +834,14 @@ class MapPassengerController extends GetxController { } int currentTimeSearchingCaptainWindow = 0; - late String driverPhone; - late String driverRate; - late String firstName; - late String carColor; - late String carYear; - late String model; - late String make; - late String licensePlate; + late String driverPhone = ''; + late String driverRate = ''; + late String firstName = ''; + late String carColor = ''; + late String carYear = ''; + late String model = ''; + late String make = ''; + late String licensePlate = ''; confirmRideForFirstDriver() async { await getCarsLocationByPassengerAndReloadMarker(); await getNearestDriverByPassengerLocationAPIGOOGLE(); diff --git a/lib/controller/local/translations.dart b/lib/controller/local/translations.dart index 177ba97..f6a48a5 100644 --- a/lib/controller/local/translations.dart +++ b/lib/controller/local/translations.dart @@ -90,7 +90,7 @@ class MyTranslation extends Translations { "By selecting \"I Agree\" below, I have reviewed and agree to the Terms of Use and acknowledge the Privacy Notice. I am at least 18 years of age.": "بتحديد \"أوافق\" أدناه ، فإنني أوافق على مراجعة وقبول شروط الاستخدام وإقرار إشعار الخصوصية. أنا على الأقل 18 عامًا من العمر.", "Update": "تحديث", - "You Should choose rate figure": "يجب عليك اختيار رقم السعر", + "You Should choose rate figure": "يجب عليك اختيار تقييم", "Login Captin": "تسجيل دخول الكابتن", "Register Captin": "تسجيل كابتن جديد", "Send Verfication Code": "أرسل رمز التحقق", @@ -442,7 +442,6 @@ class MyTranslation extends Translations { 'Total points is ': "إجمالي النقاط هو", 'Total Connection Duration:': "إجمالي مدة الإتصال:", ' H and': "ساعة و", - 'm': "دقيقة", 'Hello this is Driver': "مرحبا هذا السائق", 'Is the Passenger in your Car ?': "هل الراكب في سيارتك؟", 'don\'t start trip if not ': "لا تبدأ الرحلة إذا لم يكن", @@ -633,7 +632,6 @@ class MyTranslation extends Translations { 'Tariffs': "التعرفه", 'Minimum fare': "الحد الأدنى للأجرة", 'Maximum fare': "الحد الأقصى للأجرة", - 'JOD': "د.أ", 'Flag-down fee': "رسوم التشغيل", 'Including Tax': "بما في ذلك الضرائب", 'BookingFee': "رسوم الطلب", diff --git a/lib/views/home/Captin/mapDriverWidgets/passenger_info_window.dart b/lib/views/home/Captin/mapDriverWidgets/passenger_info_window.dart index d4a1397..25e3f40 100644 --- a/lib/views/home/Captin/mapDriverWidgets/passenger_info_window.dart +++ b/lib/views/home/Captin/mapDriverWidgets/passenger_info_window.dart @@ -31,7 +31,7 @@ class PassengerInfoWindow extends StatelessWidget { // left: 8, child: AnimatedContainer( duration: const Duration(milliseconds: 300), - height: controller.passengerInfoWindow, + height: controller.passengerInfoWindowHeight, width: Get.width * .99, decoration: AppStyle.boxDecoration, child: Padding( diff --git a/lib/views/home/map_widget.dart/apply_order_widget.dart b/lib/views/home/map_widget.dart/apply_order_widget.dart index f93f64c..bcc285b 100644 --- a/lib/views/home/map_widget.dart/apply_order_widget.dart +++ b/lib/views/home/map_widget.dart/apply_order_widget.dart @@ -26,7 +26,7 @@ class ApplyOrderWidget extends StatelessWidget { right: 0, child: Container( decoration: AppStyle.boxDecoration1, - height: Get.height * .3, + height: Get.height * .35, child: ListView( children: [ InkWell( @@ -84,7 +84,7 @@ class ApplyOrderWidget extends StatelessWidget { width: 10, ), Container( - height: 200, + height: Get.height * .3, width: Get.width * .9, decoration: AppStyle.boxDecoration1, child: Column( @@ -299,7 +299,7 @@ class DriverArrivePassengerAndWaitMinute extends StatelessWidget { color: controller.remainingTimeDriverWaitPassenger5Minute < 60 ? AppColor.redColor : AppColor.greenColor, - minHeight: 30, + minHeight: 25, borderRadius: BorderRadius.circular(15), value: controller.progressTimerDriverWaitPassenger5Minute.toDouble(), @@ -309,7 +309,7 @@ class DriverArrivePassengerAndWaitMinute extends StatelessWidget { children: [ Text( 'The driver waiting you in picked location .'.tr, - style: AppStyle.title, + style: AppStyle.subtitle, textAlign: TextAlign.center, ), const SizedBox( diff --git a/lib/views/home/map_widget.dart/ride_begin_passenger.dart b/lib/views/home/map_widget.dart/ride_begin_passenger.dart index b52f618..5501179 100644 --- a/lib/views/home/map_widget.dart/ride_begin_passenger.dart +++ b/lib/views/home/map_widget.dart/ride_begin_passenger.dart @@ -20,21 +20,21 @@ class RideBeginPassenger extends StatelessWidget { Widget build(BuildContext context) { ProfileController profileController = Get.put(ProfileController()); AudioController audioController = Get.put(AudioController()); + // Get.put(MapPassengerController()); return GetBuilder(builder: (controller) { - if ( //controller.rideTimerBegin || - controller.statusRide == 'Begin' || !controller.statusRideFromStart) { + if (controller.statusRide == 'Begin' || !controller.statusRideFromStart) { return Positioned( left: 10, right: 10, bottom: 4, child: Container( decoration: AppStyle.boxDecoration, - height: controller.rideTimerBegin ? Get.height * .3 : 0, + height: controller.statusRide == 'Begin' ? Get.height * .33 : 0, // width: 100, child: Padding( padding: const EdgeInsets.all(8.0), child: Column( - mainAxisAlignment: MainAxisAlignment.center, + mainAxisAlignment: MainAxisAlignment.spaceAround, children: [ Row( mainAxisAlignment: MainAxisAlignment.spaceBetween, @@ -58,6 +58,9 @@ class RideBeginPassenger extends StatelessWidget { ), ], ), + // SizedBox( + // height: 5, + // ), Row( mainAxisAlignment: MainAxisAlignment.spaceAround, children: [