25-3/18/1
This commit is contained in:
0
lib/views/Rate/rate_app_page.dart
Normal file → Executable file
0
lib/views/Rate/rate_app_page.dart
Normal file → Executable file
0
lib/views/Rate/rate_passenger.dart
Normal file → Executable file
0
lib/views/Rate/rate_passenger.dart
Normal file → Executable file
0
lib/views/Rate/ride_calculate_driver.dart
Normal file → Executable file
0
lib/views/Rate/ride_calculate_driver.dart
Normal file → Executable file
0
lib/views/auth/captin/ai_page.dart
Normal file → Executable file
0
lib/views/auth/captin/ai_page.dart
Normal file → Executable file
0
lib/views/auth/captin/camera_widgets/camera_lisence_page.dart
Normal file → Executable file
0
lib/views/auth/captin/camera_widgets/camera_lisence_page.dart
Normal file → Executable file
0
lib/views/auth/captin/car_license_page.dart
Normal file → Executable file
0
lib/views/auth/captin/car_license_page.dart
Normal file → Executable file
0
lib/views/auth/captin/cards/egypt_card_a_i.dart
Normal file → Executable file
0
lib/views/auth/captin/cards/egypt_card_a_i.dart
Normal file → Executable file
0
lib/views/auth/captin/cards/gemini_egypt.dart
Normal file → Executable file
0
lib/views/auth/captin/cards/gemini_egypt.dart
Normal file → Executable file
0
lib/views/auth/captin/cards/sms_signup.dart
Normal file → Executable file
0
lib/views/auth/captin/cards/sms_signup.dart
Normal file → Executable file
0
lib/views/auth/captin/contact_us_page.dart
Normal file → Executable file
0
lib/views/auth/captin/contact_us_page.dart
Normal file → Executable file
0
lib/views/auth/captin/criminal_documents_page.dart
Normal file → Executable file
0
lib/views/auth/captin/criminal_documents_page.dart
Normal file → Executable file
0
lib/views/auth/captin/driver_car_controller.dart
Normal file → Executable file
0
lib/views/auth/captin/driver_car_controller.dart
Normal file → Executable file
0
lib/views/auth/captin/forget.dart
Normal file → Executable file
0
lib/views/auth/captin/forget.dart
Normal file → Executable file
0
lib/views/auth/captin/invite_driver_screen.dart
Normal file → Executable file
0
lib/views/auth/captin/invite_driver_screen.dart
Normal file → Executable file
0
lib/views/auth/captin/login_captin.dart
Normal file → Executable file
0
lib/views/auth/captin/login_captin.dart
Normal file → Executable file
0
lib/views/auth/captin/logout_captain.dart
Normal file → Executable file
0
lib/views/auth/captin/logout_captain.dart
Normal file → Executable file
0
lib/views/auth/captin/register_captin.dart
Normal file → Executable file
0
lib/views/auth/captin/register_captin.dart
Normal file → Executable file
0
lib/views/auth/captin/verify_email_captain.dart
Normal file → Executable file
0
lib/views/auth/captin/verify_email_captain.dart
Normal file → Executable file
0
lib/views/auth/country_widget.dart
Normal file → Executable file
0
lib/views/auth/country_widget.dart
Normal file → Executable file
0
lib/views/auth/login_page.dart
Normal file → Executable file
0
lib/views/auth/login_page.dart
Normal file → Executable file
0
lib/views/auth/register_page.dart
Normal file → Executable file
0
lib/views/auth/register_page.dart
Normal file → Executable file
0
lib/views/auth/verify_email_page.dart
Normal file → Executable file
0
lib/views/auth/verify_email_page.dart
Normal file → Executable file
0
lib/views/home/Captin/About Us/about_us.dart
Normal file → Executable file
0
lib/views/home/Captin/About Us/about_us.dart
Normal file → Executable file
0
lib/views/home/Captin/About Us/frequantly_question.dart
Normal file → Executable file
0
lib/views/home/Captin/About Us/frequantly_question.dart
Normal file → Executable file
0
lib/views/home/Captin/About Us/settings_captain.dart
Normal file → Executable file
0
lib/views/home/Captin/About Us/settings_captain.dart
Normal file → Executable file
0
lib/views/home/Captin/About Us/using_app_page.dart
Normal file → Executable file
0
lib/views/home/Captin/About Us/using_app_page.dart
Normal file → Executable file
0
lib/views/home/Captin/About Us/video_page.dart
Normal file → Executable file
0
lib/views/home/Captin/About Us/video_page.dart
Normal file → Executable file
0
lib/views/home/Captin/assurance_health_page.dart
Normal file → Executable file
0
lib/views/home/Captin/assurance_health_page.dart
Normal file → Executable file
0
lib/views/home/Captin/bottom_bar.dart
Normal file → Executable file
0
lib/views/home/Captin/bottom_bar.dart
Normal file → Executable file
0
lib/views/home/Captin/camer_widget.dart
Normal file → Executable file
0
lib/views/home/Captin/camer_widget.dart
Normal file → Executable file
0
lib/views/home/Captin/driver_map_page.dart
Normal file → Executable file
0
lib/views/home/Captin/driver_map_page.dart
Normal file → Executable file
0
lib/views/home/Captin/history/history_captain.dart
Normal file → Executable file
0
lib/views/home/Captin/history/history_captain.dart
Normal file → Executable file
0
lib/views/home/Captin/history/history_details_page.dart
Normal file → Executable file
0
lib/views/home/Captin/history/history_details_page.dart
Normal file → Executable file
0
lib/views/home/Captin/home_captain/drawer_captain.dart
Normal file → Executable file
0
lib/views/home/Captin/home_captain/drawer_captain.dart
Normal file → Executable file
0
lib/views/home/Captin/home_captain/driver_call_page.dart
Normal file → Executable file
0
lib/views/home/Captin/home_captain/driver_call_page.dart
Normal file → Executable file
0
lib/views/home/Captin/home_captain/help_captain.dart
Normal file → Executable file
0
lib/views/home/Captin/home_captain/help_captain.dart
Normal file → Executable file
0
lib/views/home/Captin/home_captain/help_details_replay_page.dart
Normal file → Executable file
0
lib/views/home/Captin/home_captain/help_details_replay_page.dart
Normal file → Executable file
0
lib/views/home/Captin/home_captain/home_captin.dart
Normal file → Executable file
0
lib/views/home/Captin/home_captain/home_captin.dart
Normal file → Executable file
0
lib/views/home/Captin/home_captain/widget/call_page.dart
Normal file → Executable file
0
lib/views/home/Captin/home_captain/widget/call_page.dart
Normal file → Executable file
0
lib/views/home/Captin/home_captain/widget/connect.dart
Normal file → Executable file
0
lib/views/home/Captin/home_captain/widget/connect.dart
Normal file → Executable file
77
lib/views/home/Captin/home_captain/widget/left_menu_map_captain.dart
Normal file → Executable file
77
lib/views/home/Captin/home_captain/widget/left_menu_map_captain.dart
Normal file → Executable file
@@ -1,12 +1,7 @@
|
||||
import 'dart:convert';
|
||||
import 'dart:math';
|
||||
import 'package:crypto/crypto.dart';
|
||||
import 'dart:io';
|
||||
|
||||
import 'package:location/location.dart';
|
||||
import 'package:permission_handler/permission_handler.dart';
|
||||
import 'package:sefer_driver/constant/box_name.dart';
|
||||
import 'package:sefer_driver/controller/firebase/local_notification.dart';
|
||||
import 'package:sefer_driver/controller/functions/encrypt_decrypt.dart';
|
||||
import 'package:sefer_driver/main.dart';
|
||||
import 'package:sefer_driver/views/home/Captin/orderCaptin/vip_order_page.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
@@ -15,11 +10,7 @@ import 'package:get/get.dart';
|
||||
import 'package:sefer_driver/controller/home/captin/home_captain_controller.dart';
|
||||
|
||||
import '../../../../../constant/colors.dart';
|
||||
import '../../../../../controller/functions/face_detect.dart';
|
||||
import '../../../../../controller/functions/location_controller.dart';
|
||||
import '../../../../../controller/functions/package_info.dart';
|
||||
import '../../../../../controller/functions/security_checks.dart';
|
||||
import '../../../../../print.dart';
|
||||
import '../../../../../controller/packages/lingo/lingo_hunter.dart';
|
||||
import '../../../../Rate/ride_calculate_driver.dart';
|
||||
|
||||
GetBuilder<HomeCaptainController> leftMainMenuCaptainIcons() {
|
||||
@@ -102,32 +93,46 @@ GetBuilder<HomeCaptainController> leftMainMenuCaptainIcons() {
|
||||
)
|
||||
: const SizedBox(),
|
||||
// : const SizedBox(),
|
||||
AnimatedContainer(
|
||||
duration: const Duration(microseconds: 200),
|
||||
width: controller.widthMapTypeAndTraffic,
|
||||
decoration: BoxDecoration(
|
||||
color: AppColor.secondaryColor,
|
||||
border: Border.all(color: AppColor.blueColor),
|
||||
borderRadius: BorderRadius.circular(15)),
|
||||
child: Builder(builder: (context) {
|
||||
return IconButton(
|
||||
onPressed: () async {
|
||||
final random = Random();
|
||||
// AnimatedContainer(
|
||||
// duration: const Duration(microseconds: 200),
|
||||
// width: controller.widthMapTypeAndTraffic,
|
||||
// decoration: BoxDecoration(
|
||||
// color: AppColor.secondaryColor,
|
||||
// border: Border.all(color: AppColor.blueColor),
|
||||
// borderRadius: BorderRadius.circular(15)),
|
||||
// child: Builder(builder: (context) {
|
||||
// return IconButton(
|
||||
// onPressed: () async {
|
||||
// print("Current working directory: ${Directory.current.path}");
|
||||
// print(
|
||||
// "pubspec.yaml exists here?: ${await File('${Directory.current.path}/pubspec.yaml').exists()}");
|
||||
|
||||
if (random.nextBool()) {
|
||||
await SecurityHelper.performSecurityChecks();
|
||||
} else {
|
||||
await SecurityChecks.isDeviceRootedFromNative(Get.context!);
|
||||
}
|
||||
},
|
||||
icon: const Icon(
|
||||
FontAwesome5.grin_tears,
|
||||
size: 29,
|
||||
color: AppColor.blueColor,
|
||||
),
|
||||
);
|
||||
}),
|
||||
),
|
||||
// try {
|
||||
// await LingoHunter.extractAndCreateTranslationFiles(
|
||||
// baseLang: 'en',
|
||||
// langs: ['ar', 'fr', 'es'],
|
||||
// // Remove projectDirectory: Let it auto-detect.
|
||||
// // projectDirectory: '/Users/hamzaaleghwairyeen/development/App/driver_sefer',
|
||||
// outputDirectory:
|
||||
// '/Users/hamzaaleghwairyeen/development/App/driver_sefer/assets/lang',
|
||||
// additionalRegExps: [
|
||||
// RegExp(r'translate\("([^\"]+)"\)'),
|
||||
// ],
|
||||
// );
|
||||
// print(
|
||||
// "✅ Translation files generated successfully (auto-detected).");
|
||||
// } catch (e) {
|
||||
// print("Error: $e");
|
||||
// }
|
||||
// },
|
||||
// icon: const Icon(
|
||||
// FontAwesome5.grin_tears,
|
||||
// size: 29,
|
||||
// color: AppColor.blueColor,
|
||||
// ),
|
||||
// );
|
||||
// }),
|
||||
// ),
|
||||
|
||||
const SizedBox(
|
||||
height: 5,
|
||||
|
||||
0
lib/views/home/Captin/home_captain/widget/zones_controller.dart
Normal file → Executable file
0
lib/views/home/Captin/home_captain/widget/zones_controller.dart
Normal file → Executable file
0
lib/views/home/Captin/maintain_center_page.dart
Normal file → Executable file
0
lib/views/home/Captin/maintain_center_page.dart
Normal file → Executable file
0
lib/views/home/Captin/mapDriverWidgets/driver_end_ride_bar.dart
Normal file → Executable file
0
lib/views/home/Captin/mapDriverWidgets/driver_end_ride_bar.dart
Normal file → Executable file
0
lib/views/home/Captin/mapDriverWidgets/google_driver_map_page.dart
Normal file → Executable file
0
lib/views/home/Captin/mapDriverWidgets/google_driver_map_page.dart
Normal file → Executable file
0
lib/views/home/Captin/mapDriverWidgets/google_map_app.dart
Normal file → Executable file
0
lib/views/home/Captin/mapDriverWidgets/google_map_app.dart
Normal file → Executable file
0
lib/views/home/Captin/mapDriverWidgets/passenger_info_window.dart
Normal file → Executable file
0
lib/views/home/Captin/mapDriverWidgets/passenger_info_window.dart
Normal file → Executable file
0
lib/views/home/Captin/mapDriverWidgets/sos_connect.dart
Normal file → Executable file
0
lib/views/home/Captin/mapDriverWidgets/sos_connect.dart
Normal file → Executable file
0
lib/views/home/Captin/orderCaptin/call.dart
Normal file → Executable file
0
lib/views/home/Captin/orderCaptin/call.dart
Normal file → Executable file
0
lib/views/home/Captin/orderCaptin/order_over_lay.dart
Normal file → Executable file
0
lib/views/home/Captin/orderCaptin/order_over_lay.dart
Normal file → Executable file
0
lib/views/home/Captin/orderCaptin/order_request_page.dart
Normal file → Executable file
0
lib/views/home/Captin/orderCaptin/order_request_page.dart
Normal file → Executable file
0
lib/views/home/Captin/orderCaptin/order_speed_request.dart
Normal file → Executable file
0
lib/views/home/Captin/orderCaptin/order_speed_request.dart
Normal file → Executable file
0
lib/views/home/Captin/orderCaptin/test_order_page.dart
Normal file → Executable file
0
lib/views/home/Captin/orderCaptin/test_order_page.dart
Normal file → Executable file
0
lib/views/home/Captin/orderCaptin/vip_order_page.dart
Normal file → Executable file
0
lib/views/home/Captin/orderCaptin/vip_order_page.dart
Normal file → Executable file
0
lib/views/home/Captin/passportimage.dart
Normal file → Executable file
0
lib/views/home/Captin/passportimage.dart
Normal file → Executable file
0
lib/views/home/Captin/text_scanner.dart
Normal file → Executable file
0
lib/views/home/Captin/text_scanner.dart
Normal file → Executable file
0
lib/views/home/my_wallet/bank_account_egypt.dart
Normal file → Executable file
0
lib/views/home/my_wallet/bank_account_egypt.dart
Normal file → Executable file
3
lib/views/home/my_wallet/card_wallet_widget.dart
Normal file → Executable file
3
lib/views/home/my_wallet/card_wallet_widget.dart
Normal file → Executable file
@@ -183,8 +183,7 @@ class CardSeferWalletDriver extends StatelessWidget {
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
Text(
|
||||
'${Get.find<CaptainWalletController>().totalAmountVisa} ${'L.E'.tr}' ??
|
||||
'0.0 ${'L.E'.tr}',
|
||||
'${Get.find<CaptainWalletController>().totalAmountVisa} ${'L.E'.tr}',
|
||||
style: AppStyle.headTitle2.copyWith(
|
||||
color: AppColor.writeColor, fontSize: 28),
|
||||
),
|
||||
|
||||
0
lib/views/home/my_wallet/payment_history_driver_page.dart
Normal file → Executable file
0
lib/views/home/my_wallet/payment_history_driver_page.dart
Normal file → Executable file
0
lib/views/home/my_wallet/points_captain.dart
Normal file → Executable file
0
lib/views/home/my_wallet/points_captain.dart
Normal file → Executable file
0
lib/views/home/my_wallet/transfer_budget_page.dart
Normal file → Executable file
0
lib/views/home/my_wallet/transfer_budget_page.dart
Normal file → Executable file
70
lib/views/home/my_wallet/walet_captain.dart
Normal file → Executable file
70
lib/views/home/my_wallet/walet_captain.dart
Normal file → Executable file
@@ -1,3 +1,4 @@
|
||||
import 'package:local_auth/local_auth.dart';
|
||||
import 'package:sefer_driver/constant/links.dart';
|
||||
import 'package:sefer_driver/controller/functions/crud.dart';
|
||||
import 'package:sefer_driver/controller/functions/tts.dart';
|
||||
@@ -382,13 +383,38 @@ class WalletCaptain extends StatelessWidget {
|
||||
confirm: MyElevatedButton(
|
||||
title: 'Pay'.tr,
|
||||
onPressed: () async {
|
||||
if (double.parse(controller.amountFromBudgetController.text) <
|
||||
double.parse(controller.totalAmountVisa)) {
|
||||
await controller.payFromBudget();
|
||||
} else {
|
||||
Get.back();
|
||||
bool isAvailable =
|
||||
await LocalAuthentication().isDeviceSupported();
|
||||
if (isAvailable) {
|
||||
// Authenticate the user
|
||||
bool didAuthenticate = await LocalAuthentication().authenticate(
|
||||
localizedReason:
|
||||
'Use Touch ID or Face ID to confirm payment',
|
||||
options: AuthenticationOptions(
|
||||
biometricOnly: true,
|
||||
sensitiveTransaction: true,
|
||||
));
|
||||
if (didAuthenticate) {
|
||||
if (double.parse(controller.amountFromBudgetController.text) <
|
||||
double.parse(controller.totalAmountVisa)) {
|
||||
await controller.payFromBudget();
|
||||
} else {
|
||||
Get.back();
|
||||
|
||||
mySnackeBarError('Your Budget less than needed'.tr);
|
||||
mySnackeBarError('Your Budget less than needed'.tr);
|
||||
}
|
||||
} else {
|
||||
// Authentication failed, handle accordingly
|
||||
MyDialog().getDialog('Authentication failed'.tr, ''.tr, () {
|
||||
Get.back();
|
||||
});
|
||||
}
|
||||
} else {
|
||||
MyDialog().getDialog('Biometric Authentication'.tr,
|
||||
'You should use Touch ID or Face ID to confirm payment'.tr,
|
||||
() {
|
||||
Get.back();
|
||||
});
|
||||
}
|
||||
},
|
||||
),
|
||||
@@ -406,12 +432,34 @@ class WalletCaptain extends StatelessWidget {
|
||||
Widget _buildTransferBudgetButton(CaptainWalletController controller) {
|
||||
return MyElevatedButton(
|
||||
title: 'Transfer budget'.tr,
|
||||
onPressed: () {
|
||||
if (double.parse(controller.totalAmountVisa) > 15) {
|
||||
Get.to(() => const TransferBudgetPage());
|
||||
onPressed: () async {
|
||||
bool isAvailable = await LocalAuthentication().isDeviceSupported();
|
||||
if (isAvailable) {
|
||||
// Authenticate the user
|
||||
bool didAuthenticate = await LocalAuthentication().authenticate(
|
||||
localizedReason: 'Use Touch ID or Face ID to confirm payment',
|
||||
options: AuthenticationOptions(
|
||||
biometricOnly: true,
|
||||
sensitiveTransaction: true,
|
||||
));
|
||||
if (didAuthenticate) {
|
||||
if (double.parse(controller.totalAmountVisa) > 15) {
|
||||
Get.to(() => const TransferBudgetPage());
|
||||
} else {
|
||||
mySnackeBarError(
|
||||
"You don't have enough money in your SEFER wallet".tr);
|
||||
}
|
||||
} else {
|
||||
// Authentication failed, handle accordingly
|
||||
MyDialog().getDialog('Authentication failed'.tr, ''.tr, () {
|
||||
Get.back();
|
||||
});
|
||||
}
|
||||
} else {
|
||||
mySnackeBarError(
|
||||
"You don't have enough money in your SEFER wallet".tr);
|
||||
MyDialog().getDialog('Biometric Authentication'.tr,
|
||||
'You should use Touch ID or Face ID to confirm payment'.tr, () {
|
||||
Get.back();
|
||||
});
|
||||
}
|
||||
},
|
||||
);
|
||||
|
||||
0
lib/views/home/my_wallet/weekly_payment_page.dart
Normal file → Executable file
0
lib/views/home/my_wallet/weekly_payment_page.dart
Normal file → Executable file
0
lib/views/home/on_boarding_page.dart
Normal file → Executable file
0
lib/views/home/on_boarding_page.dart
Normal file → Executable file
0
lib/views/home/profile/captains_cars.dart
Normal file → Executable file
0
lib/views/home/profile/captains_cars.dart
Normal file → Executable file
0
lib/views/home/profile/cars_inserting_page.dart
Normal file → Executable file
0
lib/views/home/profile/cars_inserting_page.dart
Normal file → Executable file
0
lib/views/home/profile/feed_back_page.dart
Normal file → Executable file
0
lib/views/home/profile/feed_back_page.dart
Normal file → Executable file
0
lib/views/home/profile/passenger_profile_page.dart
Normal file → Executable file
0
lib/views/home/profile/passenger_profile_page.dart
Normal file → Executable file
0
lib/views/home/profile/profile_captain.dart
Normal file → Executable file
0
lib/views/home/profile/profile_captain.dart
Normal file → Executable file
0
lib/views/home/profile/promos_passenger_page.dart
Normal file → Executable file
0
lib/views/home/profile/promos_passenger_page.dart
Normal file → Executable file
0
lib/views/home/profile/taarif_page.dart
Normal file → Executable file
0
lib/views/home/profile/taarif_page.dart
Normal file → Executable file
0
lib/views/lang/languages.dart
Normal file → Executable file
0
lib/views/lang/languages.dart
Normal file → Executable file
0
lib/views/notification/available_rides_page.dart
Normal file → Executable file
0
lib/views/notification/available_rides_page.dart
Normal file → Executable file
0
lib/views/notification/notification_captain.dart
Normal file → Executable file
0
lib/views/notification/notification_captain.dart
Normal file → Executable file
0
lib/views/notification/notification_page.dart
Normal file → Executable file
0
lib/views/notification/notification_page.dart
Normal file → Executable file
0
lib/views/widgets/circle_container.dart
Normal file → Executable file
0
lib/views/widgets/circle_container.dart
Normal file → Executable file
0
lib/views/widgets/elevated_btn.dart
Normal file → Executable file
0
lib/views/widgets/elevated_btn.dart
Normal file → Executable file
0
lib/views/widgets/error_snakbar.dart
Normal file → Executable file
0
lib/views/widgets/error_snakbar.dart
Normal file → Executable file
0
lib/views/widgets/icon_widget_menu.dart
Normal file → Executable file
0
lib/views/widgets/icon_widget_menu.dart
Normal file → Executable file
0
lib/views/widgets/my_circular_indicator_timer.dart
Normal file → Executable file
0
lib/views/widgets/my_circular_indicator_timer.dart
Normal file → Executable file
0
lib/views/widgets/my_scafold.dart
Normal file → Executable file
0
lib/views/widgets/my_scafold.dart
Normal file → Executable file
0
lib/views/widgets/my_textField.dart
Normal file → Executable file
0
lib/views/widgets/my_textField.dart
Normal file → Executable file
0
lib/views/widgets/mycircular.dart
Normal file → Executable file
0
lib/views/widgets/mycircular.dart
Normal file → Executable file
0
lib/views/widgets/mydialoug.dart
Normal file → Executable file
0
lib/views/widgets/mydialoug.dart
Normal file → Executable file
Reference in New Issue
Block a user