Update: 2026-06-25 00:50:19
This commit is contained in:
@@ -113,7 +113,8 @@ class ApplyOrderWidget extends StatelessWidget {
|
||||
BuildContext context, RideLifecycleController controller) {
|
||||
// تنسيق السعر
|
||||
final formatter = NumberFormat("#,###");
|
||||
String formattedPrice = formatter.format(controller.totalPassenger);
|
||||
num totalVal = num.tryParse(controller.totalPassenger.toString()) ?? 0;
|
||||
String formattedPrice = formatter.format(totalVal);
|
||||
|
||||
// حساب الدقائق من الوقت المتبقي الحي، وليس ETA الأصلي فقط.
|
||||
final int secondsToPassenger =
|
||||
|
||||
@@ -203,7 +203,7 @@ class RideBeginPassenger extends StatelessWidget {
|
||||
crossAxisAlignment: CrossAxisAlignment.end,
|
||||
children: [
|
||||
Text(
|
||||
NumberFormat('#,###').format(controller.totalPassenger),
|
||||
NumberFormat('#,###').format(num.tryParse(controller.totalPassenger.toString()) ?? 0),
|
||||
style: const TextStyle(
|
||||
fontWeight: FontWeight.w900,
|
||||
fontSize: 16,
|
||||
|
||||
@@ -131,67 +131,61 @@ void showPaymentBottomSheet(BuildContext context) {
|
||||
borderRadius: BorderRadius.vertical(top: Radius.circular(15.0)),
|
||||
),
|
||||
builder: (BuildContext context) {
|
||||
return PopScope(
|
||||
canPop: true,
|
||||
onPopInvokedWithResult: (didPop, result) async {
|
||||
Get.back();
|
||||
},
|
||||
child: Container(
|
||||
padding: const EdgeInsets.all(16.0),
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
crossAxisAlignment: CrossAxisAlignment.stretch,
|
||||
children: [
|
||||
Text(
|
||||
'Select Payment Amount'.tr,
|
||||
style: AppStyle.headTitle2,
|
||||
textAlign: TextAlign.center,
|
||||
),
|
||||
const SizedBox(height: 16.0),
|
||||
return Container(
|
||||
padding: const EdgeInsets.all(16.0),
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
crossAxisAlignment: CrossAxisAlignment.stretch,
|
||||
children: [
|
||||
Text(
|
||||
'Select Payment Amount'.tr,
|
||||
style: AppStyle.headTitle2,
|
||||
textAlign: TextAlign.center,
|
||||
),
|
||||
const SizedBox(height: 16.0),
|
||||
|
||||
// Payment Options List
|
||||
_buildPaymentOption(
|
||||
context: context,
|
||||
controller: controller,
|
||||
amount: 500,
|
||||
bonusAmount: 30,
|
||||
currency: CurrencyHelper.currency,
|
||||
),
|
||||
// Payment Options List
|
||||
_buildPaymentOption(
|
||||
context: context,
|
||||
controller: controller,
|
||||
amount: 500,
|
||||
bonusAmount: 30,
|
||||
currency: CurrencyHelper.currency,
|
||||
),
|
||||
|
||||
const SizedBox(height: 8.0),
|
||||
_buildPaymentOption(
|
||||
context: context,
|
||||
controller: controller,
|
||||
amount: 1000,
|
||||
bonusAmount: 70,
|
||||
currency: CurrencyHelper.currency,
|
||||
),
|
||||
const SizedBox(height: 8.0),
|
||||
_buildPaymentOption(
|
||||
context: context,
|
||||
controller: controller,
|
||||
amount: 1000,
|
||||
bonusAmount: 70,
|
||||
currency: CurrencyHelper.currency,
|
||||
),
|
||||
|
||||
const SizedBox(height: 8.0),
|
||||
_buildPaymentOption(
|
||||
context: context,
|
||||
controller: controller,
|
||||
amount: 2000,
|
||||
bonusAmount: 180,
|
||||
currency: CurrencyHelper.currency,
|
||||
),
|
||||
const SizedBox(height: 8.0),
|
||||
_buildPaymentOption(
|
||||
context: context,
|
||||
controller: controller,
|
||||
amount: 2000,
|
||||
bonusAmount: 180,
|
||||
currency: CurrencyHelper.currency,
|
||||
),
|
||||
|
||||
const SizedBox(height: 8.0),
|
||||
_buildPaymentOption(
|
||||
context: context,
|
||||
controller: controller,
|
||||
amount: 5000,
|
||||
bonusAmount: 700,
|
||||
currency: CurrencyHelper.currency,
|
||||
),
|
||||
const SizedBox(height: 8.0),
|
||||
_buildPaymentOption(
|
||||
context: context,
|
||||
controller: controller,
|
||||
amount: 5000,
|
||||
bonusAmount: 700,
|
||||
currency: CurrencyHelper.currency,
|
||||
),
|
||||
|
||||
const SizedBox(height: 16.0),
|
||||
TextButton(
|
||||
onPressed: () => Get.back(),
|
||||
child: Text('Cancel'.tr),
|
||||
),
|
||||
],
|
||||
),
|
||||
const SizedBox(height: 16.0),
|
||||
TextButton(
|
||||
onPressed: () => Get.back(),
|
||||
child: Text('Cancel'.tr),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
},
|
||||
@@ -445,12 +439,15 @@ void showPaymentOptions(BuildContext context, PaymentController controller) {
|
||||
borderRadius: BorderRadius.circular(10),
|
||||
color: Colors.transparent,
|
||||
),
|
||||
child: ListTile(
|
||||
title: Text(
|
||||
'Pay by Cliq'.tr,
|
||||
style: AppStyle.title,
|
||||
child: Material(
|
||||
color: Colors.transparent,
|
||||
child: ListTile(
|
||||
title: Text(
|
||||
'Pay by Cliq'.tr,
|
||||
style: AppStyle.title,
|
||||
),
|
||||
trailing: const Icon(Icons.payment, size: 40, color: Colors.green),
|
||||
),
|
||||
trailing: const Icon(Icons.payment, size: 40, color: Colors.green),
|
||||
),
|
||||
)), if (box.read(BoxName.countryCode) == 'Syria')
|
||||
GestureDetector(
|
||||
|
||||
Reference in New Issue
Block a user