This commit is contained in:
Hamza-Ayed
2024-06-01 01:54:27 +03:00
parent 02fdf8b0f1
commit 22487e138d
18 changed files with 558 additions and 166 deletions

View File

@@ -93,56 +93,61 @@ class RatePassenger extends StatelessWidget {
],
)),
),
controller.ispassengerWantWalletFromDriver
? Container(
decoration: AppStyle.boxDecoration1,
child: Padding(
padding: const EdgeInsets.all(8.0),
child: Column(
children: [
Text(
"How much Passenger pay?".tr,
style: AppStyle.title,
),
Form(
key: controller.formKey,
child: MyTextForm(
controller:
controller.passenggerPayAmount,
label: "passenger amount to me".tr,
hint: "passenger amount to me".tr,
type:
const TextInputType.numberWithOptions(
decimal: true)),
),
MyElevatedButton(
title: "Press here".tr,
onPressed: () {
controller.addPassengerWallet();
})
],
),
),
)
: Container(
width: Get.width * .73,
decoration: AppStyle.boxDecoration1,
child: Column(
children: [
Text(
"Would the passenger like to settle the remaining fare using their wallet?"
.tr,
style: AppStyle.title,
textAlign: TextAlign.center,
),
MyElevatedButton(
title: "Press here".tr,
onPressed: () {
controller.passengerWantPay();
})
],
),
),
controller.walletChecked != 'true'
? GetBuilder<RateController>(builder: (controller) {
return controller.ispassengerWantWalletFromDriver
? Container(
decoration: AppStyle.boxDecoration1,
child: Padding(
padding: const EdgeInsets.all(8.0),
child: Column(
children: [
Text(
"How much Passenger pay?".tr,
style: AppStyle.title,
),
Form(
key: controller.formKey,
child: MyTextForm(
controller:
controller.passengerPayAmount,
label:
"passenger amount to me".tr,
hint: "passenger amount to me".tr,
type: const TextInputType
.numberWithOptions(
decimal: true)),
),
MyElevatedButton(
title: "Press here".tr,
onPressed: () {
controller.addPassengerWallet();
})
],
),
),
)
: Container(
width: Get.width * .73,
decoration: AppStyle.boxDecoration1,
child: Column(
children: [
Text(
"Would the passenger like to settle the remaining fare using their wallet?"
.tr,
style: AppStyle.title,
textAlign: TextAlign.center,
),
MyElevatedButton(
title: "Press here".tr,
onPressed: () {
controller.passengerWantPay();
})
],
),
);
})
: const SizedBox(),
const SizedBox(
height: 20,
),

View File

@@ -237,7 +237,7 @@ class RideCalculateDriver extends StatelessWidget {
),
bottomTitles: AxisTitles(
axisNameWidget: Text(
'${"Total rides on month".tr} = ${durationController.jsonData2['message'][0]['totalCount'].toString()}'
'${"Total budgets on month".tr} = ${durationController.jsonData2['message'][0]['totalPrice'].toString()}'
.tr,
style: AppStyle.title,
),
@@ -246,7 +246,7 @@ class RideCalculateDriver extends StatelessWidget {
reservedSize: 30, showTitles: true)),
leftTitles: AxisTitles(
axisNameWidget: Text(
'Counts of rides on days'.tr,
'Counts of budgets on days'.tr,
style: AppStyle.title,
),
axisNameSize: 30,