9/11/1
This commit is contained in:
2
.env
2
.env
@@ -19,6 +19,8 @@ seferAlexandriaServer=https://seferalexandria.site/sefer
|
|||||||
seferPaymentServer=https://seferpw.shop/sefer
|
seferPaymentServer=https://seferpw.shop/sefer
|
||||||
seferCairoServer=https://sefer.click/sefer
|
seferCairoServer=https://sefer.click/sefer
|
||||||
seferGizaServer=https://sefergiza.site/sefer
|
seferGizaServer=https://sefergiza.site/sefer
|
||||||
|
anthropicAIkeySeferNewHamzaayedpython=zg-qbc-qvo39-vCB-WnzEwFNArO0YlTapvfhtmguKWsXJSKqg_NZSjHBYVXMZK1yUK88SobdckV0KuPaBh0c_WHtGsRO_439PBk-e2QqgkQQXrXlBl
|
||||||
|
|
||||||
privateKeyFCM='''{
|
privateKeyFCM='''{
|
||||||
"type": "service_account",
|
"type": "service_account",
|
||||||
"project_id": "ride-b1bd8",
|
"project_id": "ride-b1bd8",
|
||||||
|
|||||||
@@ -54,8 +54,8 @@ android {
|
|||||||
// For more information, see: https://docs.flutter.dev/deployment/android#reviewing-the-gradle-build-configuration.
|
// For more information, see: https://docs.flutter.dev/deployment/android#reviewing-the-gradle-build-configuration.
|
||||||
minSdk = 23
|
minSdk = 23
|
||||||
targetSdk = flutter.targetSdkVersion
|
targetSdk = flutter.targetSdkVersion
|
||||||
versionCode = 79
|
versionCode = 83
|
||||||
versionName = '1.5.79'
|
versionName = '1.5.83'
|
||||||
multiDexEnabled =true
|
multiDexEnabled =true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ import 'box_name.dart';
|
|||||||
|
|
||||||
class AppLink {
|
class AppLink {
|
||||||
static final String seferPaymentServer0 = Env.seferPaymentServer;
|
static final String seferPaymentServer0 = Env.seferPaymentServer;
|
||||||
static final String seferPaymentServer = '${Env.seferCairoServer}/ride';
|
static final String seferPaymentServer = '${Env.seferPaymentServer}/ride';
|
||||||
static final String seferAlexandriaServer = Env.seferAlexandriaServer;
|
static final String seferAlexandriaServer = Env.seferAlexandriaServer;
|
||||||
static final String seferCairoServer = Env.seferCairoServer;
|
static final String seferCairoServer = Env.seferCairoServer;
|
||||||
static final String seferGizaServer = Env.seferGizaServer;
|
static final String seferGizaServer = Env.seferGizaServer;
|
||||||
|
|||||||
@@ -18,6 +18,7 @@ import '../../views/auth/captin/criminal_documents_page.dart';
|
|||||||
import '../../views/home/Captin/home_captain/home_captin.dart';
|
import '../../views/home/Captin/home_captain/home_captin.dart';
|
||||||
import '../../views/home/Captin/orderCaptin/order_speed_request.dart';
|
import '../../views/home/Captin/orderCaptin/order_speed_request.dart';
|
||||||
import '../../views/home/Captin/orderCaptin/order_request_page.dart';
|
import '../../views/home/Captin/orderCaptin/order_request_page.dart';
|
||||||
|
import '../../views/home/Captin/orderCaptin/vip_order_page.dart';
|
||||||
import '../auth/google_sign.dart';
|
import '../auth/google_sign.dart';
|
||||||
import '../functions/face_detect.dart';
|
import '../functions/face_detect.dart';
|
||||||
import 'access_token.dart';
|
import 'access_token.dart';
|
||||||
@@ -80,28 +81,28 @@ class FirebaseMessagesController extends GetxController {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
FirebaseMessaging.onBackgroundMessage((RemoteMessage message) async {
|
FirebaseMessaging.onBackgroundMessage((RemoteMessage message) async {
|
||||||
if (message.notification!.title! == 'Order'.tr) {
|
// if (message.notification!.title! == 'Order'.tr) {
|
||||||
if (Platform.isAndroid) {
|
// if (Platform.isAndroid) {
|
||||||
NotificationController()
|
// NotificationController()
|
||||||
.showNotification('Order'.tr, '', 'order', 'order_page_payload');
|
// .showNotification('Order'.tr, '', 'order', 'order_page_payload');
|
||||||
}
|
// }
|
||||||
// await FirebaseMessagesController().showOverlayNotification(message);
|
// // await FirebaseMessagesController().showOverlayNotification(message);
|
||||||
var myListString = message.data['DriverList'];
|
// var myListString = message.data['DriverList'];
|
||||||
// var points = message.data['PolylineJson'];
|
// // var points = message.data['PolylineJson'];
|
||||||
|
|
||||||
var myList = jsonDecode(myListString) as List<dynamic>;
|
// var myList = jsonDecode(myListString) as List<dynamic>;
|
||||||
// var myPoints = jsonDecode(points) as List<dynamic>;
|
// // var myPoints = jsonDecode(points) as List<dynamic>;
|
||||||
driverToken = myList[14].toString();
|
// driverToken = myList[14].toString();
|
||||||
// This is for location using and uploading status
|
// // This is for location using and uploading status
|
||||||
Get.put(HomeCaptainController()).changeRideId();
|
// Get.put(HomeCaptainController()).changeRideId();
|
||||||
update();
|
// update();
|
||||||
Get.to(() => OrderRequestPage(), arguments: {
|
// Get.to(() => OrderRequestPage(), arguments: {
|
||||||
'myListString': myListString,
|
// 'myListString': myListString,
|
||||||
'DriverList': myList,
|
// 'DriverList': myList,
|
||||||
// 'PolylineJson': myPoints,
|
// // 'PolylineJson': myPoints,
|
||||||
'body': message.notification!.body
|
// 'body': message.notification!.body
|
||||||
});
|
// });
|
||||||
}
|
// }
|
||||||
});
|
});
|
||||||
|
|
||||||
FirebaseMessaging.onMessageOpenedApp.listen((RemoteMessage message) {
|
FirebaseMessaging.onMessageOpenedApp.listen((RemoteMessage message) {
|
||||||
@@ -138,6 +139,23 @@ class FirebaseMessagesController extends GetxController {
|
|||||||
// 'Cancel Trip'.tr, 'Passenger Cancel Trip'.tr, 'cancel', '');
|
// 'Cancel Trip'.tr, 'Passenger Cancel Trip'.tr, 'cancel', '');
|
||||||
// }
|
// }
|
||||||
cancelTripDialog();
|
cancelTripDialog();
|
||||||
|
} else if (message.notification!.title == 'VIP Order') {
|
||||||
|
var myListString = message.data['DriverList'];
|
||||||
|
var driverList = jsonDecode(myListString) as List<dynamic>;
|
||||||
|
if (Platform.isAndroid) {
|
||||||
|
NotificationController()
|
||||||
|
.showNotification('VIP Order'.tr, '', 'order', '');
|
||||||
|
}
|
||||||
|
MyDialog().getDialog('VIP Order'.tr, 'midTitle', () {
|
||||||
|
sendNotificationToPassengerToken(
|
||||||
|
'VIP Order Accepted'.tr,
|
||||||
|
'The driver accepted your trip'.tr,
|
||||||
|
driverList[0],
|
||||||
|
[driverList[1]],
|
||||||
|
'order');
|
||||||
|
});
|
||||||
|
|
||||||
|
// Get.to(const VipOrderPage());
|
||||||
} else if (message.notification!.title == 'Cancel') {
|
} else if (message.notification!.title == 'Cancel') {
|
||||||
cancelTripDialog1();
|
cancelTripDialog1();
|
||||||
} else if (message.notification!.title! == 'token change') {
|
} else if (message.notification!.title! == 'token change') {
|
||||||
|
|||||||
@@ -87,28 +87,29 @@ class LocationController extends GetxController {
|
|||||||
|
|
||||||
switch (area) {
|
switch (area) {
|
||||||
case 'Cairo':
|
case 'Cairo':
|
||||||
endpoint = AppLink.addCarsLocationCairoEndpoint;
|
|
||||||
box.write(BoxName.serverChosen, AppLink.seferCairoServer);
|
box.write(BoxName.serverChosen, AppLink.seferCairoServer);
|
||||||
|
endpoint = AppLink.addCarsLocationCairoEndpoint;
|
||||||
Log.print('Endpoint: $endpoint');
|
Log.print('Endpoint: $endpoint');
|
||||||
break;
|
break;
|
||||||
case 'Giza':
|
case 'Giza':
|
||||||
|
box.write(BoxName.serverChosen, AppLink.seferGizaServer);
|
||||||
endpoint = AppLink.addCarsLocationGizaEndpoint;
|
endpoint = AppLink.addCarsLocationGizaEndpoint;
|
||||||
Log.print('Endpoint: $endpoint');
|
Log.print('Endpoint: $endpoint');
|
||||||
box.write(BoxName.serverChosen, AppLink.seferGizaServer);
|
|
||||||
break;
|
break;
|
||||||
case 'Alexandria':
|
case 'Alexandria':
|
||||||
endpoint = AppLink.addCarsLocationAlexandriaEndpoint;
|
|
||||||
Log.print('Endpoint: $endpoint');
|
|
||||||
box.write(
|
box.write(
|
||||||
BoxName.serverChosen, AppLink.seferAlexandriaServer);
|
BoxName.serverChosen, AppLink.seferAlexandriaServer);
|
||||||
|
endpoint = AppLink.addCarsLocationAlexandriaEndpoint;
|
||||||
|
Log.print('Endpoint: $endpoint');
|
||||||
break;
|
break;
|
||||||
case 'Outside':
|
case 'Outside':
|
||||||
// Handle cases outside of Cairo, Giza, and Alexandria
|
// Handle cases outside of Cairo, Giza, and Alexandria
|
||||||
print('Location outside Cairo, Giza, or Alexandria');
|
print('Location outside Cairo, Giza, or Alexandria');
|
||||||
|
|
||||||
|
box.write(BoxName.serverChosen, AppLink.seferCairoServer);
|
||||||
endpoint = AppLink
|
endpoint = AppLink
|
||||||
.addCarsLocationCairoEndpoint; // Fallback to Cairo endpoint
|
.addCarsLocationCairoEndpoint; // Fallback to Cairo endpoint
|
||||||
Log.print('Fallback Endpoint: $endpoint');
|
Log.print('Fallback Endpoint: $endpoint');
|
||||||
box.write(BoxName.serverChosen, AppLink.seferCairoServer);
|
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
// Handle any other unexpected cases
|
// Handle any other unexpected cases
|
||||||
|
|||||||
@@ -566,12 +566,14 @@ class MapDriverController extends GetxController {
|
|||||||
// Get.find<HomeCaptainController>().changeToAppliedRide('Finished');
|
// Get.find<HomeCaptainController>().changeToAppliedRide('Finished');
|
||||||
// Get.find<HomeCaptainController>().update();
|
// Get.find<HomeCaptainController>().update();
|
||||||
totalCost = price < 30
|
totalCost = price < 30
|
||||||
? carType != 'Comfort' && carType != 'Mashwari' && carType != 'Lady'
|
? carType != 'Comfort' && carType != 'Mishwar Vip' && carType != 'Lady'
|
||||||
? '20'
|
? '20'
|
||||||
: '30'
|
: '30'
|
||||||
: price < double.parse(totalPricePassenger)
|
: price < double.parse(totalPricePassenger)
|
||||||
? totalPricePassenger
|
? totalPricePassenger
|
||||||
: carType != 'Comfort' && carType != 'Mashwari' && carType != 'Lady'
|
: carType != 'Comfort' &&
|
||||||
|
carType != 'Mishwar Vip' &&
|
||||||
|
carType != 'Lady'
|
||||||
? totalPricePassenger
|
? totalPricePassenger
|
||||||
: price.toStringAsFixed(2);
|
: price.toStringAsFixed(2);
|
||||||
paymentAmount = totalCost;
|
paymentAmount = totalCost;
|
||||||
@@ -633,7 +635,7 @@ class MapDriverController extends GetxController {
|
|||||||
box.read(BoxName.driverID),
|
box.read(BoxName.driverID),
|
||||||
rideId,
|
rideId,
|
||||||
box.read(BoxName.tokenDriver),
|
box.read(BoxName.tokenDriver),
|
||||||
// carType == 'Comfort' || carType == 'Mashwari'
|
// carType == 'Comfort' || carType == 'Mishwar Vip'
|
||||||
// ? price.toStringAsFixed(2)
|
// ? price.toStringAsFixed(2)
|
||||||
// : totalPassenger
|
// : totalPassenger
|
||||||
paymentAmount.toString()
|
paymentAmount.toString()
|
||||||
@@ -681,44 +683,178 @@ class MapDriverController extends GetxController {
|
|||||||
|
|
||||||
int rideTimerFromBegin = 0;
|
int rideTimerFromBegin = 0;
|
||||||
double price = 0;
|
double price = 0;
|
||||||
|
DateTime currentTime = DateTime.now();
|
||||||
void rideIsBeginPassengerTimer() async {
|
void rideIsBeginPassengerTimer() async {
|
||||||
int durationOfRide = int.parse(durationOfRideValue);
|
int durationOfRide = int.parse(durationOfRideValue);
|
||||||
update();
|
update();
|
||||||
int infinity = 40000;
|
int infinity = 40000;
|
||||||
if (carType == 'Comfort' ||
|
if (carType == 'Comfort' ||
|
||||||
carType == 'Mashwari' ||
|
carType == 'Mishwar Vip' ||
|
||||||
carType == 'Rayeh Gai') {
|
carType == 'RayehGaiComfort') {
|
||||||
durationOfRide = infinity;
|
durationOfRide = infinity;
|
||||||
update();
|
update();
|
||||||
}
|
}
|
||||||
|
if (carType != 'Comfort' ||
|
||||||
|
carType != 'Mishwar Vip' ||
|
||||||
|
carType != 'Lady' ||
|
||||||
|
carType != 'RayehGaiComfort') {
|
||||||
|
price = double.parse(totalCost);
|
||||||
|
update();
|
||||||
|
}
|
||||||
for (int i = 0; i <= durationOfRide; i++) {
|
for (int i = 0; i <= durationOfRide; i++) {
|
||||||
await Future.delayed(const Duration(seconds: 1));
|
await Future.delayed(const Duration(seconds: 1));
|
||||||
recentDistanceToDash = Get.find<LocationController>().totalDistance;
|
recentDistanceToDash = Get.find<LocationController>().totalDistance;
|
||||||
rideTimerFromBegin = i;
|
rideTimerFromBegin = i;
|
||||||
price = carType == 'Comfort' // || carType == 'Free Ride'
|
|
||||||
? (i ~/ 60) +
|
if (startNameLocation.toLowerCase().contains('airport') ||
|
||||||
(recentDistanceToDash *
|
endNameLocation.toLowerCase().contains('airport') ||
|
||||||
Get.find<HomeCaptainController>().comfortPrice)
|
startNameLocation.contains('مطار') ||
|
||||||
: carType == 'Speed'
|
startNameLocation.contains('المطار') ||
|
||||||
? (i ~/ 60) +
|
endNameLocation.contains('مطار') ||
|
||||||
|
endNameLocation.contains('المطار')) {
|
||||||
|
price = carType == 'Comfort' // || carType == 'Free Ride'
|
||||||
|
? (i ~/ 60) * Get.find<HomeCaptainController>().latePrice +
|
||||||
|
20 +
|
||||||
|
(recentDistanceToDash *
|
||||||
|
Get.find<HomeCaptainController>().comfortPrice)
|
||||||
|
|
||||||
|
// : carType == 'Speed'
|
||||||
|
// ? (i ~/ 60) +
|
||||||
|
// (recentDistanceToDash *
|
||||||
|
// Get.find<HomeCaptainController>().speedPrice)
|
||||||
|
: carType == 'Lady'
|
||||||
|
? (i ~/ 60) * Get.find<HomeCaptainController>().latePrice +
|
||||||
|
20 +
|
||||||
|
(recentDistanceToDash *
|
||||||
|
Get.find<HomeCaptainController>().comfortPrice)
|
||||||
|
// : carType == 'Delivery'
|
||||||
|
// ? (i ~/ 60) +
|
||||||
|
// (recentDistanceToDash *
|
||||||
|
// Get.find<HomeCaptainController>().deliveryPrice)
|
||||||
|
: carType == 'RayehGaiComfort'
|
||||||
|
? (i ~/ 60) * Get.find<HomeCaptainController>().latePrice +
|
||||||
|
20 +
|
||||||
|
(recentDistanceToDash *
|
||||||
|
Get.find<HomeCaptainController>().comfortPrice)
|
||||||
|
: (i ~/ 60) * Get.find<HomeCaptainController>().latePrice +
|
||||||
|
20 +
|
||||||
|
(recentDistanceToDash *
|
||||||
|
Get.find<HomeCaptainController>().mashwariPrice);
|
||||||
|
} else if (currentTime.hour >= 21 && currentTime.hour < 0) {
|
||||||
|
price = carType == 'Comfort' // || carType == 'Free Ride'
|
||||||
|
? (i ~/ 60) * Get.find<HomeCaptainController>().latePrice +
|
||||||
|
20 +
|
||||||
|
(recentDistanceToDash *
|
||||||
|
Get.find<HomeCaptainController>().comfortPrice)
|
||||||
|
|
||||||
|
// : carType == 'Speed'
|
||||||
|
// ? (i ~/ 60) +
|
||||||
|
// (recentDistanceToDash *
|
||||||
|
// Get.find<HomeCaptainController>().speedPrice)
|
||||||
|
: carType == 'Lady'
|
||||||
|
? (i ~/ 60) * Get.find<HomeCaptainController>().latePrice +
|
||||||
|
20 +
|
||||||
|
(recentDistanceToDash *
|
||||||
|
Get.find<HomeCaptainController>().comfortPrice)
|
||||||
|
// : carType == 'Delivery'
|
||||||
|
// ? (i ~/ 60) +
|
||||||
|
// (recentDistanceToDash *
|
||||||
|
// Get.find<HomeCaptainController>().deliveryPrice)
|
||||||
|
: carType == 'RayehGaiComfort'
|
||||||
|
? (i ~/ 60) * Get.find<HomeCaptainController>().latePrice +
|
||||||
|
20 +
|
||||||
|
(recentDistanceToDash *
|
||||||
|
Get.find<HomeCaptainController>().comfortPrice)
|
||||||
|
: (i ~/ 60) * Get.find<HomeCaptainController>().latePrice +
|
||||||
|
20 +
|
||||||
|
(recentDistanceToDash *
|
||||||
|
Get.find<HomeCaptainController>().mashwariPrice);
|
||||||
|
} else if (currentTime.hour >= 1 && currentTime.hour < 5) {
|
||||||
|
if (startNameLocation.contains('club') ||
|
||||||
|
startNameLocation.contains('nightclub') ||
|
||||||
|
startNameLocation.contains('ديسكو') ||
|
||||||
|
startNameLocation.contains('ملهى ليلي') ||
|
||||||
|
startNameLocation.contains('Night club')) {
|
||||||
|
price = carType == 'Comfort' // || carType == 'Free Ride'
|
||||||
|
? (i ~/ 60) *
|
||||||
|
(Get.find<HomeCaptainController>().latePrice + .5) *
|
||||||
|
2 +
|
||||||
(recentDistanceToDash *
|
(recentDistanceToDash *
|
||||||
Get.find<HomeCaptainController>().speedPrice)
|
Get.find<HomeCaptainController>().comfortPrice)
|
||||||
: carType == 'Lady'
|
: carType == 'Lady'
|
||||||
? (i ~/ 60) +
|
? (i ~/ 60) *
|
||||||
|
(Get.find<HomeCaptainController>().latePrice + .5) *
|
||||||
|
2 +
|
||||||
(recentDistanceToDash *
|
(recentDistanceToDash *
|
||||||
Get.find<HomeCaptainController>().comfortPrice)
|
Get.find<HomeCaptainController>().comfortPrice)
|
||||||
: carType == 'Delivery'
|
: carType == 'RayehGaiComfort'
|
||||||
? (i ~/ 60) +
|
? (i ~/ 60) *
|
||||||
|
(Get.find<HomeCaptainController>().latePrice +
|
||||||
|
.5) *
|
||||||
|
2 +
|
||||||
(recentDistanceToDash *
|
(recentDistanceToDash *
|
||||||
Get.find<HomeCaptainController>().deliveryPrice)
|
Get.find<HomeCaptainController>().comfortPrice)
|
||||||
: carType == 'Rayeh Gai'
|
: (i ~/ 60) *
|
||||||
? (i ~/ 60) +
|
(Get.find<HomeCaptainController>().latePrice +
|
||||||
(recentDistanceToDash *
|
.5) *
|
||||||
Get.find<HomeCaptainController>().speedPrice)
|
2 +
|
||||||
: (i ~/ 60) +
|
(recentDistanceToDash *
|
||||||
(recentDistanceToDash *
|
Get.find<HomeCaptainController>().mashwariPrice);
|
||||||
Get.find<HomeCaptainController>()
|
}
|
||||||
.mashwariPrice); // $1 for each minute + $4 for each km
|
price = carType == 'Comfort' // || carType == 'Free Ride'
|
||||||
|
? (i ~/ 60) * (Get.find<HomeCaptainController>().latePrice + .5) +
|
||||||
|
(recentDistanceToDash *
|
||||||
|
Get.find<HomeCaptainController>().comfortPrice)
|
||||||
|
: carType == 'Lady'
|
||||||
|
? (i ~/ 60) *
|
||||||
|
(Get.find<HomeCaptainController>().latePrice + .5) +
|
||||||
|
(recentDistanceToDash *
|
||||||
|
Get.find<HomeCaptainController>().comfortPrice)
|
||||||
|
: carType == 'RayehGaiComfort'
|
||||||
|
? (i ~/ 60) *
|
||||||
|
(Get.find<HomeCaptainController>().latePrice + .5) +
|
||||||
|
(recentDistanceToDash *
|
||||||
|
Get.find<HomeCaptainController>().comfortPrice)
|
||||||
|
: (i ~/ 60) *
|
||||||
|
(Get.find<HomeCaptainController>().latePrice + .5) +
|
||||||
|
(recentDistanceToDash *
|
||||||
|
Get.find<HomeCaptainController>().mashwariPrice);
|
||||||
|
} else if (currentTime.hour >= 14 && currentTime.hour <= 17) {
|
||||||
|
price = carType == 'Comfort' // || carType == 'Free Ride'
|
||||||
|
? (i ~/ 60) * (Get.find<HomeCaptainController>().heavyPrice) +
|
||||||
|
(recentDistanceToDash *
|
||||||
|
Get.find<HomeCaptainController>().comfortPrice)
|
||||||
|
: carType == 'Lady'
|
||||||
|
? (i ~/ 60) * (Get.find<HomeCaptainController>().heavyPrice) +
|
||||||
|
(recentDistanceToDash *
|
||||||
|
Get.find<HomeCaptainController>().comfortPrice)
|
||||||
|
: carType == 'RayehGaiComfort'
|
||||||
|
? (i ~/ 60) *
|
||||||
|
(Get.find<HomeCaptainController>().heavyPrice) +
|
||||||
|
(recentDistanceToDash *
|
||||||
|
Get.find<HomeCaptainController>().comfortPrice)
|
||||||
|
: (i ~/ 60) *
|
||||||
|
(Get.find<HomeCaptainController>().heavyPrice) +
|
||||||
|
(recentDistanceToDash *
|
||||||
|
Get.find<HomeCaptainController>().mashwariPrice);
|
||||||
|
} else {
|
||||||
|
price = carType == 'Comfort' // || carType == 'Free Ride'
|
||||||
|
? (i ~/ 60) +
|
||||||
|
(recentDistanceToDash *
|
||||||
|
Get.find<HomeCaptainController>().comfortPrice)
|
||||||
|
: carType == 'Lady'
|
||||||
|
? (i ~/ 60) +
|
||||||
|
(recentDistanceToDash *
|
||||||
|
Get.find<HomeCaptainController>().comfortPrice)
|
||||||
|
: carType == 'RayehGaiComfort'
|
||||||
|
? (i ~/ 60) +
|
||||||
|
(recentDistanceToDash *
|
||||||
|
Get.find<HomeCaptainController>().comfortPrice)
|
||||||
|
: (i ~/ 60) +
|
||||||
|
(recentDistanceToDash *
|
||||||
|
Get.find<HomeCaptainController>().mashwariPrice);
|
||||||
|
}
|
||||||
|
// $1 for each minute + $4 for each km
|
||||||
price = (price * double.parse(kazan)) + price; // Add 10% tax
|
price = (price * double.parse(kazan)) + price; // Add 10% tax
|
||||||
speed = Get.find<LocationController>().speed * 3.6;
|
speed = Get.find<LocationController>().speed * 3.6;
|
||||||
progressTimerRideBegin = i / durationOfRide;
|
progressTimerRideBegin = i / durationOfRide;
|
||||||
|
|||||||
@@ -113,14 +113,16 @@ class MyTranslation extends Translations {
|
|||||||
"National Bank of Greece": "البنك الوطني اليوناني",
|
"National Bank of Greece": "البنك الوطني اليوناني",
|
||||||
"Central Bank Of Egypt": "البنك المركزي المصري",
|
"Central Bank Of Egypt": "البنك المركزي المصري",
|
||||||
"ATTIJARIWAFA BANK Egypt": "البنك التجاري وفا مصر",
|
"ATTIJARIWAFA BANK Egypt": "البنك التجاري وفا مصر",
|
||||||
"Morning Promo": "عرض الصباح",
|
"Morning Promo": "بونص الصباح",
|
||||||
|
"VIP Order": "طلب VIP", "VIP Order Accepted": "تم قبول طلب VIP.",
|
||||||
|
"The driver accepted your trip": "السائق قبل رحلتك.",
|
||||||
"this is count of your all trips in the morning promo today from 7:00am-10:00am":
|
"this is count of your all trips in the morning promo today from 7:00am-10:00am":
|
||||||
"هذا عدد جميع رحلاتك في عرض الصباح اليوم من الساعة 7:00 صباحًا حتى 10:00 صباحًا",
|
"هذا عدد جميع رحلاتك في بونص الصباح اليوم من الساعة 7:00 صباحًا حتى 10:00 صباحًا",
|
||||||
"Morning Promo Rides": "رحلات عرض الصباح",
|
"Morning Promo Rides": "رحلات عرض الصباح",
|
||||||
"Afternoon Promo": "عرض بعد الظهر",
|
"Afternoon Promo": "بونص الظهر",
|
||||||
"this is count of your all trips in the Afternoon promo today from 3:00pm-6:00 pm":
|
"this is count of your all trips in the Afternoon promo today from 3:00pm-6:00 pm":
|
||||||
"هذا عدد جميع رحلاتك في عرض بعد الظهر اليوم من الساعة 3:00 مساءً حتى 6:00 مساءً",
|
"هذا عدد جميع رحلاتك في بونص بعد الظهر اليوم من الساعة 3:00 مساءً حتى 6:00 مساءً",
|
||||||
"Afternoon Promo Rides": "رحلات عرض بعد الظهر",
|
"Afternoon Promo Rides": "رحلات بونص بعد الظهر",
|
||||||
"Heading your way now. Please be ready.":
|
"Heading your way now. Please be ready.":
|
||||||
"في طريقي إليك الآن. يرجى الاستعداد.",
|
"في طريقي إليك الآن. يرجى الاستعداد.",
|
||||||
"Approaching your area. Should be there in 3 minutes.":
|
"Approaching your area. Should be there in 3 minutes.":
|
||||||
|
|||||||
@@ -36,9 +36,12 @@ final PaymobPayment paymobPayment = PaymobPayment();
|
|||||||
final PaymobPaymentWallet paymobPaymentWallet = PaymobPaymentWallet();
|
final PaymobPaymentWallet paymobPaymentWallet = PaymobPaymentWallet();
|
||||||
DbSql sql = DbSql.instance;
|
DbSql sql = DbSql.instance;
|
||||||
|
|
||||||
|
final GlobalKey<NavigatorState> navigatorKey = GlobalKey<NavigatorState>();
|
||||||
|
|
||||||
@pragma('vm:entry-point')
|
@pragma('vm:entry-point')
|
||||||
Future<void> backgroundMessageHandler(RemoteMessage message) async {
|
Future<void> backgroundMessageHandler(RemoteMessage message) async {
|
||||||
await Firebase.initializeApp();
|
await Firebase.initializeApp();
|
||||||
|
|
||||||
if (Platform.isAndroid) {
|
if (Platform.isAndroid) {
|
||||||
if (message.notification != null && message.notification!.title != null) {
|
if (message.notification != null && message.notification!.title != null) {
|
||||||
if (message.notification?.title == 'Order' ||
|
if (message.notification?.title == 'Order' ||
|
||||||
@@ -47,7 +50,7 @@ Future<void> backgroundMessageHandler(RemoteMessage message) async {
|
|||||||
Log.print('myListString: $myListString');
|
Log.print('myListString: $myListString');
|
||||||
|
|
||||||
// Decode the JSON string to a list
|
// Decode the JSON string to a list
|
||||||
var myList;
|
List<dynamic> myList;
|
||||||
try {
|
try {
|
||||||
myList = jsonDecode(myListString) as List<dynamic>;
|
myList = jsonDecode(myListString) as List<dynamic>;
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
@@ -55,7 +58,7 @@ Future<void> backgroundMessageHandler(RemoteMessage message) async {
|
|||||||
myList = [];
|
myList = [];
|
||||||
}
|
}
|
||||||
|
|
||||||
Future.delayed(const Duration(seconds: 1));
|
await Future.delayed(const Duration(seconds: 1));
|
||||||
NotificationController().showNotification(
|
NotificationController().showNotification(
|
||||||
message.notification!.title.toString(),
|
message.notification!.title.toString(),
|
||||||
message.notification!.body.toString(),
|
message.notification!.body.toString(),
|
||||||
@@ -67,6 +70,7 @@ Future<void> backgroundMessageHandler(RemoteMessage message) async {
|
|||||||
if (isOverlayActive) {
|
if (isOverlayActive) {
|
||||||
await FlutterOverlayWindow.closeOverlay();
|
await FlutterOverlayWindow.closeOverlay();
|
||||||
}
|
}
|
||||||
|
|
||||||
await FlutterOverlayWindow.showOverlay(
|
await FlutterOverlayWindow.showOverlay(
|
||||||
enableDrag: true,
|
enableDrag: true,
|
||||||
flag: OverlayFlag.focusPointer,
|
flag: OverlayFlag.focusPointer,
|
||||||
@@ -78,8 +82,6 @@ Future<void> backgroundMessageHandler(RemoteMessage message) async {
|
|||||||
);
|
);
|
||||||
|
|
||||||
await FlutterOverlayWindow.shareData(myList);
|
await FlutterOverlayWindow.shareData(myList);
|
||||||
|
|
||||||
// Bubble().startBubbleHead(sendAppToBackground: true);
|
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
FirebaseMessagesController().fireBaseTitles(message);
|
FirebaseMessagesController().fireBaseTitles(message);
|
||||||
@@ -87,8 +89,6 @@ Future<void> backgroundMessageHandler(RemoteMessage message) async {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
final GlobalKey<NavigatorState> navigatorKey = GlobalKey<NavigatorState>();
|
|
||||||
|
|
||||||
@pragma('vm:entry-point')
|
@pragma('vm:entry-point')
|
||||||
void overlayMain() async {
|
void overlayMain() async {
|
||||||
WidgetsFlutterBinding.ensureInitialized();
|
WidgetsFlutterBinding.ensureInitialized();
|
||||||
@@ -105,21 +105,18 @@ void closeOverLay() {
|
|||||||
|
|
||||||
void main() async {
|
void main() async {
|
||||||
WidgetsFlutterBinding.ensureInitialized();
|
WidgetsFlutterBinding.ensureInitialized();
|
||||||
WakelockPlus.enable();
|
await WakelockPlus.enable();
|
||||||
// Request location permission first
|
|
||||||
|
// Request location permission
|
||||||
PermissionStatus status = await Permission.location.request();
|
PermissionStatus status = await Permission.location.request();
|
||||||
if (status.isDenied) {
|
if (status.isDenied) {
|
||||||
WidgetsBinding.instance.addPostFrameCallback((_) {
|
WidgetsBinding.instance.addPostFrameCallback((_) {
|
||||||
getPermissionLocation();
|
getPermissionLocation();
|
||||||
});
|
});
|
||||||
// Handle the case when permission is denied
|
|
||||||
// You might want to show a dialog explaining why the permission is needed
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
// Set up the overlay entry point
|
|
||||||
// FlutterOverlayWindow.overlayMain = overlayMain;
|
|
||||||
await LocationController().startLocationUpdates();
|
|
||||||
|
|
||||||
|
await LocationController().startLocationUpdates();
|
||||||
await GetStorage.init();
|
await GetStorage.init();
|
||||||
Stripe.publishableKey = AK.publishableKeyStripe;
|
Stripe.publishableKey = AK.publishableKeyStripe;
|
||||||
|
|
||||||
@@ -131,12 +128,12 @@ void main() async {
|
|||||||
|
|
||||||
FirebaseMessaging.onBackgroundMessage(backgroundMessageHandler);
|
FirebaseMessaging.onBackgroundMessage(backgroundMessageHandler);
|
||||||
NotificationController().initNotifications();
|
NotificationController().initNotifications();
|
||||||
List<Future> initializationTasks = [
|
|
||||||
|
await Future.wait([
|
||||||
FirebaseMessagesController().getNotificationSettings(),
|
FirebaseMessagesController().getNotificationSettings(),
|
||||||
FirebaseMessagesController().getToken(),
|
FirebaseMessagesController().getToken(),
|
||||||
];
|
]);
|
||||||
|
|
||||||
await Future.wait(initializationTasks);
|
|
||||||
SystemChrome.setPreferredOrientations([
|
SystemChrome.setPreferredOrientations([
|
||||||
DeviceOrientation.portraitUp,
|
DeviceOrientation.portraitUp,
|
||||||
DeviceOrientation.portraitDown,
|
DeviceOrientation.portraitDown,
|
||||||
@@ -160,8 +157,6 @@ void main() async {
|
|||||||
}
|
}
|
||||||
|
|
||||||
class MyApp extends StatelessWidget {
|
class MyApp extends StatelessWidget {
|
||||||
MyApp({super.key});
|
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
LocaleController localController = Get.put(LocaleController());
|
LocaleController localController = Get.put(LocaleController());
|
||||||
@@ -172,18 +167,14 @@ class MyApp extends StatelessWidget {
|
|||||||
debugShowCheckedModeBanner: false,
|
debugShowCheckedModeBanner: false,
|
||||||
locale: localController.language,
|
locale: localController.language,
|
||||||
theme: localController.appTheme,
|
theme: localController.appTheme,
|
||||||
key: UniqueKey(),
|
|
||||||
initialRoute: '/',
|
initialRoute: '/',
|
||||||
// home: SplashScreen(),
|
|
||||||
routes: {
|
|
||||||
'/order': (context) => OrderRequestPage(),
|
|
||||||
},
|
|
||||||
getPages: [
|
getPages: [
|
||||||
GetPage(name: '/', page: () => SplashScreen()),
|
GetPage(name: '/', page: () => SplashScreen()),
|
||||||
GetPage(
|
GetPage(
|
||||||
name: '/order-page',
|
name: '/order-page',
|
||||||
page: () => OrderRequestPage(),
|
page: () => OrderRequestPage(),
|
||||||
arguments: box.read(BoxName.rideArguments)),
|
arguments: box.read(BoxName.rideArguments),
|
||||||
|
),
|
||||||
],
|
],
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -9,6 +9,7 @@ import 'package:SEFER/controller/home/captin/home_captain_controller.dart';
|
|||||||
import 'package:google_maps_flutter/google_maps_flutter.dart';
|
import 'package:google_maps_flutter/google_maps_flutter.dart';
|
||||||
|
|
||||||
import '../../../../../constant/colors.dart';
|
import '../../../../../constant/colors.dart';
|
||||||
|
import '../../../../../constant/links.dart';
|
||||||
import '../../../../../controller/firebase/firbase_messge.dart';
|
import '../../../../../controller/firebase/firbase_messge.dart';
|
||||||
import '../../../../../print.dart';
|
import '../../../../../print.dart';
|
||||||
import '../../../../Rate/ride_calculate_driver.dart';
|
import '../../../../Rate/ride_calculate_driver.dart';
|
||||||
@@ -270,34 +271,35 @@ GetBuilder<HomeCaptainController> leftMainMenuCaptainIcons() {
|
|||||||
// );
|
// );
|
||||||
// }),
|
// }),
|
||||||
// ),
|
// ),
|
||||||
// AnimatedContainer(
|
AnimatedContainer(
|
||||||
// duration: const Duration(microseconds: 200),
|
duration: const Duration(microseconds: 200),
|
||||||
// width: controller.widthMapTypeAndTraffic,
|
width: controller.widthMapTypeAndTraffic,
|
||||||
// decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
// color: AppColor.secondaryColor,
|
color: AppColor.secondaryColor,
|
||||||
// border: Border.all(color: AppColor.blueColor),
|
border: Border.all(color: AppColor.blueColor),
|
||||||
// borderRadius: BorderRadius.circular(15)),
|
borderRadius: BorderRadius.circular(15)),
|
||||||
// child: Builder(builder: (context) {
|
child: Builder(builder: (context) {
|
||||||
// return IconButton(
|
return IconButton(
|
||||||
// onPressed: () async {
|
onPressed: () async {
|
||||||
// FirebaseMessagesController().sendNotificationToAnyWithoutData(
|
// FirebaseMessagesController().sendNotificationToAnyWithoutData(
|
||||||
// 'Order'.tr,
|
// 'Order'.tr,
|
||||||
// 'from: ',
|
// 'from: ',
|
||||||
// // jsonDecode(value)['message'].toString(),
|
// // jsonDecode(value)['message'].toString(),
|
||||||
// 'dEugS-JOT4Ka5riF4s5TEN:APA91bEDL_W7BuEQGbyL-RMaKiMWDlURXhFuaybe5WurTUV8K5eIooSGe22yY22_U2hEZcfPr46ig1v--l00dbOGiivazxvmTyhUyQQW6lJsuIN-wordGtBxtREyeYtEKvxIa1J4ApEu',
|
// 'dEugS-JOT4Ka5riF4s5TEN:APA91bEDL_W7BuEQGbyL-RMaKiMWDlURXhFuaybe5WurTUV8K5eIooSGe22yY22_U2hEZcfPr46ig1v--l00dbOGiivazxvmTyhUyQQW6lJsuIN-wordGtBxtREyeYtEKvxIa1J4ApEu',
|
||||||
// 'order.wav'
|
// 'order.wav'
|
||||||
|
|
||||||
// // polylineCoordinates.toString()
|
// // polylineCoordinates.toString()
|
||||||
// );
|
// );
|
||||||
// },
|
print(AppLink.addDriverPaymentPoints);
|
||||||
// icon: const Icon(
|
},
|
||||||
// FontAwesome5.closed_captioning,
|
icon: const Icon(
|
||||||
// size: 29,
|
FontAwesome5.closed_captioning,
|
||||||
// color: AppColor.blueColor,
|
size: 29,
|
||||||
// ),
|
color: AppColor.blueColor,
|
||||||
// );
|
),
|
||||||
// }),
|
);
|
||||||
// ),
|
}),
|
||||||
|
),
|
||||||
],
|
],
|
||||||
)),
|
)),
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -63,7 +63,8 @@ GetBuilder<MapDriverController> driverEndRideBar() {
|
|||||||
)
|
)
|
||||||
: const SizedBox(),
|
: const SizedBox(),
|
||||||
mapDriverController.carType != 'Speed' &&
|
mapDriverController.carType != 'Speed' &&
|
||||||
mapDriverController.carType != 'Delivery'
|
mapDriverController.carType != 'Delivery' &&
|
||||||
|
mapDriverController.carType != 'Balash'
|
||||||
? Row(
|
? Row(
|
||||||
mainAxisAlignment: MainAxisAlignment.spaceAround,
|
mainAxisAlignment: MainAxisAlignment.spaceAround,
|
||||||
children: [
|
children: [
|
||||||
|
|||||||
16
lib/views/home/Captin/orderCaptin/vip_order_page.dart
Normal file
16
lib/views/home/Captin/orderCaptin/vip_order_page.dart
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
import 'package:SEFER/views/widgets/my_scafold.dart';
|
||||||
|
import 'package:flutter/material.dart';
|
||||||
|
import 'package:get/get.dart';
|
||||||
|
|
||||||
|
class VipOrderPage extends StatelessWidget {
|
||||||
|
const VipOrderPage({super.key});
|
||||||
|
|
||||||
|
@override
|
||||||
|
Widget build(BuildContext context) {
|
||||||
|
return MyScafolld(
|
||||||
|
title: 'VIP Order'.tr,
|
||||||
|
body: [],
|
||||||
|
isleading: true,
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -398,26 +398,26 @@ class WalletCaptain extends StatelessWidget {
|
|||||||
|
|
||||||
GetBuilder<CaptainWalletController>(
|
GetBuilder<CaptainWalletController>(
|
||||||
builder: (captainWalletController) {
|
builder: (captainWalletController) {
|
||||||
return Padding(
|
return InkWell(
|
||||||
padding: const EdgeInsets.all(8.0),
|
onTap: () {
|
||||||
child: Row(
|
MyDialog().getDialog(
|
||||||
children: [
|
'Morning Promo'.tr,
|
||||||
SizedBox(
|
"this is count of your all trips in the morning promo today from 7:00am-10:00am"
|
||||||
width: Get.width * .9,
|
.tr, () {
|
||||||
// height: Get.height * .1,
|
Get.back();
|
||||||
// decoration: AppStyle.boxDecoration,
|
});
|
||||||
child: Stack(
|
},
|
||||||
children: [
|
child: Padding(
|
||||||
InkWell(
|
padding: const EdgeInsets.all(8.0),
|
||||||
onTap: () {
|
child: Row(
|
||||||
MyDialog().getDialog(
|
children: [
|
||||||
'Morning Promo'.tr,
|
SizedBox(
|
||||||
"this is count of your all trips in the morning promo today from 7:00am-10:00am"
|
width: Get.width * .9,
|
||||||
.tr, () {
|
// height: Get.height * .1,
|
||||||
Get.back();
|
// decoration: AppStyle.boxDecoration,
|
||||||
});
|
child: Stack(
|
||||||
},
|
children: [
|
||||||
child: LinearProgressIndicator(
|
LinearProgressIndicator(
|
||||||
minHeight: 35,
|
minHeight: 35,
|
||||||
color: AppColor.blueColor,
|
color: AppColor.blueColor,
|
||||||
borderRadius:
|
borderRadius:
|
||||||
@@ -431,53 +431,53 @@ class WalletCaptain extends StatelessWidget {
|
|||||||
.toString()) /
|
.toString()) /
|
||||||
5,
|
5,
|
||||||
),
|
),
|
||||||
),
|
Row(
|
||||||
Row(
|
mainAxisAlignment:
|
||||||
mainAxisAlignment:
|
MainAxisAlignment.center,
|
||||||
MainAxisAlignment.center,
|
children: <Widget>[
|
||||||
children: <Widget>[
|
Text(
|
||||||
Text(
|
'Morning Promo Rides'.tr,
|
||||||
'Morning Promo Rides'.tr,
|
style: AppStyle.title,
|
||||||
style: AppStyle.title,
|
),
|
||||||
),
|
const SizedBox(
|
||||||
const SizedBox(
|
width: 20,
|
||||||
width: 20,
|
),
|
||||||
),
|
Text(
|
||||||
Text(
|
'${captainWalletController.walletDate['message'][0]['morning_count']} / 5',
|
||||||
'${captainWalletController.walletDate['message'][0]['morning_count']} / 5',
|
style: AppStyle.title,
|
||||||
style: AppStyle.title,
|
),
|
||||||
),
|
],
|
||||||
],
|
),
|
||||||
),
|
],
|
||||||
],
|
),
|
||||||
),
|
)
|
||||||
)
|
],
|
||||||
],
|
),
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
}),
|
}),
|
||||||
GetBuilder<CaptainWalletController>(
|
GetBuilder<CaptainWalletController>(
|
||||||
builder: (captainWalletController) {
|
builder: (captainWalletController) {
|
||||||
return Padding(
|
return InkWell(
|
||||||
padding: const EdgeInsets.all(8.0),
|
onTap: () {
|
||||||
child: Row(
|
MyDialog().getDialog(
|
||||||
children: [
|
'Afternoon Promo'.tr,
|
||||||
SizedBox(
|
"this is count of your all trips in the Afternoon promo today from 3:00pm-6:00 pm"
|
||||||
width: Get.width * .9,
|
.tr, () {
|
||||||
// height: Get.height * .1,
|
Get.back();
|
||||||
// decoration: AppStyle.boxDecoration,
|
});
|
||||||
child: Stack(
|
},
|
||||||
children: [
|
child: Padding(
|
||||||
InkWell(
|
padding: const EdgeInsets.all(8.0),
|
||||||
onTap: () {
|
child: Row(
|
||||||
MyDialog().getDialog(
|
children: [
|
||||||
'Afternoon Promo'.tr,
|
SizedBox(
|
||||||
"this is count of your all trips in the Afternoon promo today from 3:00pm-6:00 pm"
|
width: Get.width * .9,
|
||||||
.tr, () {
|
// height: Get.height * .1,
|
||||||
Get.back();
|
// decoration: AppStyle.boxDecoration,
|
||||||
});
|
child: Stack(
|
||||||
},
|
children: [
|
||||||
child: LinearProgressIndicator(
|
LinearProgressIndicator(
|
||||||
minHeight: 35,
|
minHeight: 35,
|
||||||
color: AppColor.blueColor,
|
color: AppColor.blueColor,
|
||||||
borderRadius:
|
borderRadius:
|
||||||
@@ -491,28 +491,28 @@ class WalletCaptain extends StatelessWidget {
|
|||||||
.toString()) /
|
.toString()) /
|
||||||
5,
|
5,
|
||||||
),
|
),
|
||||||
),
|
Row(
|
||||||
Row(
|
mainAxisAlignment:
|
||||||
mainAxisAlignment:
|
MainAxisAlignment.center,
|
||||||
MainAxisAlignment.center,
|
children: <Widget>[
|
||||||
children: <Widget>[
|
Text(
|
||||||
Text(
|
'Afternoon Promo Rides'.tr,
|
||||||
'Afternoon Promo Rides'.tr,
|
style: AppStyle.title,
|
||||||
style: AppStyle.title,
|
),
|
||||||
),
|
const SizedBox(
|
||||||
const SizedBox(
|
width: 20,
|
||||||
width: 20,
|
),
|
||||||
),
|
Text(
|
||||||
Text(
|
'${captainWalletController.walletDate['message'][0]['afternoon_count']} / 5',
|
||||||
'${captainWalletController.walletDate['message'][0]['afternoon_count']} / 5',
|
style: AppStyle.title,
|
||||||
style: AppStyle.title,
|
),
|
||||||
),
|
],
|
||||||
],
|
),
|
||||||
),
|
],
|
||||||
],
|
),
|
||||||
),
|
)
|
||||||
)
|
],
|
||||||
],
|
),
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
}),
|
}),
|
||||||
|
|||||||
@@ -37,15 +37,16 @@ class MyDialog extends GetxController {
|
|||||||
),
|
),
|
||||||
actions: [
|
actions: [
|
||||||
CupertinoDialogAction(
|
CupertinoDialogAction(
|
||||||
child: Text('Cancel', style: TextStyle(color: AppColor.redColor)),
|
child: const Text('Cancel',
|
||||||
|
style: TextStyle(color: AppColor.redColor)),
|
||||||
onPressed: () {
|
onPressed: () {
|
||||||
Get.back();
|
Get.back();
|
||||||
},
|
},
|
||||||
),
|
),
|
||||||
CupertinoDialogAction(
|
CupertinoDialogAction(
|
||||||
child:
|
|
||||||
Text('OK'.tr, style: TextStyle(color: AppColor.greenColor)),
|
|
||||||
onPressed: onPressed,
|
onPressed: onPressed,
|
||||||
|
child: Text('OK'.tr,
|
||||||
|
style: const TextStyle(color: AppColor.greenColor)),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
@@ -84,15 +85,16 @@ class MyDialogContent extends GetxController {
|
|||||||
),
|
),
|
||||||
actions: [
|
actions: [
|
||||||
CupertinoDialogAction(
|
CupertinoDialogAction(
|
||||||
child: Text('Cancel', style: TextStyle(color: AppColor.redColor)),
|
child: const Text('Cancel',
|
||||||
|
style: TextStyle(color: AppColor.redColor)),
|
||||||
onPressed: () {
|
onPressed: () {
|
||||||
Get.back();
|
Get.back();
|
||||||
},
|
},
|
||||||
),
|
),
|
||||||
CupertinoDialogAction(
|
CupertinoDialogAction(
|
||||||
child:
|
|
||||||
Text('OK'.tr, style: TextStyle(color: AppColor.greenColor)),
|
|
||||||
onPressed: onPressed,
|
onPressed: onPressed,
|
||||||
|
child: Text('OK'.tr,
|
||||||
|
style: const TextStyle(color: AppColor.greenColor)),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
|
|||||||
Reference in New Issue
Block a user