7/5/4
This commit is contained in:
56
.env
56
.env
@@ -39,8 +39,62 @@ payMobOutClientSecrret='xyjjRlahJM0Xc38WjApCOh8bvgL9slFpNdM9YeCu9AhLqboKMPtmSvc2
|
||||
payMobOutClient_id='Z05ut48dVkS2gI2zenFFcKsfDKfHAU0WELqKyJ0LXrXlBl'
|
||||
payMobOutPassword='D2zJFxkE#LN3vz38z2dYxpNfWXrXlBl'
|
||||
payMobOutUserName='zjujl_qvo_fwjfgjlXrXlBl'
|
||||
keyOfApp=nqryjp@1737wqnmqqsjyzjujljksvceiXrXlBl
|
||||
|
||||
|
||||
a= q
|
||||
b= x
|
||||
c= f
|
||||
d= y
|
||||
e= j
|
||||
f= u
|
||||
g= k
|
||||
h= w
|
||||
i= o
|
||||
j= e
|
||||
k= g
|
||||
l= r
|
||||
m= n
|
||||
n= b
|
||||
o= i
|
||||
p= v
|
||||
q= a
|
||||
r= l
|
||||
s= z
|
||||
t= c
|
||||
u= h
|
||||
v= p
|
||||
w= t
|
||||
x= d
|
||||
y= s
|
||||
z= m
|
||||
|
||||
A= Q
|
||||
B= X
|
||||
C= F
|
||||
D= Y
|
||||
E= J
|
||||
F= U
|
||||
G= K
|
||||
H= W
|
||||
I= O
|
||||
J= E
|
||||
K= G
|
||||
L= R
|
||||
M= N
|
||||
N= B
|
||||
O= I
|
||||
P= V
|
||||
Q= A
|
||||
R= L
|
||||
S= Z
|
||||
T= C
|
||||
U= H
|
||||
V= P
|
||||
W= T
|
||||
X= D
|
||||
Y= S
|
||||
Z= M
|
||||
#
|
||||
#basicAuthCredentials= q9XDwNb2SWHU9nq0tIqWYIN+bvXt54jPVrBFOZUstsnk3Ndz2BOSI3wLC3GKMuqE
|
||||
#basicCompareFaces= ZK2RkvTEAi0ihtR0GuJ+H2bmU1OVn5V/f9NLVoKZZdE=
|
||||
@@ -58,7 +112,7 @@ payMobOutUserName='zjujl_qvo_fwjfgjlXrXlBl'
|
||||
#secretKey= PNwYqtlLcDMlmKbzy3++wSPC/XB9WX2t+zfrJDsYz7LXD5jVFUGs3CXUF227VDGPe1sk10yMGLM4E818969GF7/qhZjLzwF8qXLAEpUhtGniQ+undfoiJw2vNfB4lXWKgQQC4N+/6KPb7zSZx8o8yVlvL/5iZiuf1LYhUhjJmJE=
|
||||
#stripe_publishableKe= gyXxuOp+vaGcRTTBohZeTaK7HEhpNUVvWGcBNABhzHu125y6ftOwvf1Z8fYlfaG/ysClJpqfxBU8+RulI7KhtJM5mVrmALFiypv/6IlkACsundM6zkbxQGHzjfQdrfkdFZF00fpYjOI/3P/znZIlKGYYLmdxUqF3chAfYDet1/I=
|
||||
#llamaKey= a3oCdxMeaKjatKyLQEnPMLqFmfLe9mCGRofsROVQ6NF7SCqxOt7h2A/KvdYWGBM42SxNTuWIq5+UsnPulqKbd3yVTRnG+Lx0rxPa+9mc48frICnl+hz6CSmJjOjDhHnE
|
||||
#serverPHP= blf8gn/gV8/mvMZlPdJMnSu+ATBZfBThpVjNb9mzXT7OfBrBSZnCBxveUsCcXUW3
|
||||
#serverPHP= bWjMqX8G7gUyLhrQ85zAXSe2YLffF62PaPHyYK1WcQTPTjcj2+sRswzOU1XPVu+n
|
||||
#cohere= SvRbfrRc+Gyyy20otHDz1cNNcQpoMyLm+TIkTyfZI7vnxkgsEYiGdYOJ0Punkz6JdY4qa3B0fu2OCZ7NOa6Y1w==
|
||||
#claudeAiAPI= oO1ZcIFPBgin9gQs5vNT/oDs0KpJDVnjwXqKjCAABoezFxLUpAMINvSNruW7DFU2mbsjpJTDwpTzddsMCIPqi7AjzBpW6X1ddxYX+ZPuJ55Kymj5KvTHAwYYhW7F3l9sOjrtODWwhH6uGTNfh3Ftz531Xb2Qr5d3rKDC4H5tkFM=
|
||||
#payPalClientId= VmMsEn1Kz4wCqCnWOm+XoUE2k2c7wA9y2cHqe303GSR9HfnuDqpbcijBYDs5EGYsYF/t68M1xlAp1OX+oXSN3RSsjKelJmbbreg8YtjTeErMVOSGHrsOHRY7hqlUYvmN8DUTlRTFvIdTX+RafY2LiA==
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
<key>CFBundlePackageType</key>
|
||||
<string>APPL</string>
|
||||
<key>CFBundleShortVersionString</key>
|
||||
<string>45</string>
|
||||
<string>46</string>
|
||||
<key>CFBundleSignature</key>
|
||||
<string>????</string>
|
||||
<key>CFBundleURLTypes</key>
|
||||
@@ -36,7 +36,7 @@
|
||||
</dict>
|
||||
</array>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>4.0.45</string>
|
||||
<string>4.0.46</string>
|
||||
<key>FirebaseAppDelegateProxyEnabled</key>
|
||||
<string>NO</string>
|
||||
<key>GMSApiKey</key>
|
||||
|
||||
@@ -68,6 +68,9 @@ class AK {
|
||||
a.r(a.r(a.r(Env.payMobOutPassword, cn), cC), cs);
|
||||
static final String payMobOutUserName =
|
||||
a.r(a.r(a.r(Env.payMobOutUserName, cn), cC), cs);
|
||||
|
||||
/////////////
|
||||
static final String keyOfApp = a.r(a.r(a.r(Env.keyOfApp, cn), cC), cs);
|
||||
}
|
||||
|
||||
//
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
import 'package:SEFER/env/env.dart';
|
||||
|
||||
Map<String, String> cn = {
|
||||
"0": "3",
|
||||
"1": "7",
|
||||
@@ -11,58 +13,58 @@ Map<String, String> cn = {
|
||||
"9": "8"
|
||||
};
|
||||
Map<String, String> cs = {
|
||||
"a": "q",
|
||||
"b": "x",
|
||||
"c": "f",
|
||||
"d": "y",
|
||||
"e": "j",
|
||||
"f": "u",
|
||||
"g": "k",
|
||||
"h": "w",
|
||||
"i": "o",
|
||||
"j": "e",
|
||||
"k": "g",
|
||||
"l": "r",
|
||||
"m": "n",
|
||||
"n": "b",
|
||||
"o": "i",
|
||||
"p": "v",
|
||||
"q": "a",
|
||||
"r": "l",
|
||||
"s": "z",
|
||||
"t": "c",
|
||||
"u": "h",
|
||||
"v": "p",
|
||||
"w": "t",
|
||||
"x": "d",
|
||||
"y": "s",
|
||||
"z": "m"
|
||||
"a": Env.a,
|
||||
"b": Env.b,
|
||||
"c": Env.c,
|
||||
"d": Env.d,
|
||||
"e": Env.e,
|
||||
"f": Env.f,
|
||||
"g": Env.g,
|
||||
"h": Env.h,
|
||||
"i": Env.i,
|
||||
"j": Env.j,
|
||||
"k": Env.k,
|
||||
"l": Env.l,
|
||||
"m": Env.m,
|
||||
"n": Env.n,
|
||||
"o": Env.o,
|
||||
"p": Env.p,
|
||||
"q": Env.q,
|
||||
"r": Env.r,
|
||||
"s": Env.s,
|
||||
"t": Env.t,
|
||||
"u": Env.u,
|
||||
"v": Env.v,
|
||||
"w": Env.w,
|
||||
"x": Env.x,
|
||||
"y": Env.y,
|
||||
"z": Env.z,
|
||||
};
|
||||
Map<String, String> cC = {
|
||||
"A": "Q",
|
||||
"B": "X",
|
||||
"C": "F",
|
||||
"D": "Y",
|
||||
"E": "J",
|
||||
"F": "U",
|
||||
"G": "K",
|
||||
"H": "W",
|
||||
"I": "O",
|
||||
"J": "E",
|
||||
"K": "G",
|
||||
"L": "R",
|
||||
"M": "N",
|
||||
"N": "B",
|
||||
"O": "I",
|
||||
"P": "V",
|
||||
"Q": "A",
|
||||
"R": "L",
|
||||
"S": "Z",
|
||||
"T": "C",
|
||||
"U": "H",
|
||||
"V": "P",
|
||||
"W": "T",
|
||||
"X": "D",
|
||||
"Y": "S",
|
||||
"Z": "M"
|
||||
"A": Env.A,
|
||||
"B": Env.B,
|
||||
"C": Env.C,
|
||||
"D": Env.D,
|
||||
"E": Env.E,
|
||||
"F": Env.F,
|
||||
"G": Env.G,
|
||||
"H": Env.H,
|
||||
"I": Env.I,
|
||||
"J": Env.J,
|
||||
"K": Env.K,
|
||||
"L": Env.L,
|
||||
"M": Env.M,
|
||||
"N": Env.N,
|
||||
"O": Env.O,
|
||||
"P": Env.P,
|
||||
"Q": Env.Q,
|
||||
"R": Env.R,
|
||||
"S": Env.S,
|
||||
"T": Env.T,
|
||||
"U": Env.U,
|
||||
"V": Env.V,
|
||||
"W": Env.W,
|
||||
"X": Env.X,
|
||||
"Y": Env.Y,
|
||||
"Z": Env.Z
|
||||
};
|
||||
|
||||
@@ -12,7 +12,7 @@ class AC {
|
||||
if (box.read(BoxName.apiKeyRun).toString() != 'run') {
|
||||
var res = await CRUD().get(link: AppLink.getApiKey, payload: {});
|
||||
var decod = jsonDecode(res);
|
||||
print(decod);
|
||||
// print(decod);
|
||||
Map<String, dynamic> jsonData = {};
|
||||
for (var i = 0; i < decod['message'].length; i++) {
|
||||
String h = decod['message'][i]['hashed_key'].toString();
|
||||
|
||||
@@ -1,14 +1,14 @@
|
||||
class AppInformation {
|
||||
static const String companyName = 'Mobile-App';
|
||||
static const String companyName = 'SEFER LLC';
|
||||
static const String appName = 'SEFER';
|
||||
static const String appVersion = 'SEFER Captain';
|
||||
static const String phoneNumber = '962798583052';
|
||||
static const String linkedInProfile =
|
||||
'https://www.linkedin.com/in/hamza-ayed/';
|
||||
static const String website = 'https://mobile-app.store';
|
||||
static const String email = 'hamzaayed@mobile-app.store';
|
||||
static const String website = 'https://sefer.live';
|
||||
static const String email = 'hamzaayed@sefer.live';
|
||||
|
||||
static const String privacyPolicy =
|
||||
'''
|
||||
static const String privacyPolicy = '''
|
||||
|
||||
<body monica-version="2.4.0" monica-id="ofpnmcalabcbjgholdjcjblkibolbppb">
|
||||
|
||||
|
||||
@@ -206,6 +206,7 @@ class AppLink {
|
||||
static String authCaptin = '$server/auth/captin';
|
||||
static String loginCaptin = "$authCaptin/login.php";
|
||||
static String loginFromGoogleCaptin = "$authCaptin/loginFromGoogle.php";
|
||||
static String packageInfo = "$server/auth/packageInfo.php";
|
||||
static String signUpCaptin = "$authCaptin/register.php";
|
||||
static String sendVerifyEmailCaptin = "$authCaptin/sendVerifyEmail.php";
|
||||
static String sendVerifyOtpMessage =
|
||||
|
||||
@@ -42,9 +42,9 @@ class AppStyle {
|
||||
static BoxDecoration boxDecoration = const BoxDecoration(
|
||||
boxShadow: [
|
||||
BoxShadow(
|
||||
color: AppColor.accentColor, blurRadius: 5, offset: Offset(2, 4)),
|
||||
color: AppColor.accentColor, blurRadius: 2, offset: Offset(1, 2)),
|
||||
BoxShadow(
|
||||
color: AppColor.accentColor, blurRadius: 5, offset: Offset(-2, -2))
|
||||
color: AppColor.accentColor, blurRadius: 2, offset: Offset(-1, -1))
|
||||
],
|
||||
color: AppColor.secondaryColor,
|
||||
borderRadius: BorderRadius.all(
|
||||
@@ -53,9 +53,9 @@ class AppStyle {
|
||||
static BoxDecoration boxDecoration1 = const BoxDecoration(
|
||||
boxShadow: [
|
||||
BoxShadow(
|
||||
color: AppColor.accentColor, blurRadius: 5, offset: Offset(2, 4)),
|
||||
color: AppColor.accentColor, blurRadius: 2, offset: Offset(1, 2)),
|
||||
BoxShadow(
|
||||
color: AppColor.accentColor, blurRadius: 5, offset: Offset(-2, -2))
|
||||
color: AppColor.accentColor, blurRadius: 2, offset: Offset(-1, -1))
|
||||
],
|
||||
color: AppColor.secondaryColor,
|
||||
borderRadius: BorderRadius.all(
|
||||
|
||||
@@ -1,21 +1,19 @@
|
||||
import 'package:encrypt/encrypt.dart' as encrypt;
|
||||
import 'dart:convert';
|
||||
import 'package:http/http.dart' as http;
|
||||
import 'package:encrypt/encrypt.dart' as encrypt;
|
||||
|
||||
//
|
||||
import 'dart:convert';
|
||||
import 'dart:math';
|
||||
import 'package:encrypt/encrypt.dart' as encrypt;
|
||||
import '../../constant/api_key.dart';
|
||||
|
||||
class KeyEncryption {
|
||||
static final _key = encrypt.Key.fromUtf8('mehmetDEV@2101'); // ضع مفتاحك هنا
|
||||
// استخدم مفتاح بطول 32 حرفًا
|
||||
static final _key = encrypt.Key.fromUtf8(AK.keyOfApp);
|
||||
static final _iv =
|
||||
encrypt.IV.fromLength(16); // توليد تهيئة عشوائية بطول 16 بايت
|
||||
|
||||
static String encryptKey(String key) {
|
||||
final iv = encrypt.IV.fromLength(16); // توليد تهيئة عشوائية
|
||||
final encrypter =
|
||||
encrypt.Encrypter(encrypt.AES(_key, mode: encrypt.AESMode.cbc));
|
||||
final encrypted = encrypter.encrypt(key, iv: iv);
|
||||
final result = iv.bytes + encrypted.bytes; // تضمين التهيئة مع النص المشفر
|
||||
final encrypted = encrypter.encrypt(key, iv: _iv);
|
||||
final result = _iv.bytes + encrypted.bytes; // تضمين التهيئة مع النص المشفر
|
||||
return base64Encode(result);
|
||||
}
|
||||
|
||||
@@ -29,55 +27,3 @@ class KeyEncryption {
|
||||
return encrypter.decrypt(encrypted, iv: iv);
|
||||
}
|
||||
}
|
||||
|
||||
// class KeyEncryption {
|
||||
// static final _key = encrypt.Key.fromUtf8('7'); // ضع مفتاحك هنا
|
||||
//
|
||||
// static String encryptKey(String key) {
|
||||
// final iv = encrypt.IV.fromLength(16); // توليد تهيئة عشوائية
|
||||
// final encrypter =
|
||||
// encrypt.Encrypter(encrypt.AES(_key, mode: encrypt.AESMode.cbc));
|
||||
// final encrypted = encrypter.encrypt(key, iv: iv);
|
||||
// final result = iv.bytes + encrypted.bytes; // تضمين التهيئة مع النص المشفر
|
||||
// return base64Encode(result);
|
||||
// }
|
||||
//
|
||||
// static String decryptKey(String encryptedKey) {
|
||||
// final decoded = base64Decode(encryptedKey);
|
||||
// final iv = encrypt.IV(decoded.sublist(0, 16)); // استخراج التهيئة
|
||||
// final encrypted =
|
||||
// encrypt.Encrypted(decoded.sublist(16)); // استخراج النص المشفر
|
||||
// final encrypter =
|
||||
// encrypt.Encrypter(encrypt.AES(_key, mode: encrypt.AESMode.cbc));
|
||||
// return encrypter.decrypt(encrypted, iv: iv);
|
||||
// }
|
||||
// }
|
||||
|
||||
// class KeyEncryption {
|
||||
// static final _key =
|
||||
// encrypt.Key.fromUtf8('32-character-key....'); // ضع مفتاحك هنا
|
||||
//
|
||||
// static String encryptKey(String key) {
|
||||
// final iv = encrypt.IV.fromLength(16); // توليد تهيئة عشوائية
|
||||
// final encrypter =
|
||||
// encrypt.Encrypter(encrypt.AES(_key, mode: encrypt.AESMode.cbc));
|
||||
// final encrypted = encrypter.encrypt(key, iv: iv);
|
||||
// final result = iv.bytes + encrypted.bytes; // تضمين التهيئة مع النص المشفر
|
||||
// return base64Encode(result);
|
||||
// }
|
||||
//
|
||||
// static Future<void> storeApiKeys(List<String> apiKeys) async {
|
||||
// final encryptedKeys = apiKeys.map((key) => encryptKey(key)).toList();
|
||||
// final response = await http.post(
|
||||
// Uri.parse('https://yourdomain.com/store_keys.php'),
|
||||
// body: jsonEncode({'keys': encryptedKeys}),
|
||||
// headers: {'Content-Type': 'application/json'},
|
||||
// );
|
||||
//
|
||||
// if (response.statusCode == 200) {
|
||||
// print('Keys stored successfully.');
|
||||
// } else {
|
||||
// print('Failed to store keys.');
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
|
||||
67
lib/controller/functions/package_info.dart
Normal file
67
lib/controller/functions/package_info.dart
Normal file
@@ -0,0 +1,67 @@
|
||||
import 'dart:convert';
|
||||
import 'dart:io';
|
||||
import 'package:SEFER/constant/links.dart';
|
||||
import 'package:SEFER/controller/functions/crud.dart';
|
||||
import 'package:flutter/cupertino.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:get/get.dart';
|
||||
import 'package:package_info_plus/package_info_plus.dart';
|
||||
import 'package:url_launcher/url_launcher.dart';
|
||||
import '../../constant/info.dart';
|
||||
|
||||
Future<void> checkForUpdate(BuildContext context) async {
|
||||
final packageInfo = await PackageInfo.fromPlatform();
|
||||
final currentVersion = packageInfo.buildNumber;
|
||||
print('currentVersion is : $currentVersion');
|
||||
// Fetch the latest version from your server
|
||||
String latestVersion = await getPackageInfo();
|
||||
|
||||
if (latestVersion.isNotEmpty && latestVersion != currentVersion) {
|
||||
showUpdateDialog(context);
|
||||
}
|
||||
}
|
||||
|
||||
Future<String> getPackageInfo() async {
|
||||
final response = await CRUD().get(link: AppLink.packageInfo, payload: {
|
||||
"platform": Platform.isAndroid ? 'android' : 'ios',
|
||||
"appName": AppInformation.appName,
|
||||
});
|
||||
|
||||
if (response != 'failure') {
|
||||
return jsonDecode(response)['message'][0]['version'];
|
||||
}
|
||||
return '';
|
||||
}
|
||||
|
||||
void showUpdateDialog(BuildContext context) {
|
||||
final String storeUrl = Platform.isAndroid
|
||||
? 'https://play.google.com/store/apps/details?id=com.sefer_driver'
|
||||
: 'https://apps.apple.com/ae/app/sefer/id6458734951';
|
||||
showCupertinoDialog(
|
||||
context: context,
|
||||
barrierDismissible: false,
|
||||
builder: (BuildContext context) {
|
||||
return CupertinoAlertDialog(
|
||||
title: Text('Update Available'.tr),
|
||||
content: Text(
|
||||
'A new version of the app is available. Please update to the latest version.'
|
||||
.tr,
|
||||
),
|
||||
actions: <Widget>[
|
||||
CupertinoDialogAction(
|
||||
child: Text('Update'.tr),
|
||||
onPressed: () async {
|
||||
if (await canLaunchUrl(Uri.parse(storeUrl))) {
|
||||
await launchUrl(Uri.parse(storeUrl));
|
||||
} else {
|
||||
print('Could not launch $storeUrl');
|
||||
}
|
||||
|
||||
Navigator.of(context).pop();
|
||||
},
|
||||
),
|
||||
],
|
||||
);
|
||||
},
|
||||
);
|
||||
}
|
||||
@@ -4,6 +4,9 @@ class MyTranslation extends Translations {
|
||||
@override
|
||||
Map<String, Map<String, String>> get keys => {
|
||||
"ar": {
|
||||
"Update Available": "تحديث متوفر",
|
||||
"A new version of the app is available. Please update to the latest version.":
|
||||
"تتوفر نسخة جديدة من التطبيق. يرجى التحديث إلى أحدث إصدار.",
|
||||
"We use location to get accurate and nearest passengers for you":
|
||||
"نستخدم الموقع للحصول على أقرب الركاب وأكثرهم دقة لك",
|
||||
"This ride is already applied by another driver.":
|
||||
|
||||
@@ -56,43 +56,44 @@ class RateController extends GetxController {
|
||||
if (value != 'failure') {
|
||||
Get.snackbar('Wallet Added'.tr, '',
|
||||
backgroundColor: AppColor.greenColor);
|
||||
if (double.parse(
|
||||
Get.find<CaptainWalletController>().totalAmountVisa) >
|
||||
remainingFee) {
|
||||
var paymentToken3 = await Get.find<MapDriverController>()
|
||||
.generateTokenDriver((-1 * remainingFee).toString());
|
||||
// if (double.parse(
|
||||
// Get.find<CaptainWalletController>().totalAmountVisa) >
|
||||
// remainingFee) {
|
||||
var paymentToken3 = await Get.find<MapDriverController>()
|
||||
.generateTokenDriver((-1 * remainingFee).toString());
|
||||
|
||||
await CRUD().post(link: AppLink.addDrivePayment, payload: {
|
||||
'rideId': 'remain$rideId',
|
||||
'amount': (-1 * remainingFee).toString(),
|
||||
'payment_method': 'Remainder',
|
||||
'passengerID': passengerId,
|
||||
'token': paymentToken3,
|
||||
'driverID': box.read(BoxName.driverID).toString(),
|
||||
});
|
||||
} else {
|
||||
double pointsSubtraction = 0;
|
||||
pointsSubtraction = remainingFee *
|
||||
(-1) /
|
||||
double.parse(
|
||||
Get.find<MapDriverController>().kazan); // for egypt /100
|
||||
var paymentToken4 = await Get.find<MapDriverController>()
|
||||
.generateTokenDriver((pointsSubtraction).toStringAsFixed(0));
|
||||
var res = await CRUD()
|
||||
.post(link: AppLink.addDriversWalletPoints, payload: {
|
||||
'paymentID': 'rideId$rideId',
|
||||
'amount': (pointsSubtraction).toStringAsFixed(0),
|
||||
'paymentMethod': 'Remainder',
|
||||
'token': paymentToken4,
|
||||
'driverID': box.read(BoxName.driverID).toString(),
|
||||
});
|
||||
FirebaseMessagesController().sendNotificationToAnyWithoutData(
|
||||
'Wallet Added'.tr,
|
||||
'Wallet Added${(remainingFee).toStringAsFixed(0)}'.tr,
|
||||
Get.find<MapDriverController>().tokenPassenger,
|
||||
'tone2.wav');
|
||||
walletChecked = 'true';
|
||||
}
|
||||
await CRUD().post(link: AppLink.addDrivePayment, payload: {
|
||||
'rideId': 'remain$rideId',
|
||||
'amount': (-1 * remainingFee).toString(),
|
||||
'payment_method': 'Remainder',
|
||||
'passengerID': passengerId,
|
||||
'token': paymentToken3,
|
||||
'driverID': box.read(BoxName.driverID).toString(),
|
||||
});
|
||||
// }
|
||||
// else {
|
||||
// double pointsSubtraction = 0;
|
||||
// pointsSubtraction = remainingFee *
|
||||
// (-1) /
|
||||
// double.parse(
|
||||
// Get.find<MapDriverController>().kazan); // for egypt /100
|
||||
// var paymentToken4 = await Get.find<MapDriverController>()
|
||||
// .generateTokenDriver((pointsSubtraction).toStringAsFixed(0));
|
||||
// var res = await CRUD()
|
||||
// .post(link: AppLink.addDriversWalletPoints, payload: {
|
||||
// 'paymentID': 'rideId$rideId',
|
||||
// 'amount': (pointsSubtraction).toStringAsFixed(0),
|
||||
// 'paymentMethod': 'Remainder',
|
||||
// 'token': paymentToken4,
|
||||
// 'driverID': box.read(BoxName.driverID).toString(),
|
||||
// });
|
||||
FirebaseMessagesController().sendNotificationToAnyWithoutData(
|
||||
'Wallet Added'.tr,
|
||||
'Wallet Added${(remainingFee).toStringAsFixed(0)}'.tr,
|
||||
Get.find<MapDriverController>().tokenPassenger,
|
||||
'tone2.wav');
|
||||
walletChecked = 'true';
|
||||
// }
|
||||
|
||||
update();
|
||||
}
|
||||
|
||||
@@ -17,6 +17,7 @@ import 'constant/info.dart';
|
||||
import 'controller/firebase/firbase_messge.dart';
|
||||
import 'controller/firebase/local_notification.dart';
|
||||
import 'controller/functions/location_controller.dart';
|
||||
import 'controller/functions/package_info.dart';
|
||||
import 'controller/local/local_controller.dart';
|
||||
import 'controller/local/translations.dart';
|
||||
import 'controller/payment/paymob/paymob_wallet.dart';
|
||||
@@ -109,7 +110,7 @@ class MyApp extends StatelessWidget {
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
LocaleController localController = Get.put(LocaleController());
|
||||
|
||||
// checkForUpdate(context);
|
||||
return GetMaterialApp(
|
||||
title: AppInformation.appName,
|
||||
translations: MyTranslation(),
|
||||
|
||||
@@ -10,6 +10,7 @@ import '../../../../constant/info.dart';
|
||||
import '../../../../constant/style.dart';
|
||||
import '../../../../constant/table_names.dart';
|
||||
import '../../../../controller/functions/location_controller.dart';
|
||||
import '../../../../controller/functions/package_info.dart';
|
||||
import '../../../../controller/home/captin/home_captain_controller.dart';
|
||||
import '../../../../controller/home/captin/order_request_controller.dart';
|
||||
import '../../../widgets/circle_container.dart';
|
||||
@@ -28,6 +29,9 @@ class HomeCaptain extends StatelessWidget {
|
||||
Widget build(BuildContext context) {
|
||||
Get.put(OrderRequestController());
|
||||
Get.put(HomeCaptainController());
|
||||
WidgetsBinding.instance.addPostFrameCallback((_) {
|
||||
checkForUpdate(context);
|
||||
});
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
// backgroundColor: AppColor.accentColor,
|
||||
|
||||
@@ -22,50 +22,52 @@ GetBuilder<HomeCaptainController> leftMainMenuCaptainIcons() {
|
||||
left: 6,
|
||||
child: Column(
|
||||
children: [
|
||||
// AnimatedContainer(
|
||||
// duration: const Duration(microseconds: 200),
|
||||
// width: controller.widthMapTypeAndTraffic,
|
||||
// decoration: BoxDecoration(
|
||||
// border: Border.all(color: AppColor.blueColor),
|
||||
// color: AppColor.secondaryColor,
|
||||
// borderRadius: BorderRadius.circular(15)),
|
||||
// child: IconButton(
|
||||
// onPressed: () {
|
||||
// // AC credentials = AC();
|
||||
// String apiKey = 'mehmetDEV@2101';
|
||||
// // String convertedStringN = credentials.c(
|
||||
// // credentials.c(credentials.c(apiKey, cs), cC), cn);
|
||||
// // print(convertedStringN);
|
||||
// // String retrievedStringS = credentials.r(
|
||||
// // credentials.r(credentials.r(convertedStringN, cn), cC),
|
||||
// // cs);
|
||||
// // print(retrievedStringS);
|
||||
// // //
|
||||
// // if (retrievedStringS == apiKey) {
|
||||
// // print('same');
|
||||
// // }
|
||||
//
|
||||
// // key.forEach((key, apiKey) {
|
||||
// String encryptedApiKey = KeyEncryption.encryptKey(apiKey);
|
||||
// print('Encrypted = $encryptedApiKey');
|
||||
//
|
||||
// String decryptedApiKey =
|
||||
// KeyEncryption.decryptKey(encryptedApiKey);
|
||||
// print('Decrypted : $decryptedApiKey');
|
||||
//
|
||||
// // if (decryptedApiKey == apiKey) {
|
||||
// // print('Keys match for $decryptedApiKey');
|
||||
// // } else {
|
||||
// // // print('Keys do not match for $key');
|
||||
// // }
|
||||
// // });
|
||||
// },
|
||||
// icon: const Icon(
|
||||
// FontAwesome.map_signs,
|
||||
// size: 24,
|
||||
// color: Colors.black,
|
||||
// )),
|
||||
// ),
|
||||
AnimatedContainer(
|
||||
duration: const Duration(microseconds: 200),
|
||||
width: controller.widthMapTypeAndTraffic,
|
||||
decoration: BoxDecoration(
|
||||
border: Border.all(color: AppColor.blueColor),
|
||||
color: AppColor.secondaryColor,
|
||||
borderRadius: BorderRadius.circular(15)),
|
||||
child: IconButton(
|
||||
onPressed: () {
|
||||
// AC credentials = AC();
|
||||
String apiKey = 'maldev@2101hamzaayedseferegyptjo';
|
||||
// String convertedStringN = credentials.c(
|
||||
// credentials.c(credentials.c(apiKey, cs), cC), cn);
|
||||
// print(convertedStringN);
|
||||
// String retrievedStringS = credentials.r(
|
||||
// credentials.r(credentials.r(convertedStringN, cn), cC),
|
||||
// cs);
|
||||
// print(retrievedStringS);
|
||||
// //
|
||||
// if (retrievedStringS == apiKey) {
|
||||
// print('same');
|
||||
// }
|
||||
|
||||
// key.forEach((key, apiKey) {
|
||||
|
||||
// keys.forEach((key, apiKey) {
|
||||
String encryptedApiKey = KeyEncryption.encryptKey(apiKey);
|
||||
print('Encrypted API Key for : $encryptedApiKey');
|
||||
|
||||
String decryptedApiKey = KeyEncryption.decryptKey(
|
||||
"Hsd7tLdt4ZsSRMCCs0xia2ct9O1jrJKyZu6pvh6MjL8qg6TkJ9FZCW4H/OqCkMjtokBOTdTX0P2sASLTcTxBVA==");
|
||||
print('Decrypted API Key for : $decryptedApiKey');
|
||||
|
||||
if (decryptedApiKey == apiKey) {
|
||||
print('Keys match for ');
|
||||
} else {
|
||||
print('Keys do not match for ');
|
||||
}
|
||||
// });
|
||||
},
|
||||
icon: const Icon(
|
||||
FontAwesome.map_signs,
|
||||
size: 24,
|
||||
color: Colors.black,
|
||||
)),
|
||||
),
|
||||
const SizedBox(
|
||||
height: 5,
|
||||
),
|
||||
|
||||
32
pubspec.lock
32
pubspec.lock
@@ -413,10 +413,10 @@ packages:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: ffi
|
||||
sha256: "7bf0adc28a23d395f19f3f1eb21dd7cfd1dd9f8e1c50051c069122e6853bc878"
|
||||
sha256: "493f37e7df1804778ff3a53bd691d8692ddf69702cf4c1c1096a2e41b4779e21"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "2.1.0"
|
||||
version: "2.1.2"
|
||||
file:
|
||||
dependency: transitive
|
||||
description:
|
||||
@@ -1377,21 +1377,21 @@ packages:
|
||||
source: hosted
|
||||
version: "2.1.0"
|
||||
package_info_plus:
|
||||
dependency: transitive
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: package_info_plus
|
||||
sha256: "7e76fad405b3e4016cd39d08f455a4eb5199723cf594cd1b8916d47140d93017"
|
||||
sha256: b93d8b4d624b4ea19b0a5a208b2d6eff06004bc3ce74c06040b120eeadd00ce0
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "4.2.0"
|
||||
version: "8.0.0"
|
||||
package_info_plus_platform_interface:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: package_info_plus_platform_interface
|
||||
sha256: "9bc8ba46813a4cc42c66ab781470711781940780fd8beddd0c3da62506d3a6c6"
|
||||
sha256: f49918f3433a3146047372f9d4f1f847511f2acd5cd030e1f44fe5a50036b70e
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "2.0.1"
|
||||
version: "3.0.0"
|
||||
path:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
@@ -1524,10 +1524,10 @@ packages:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: plugin_platform_interface
|
||||
sha256: f4f88d4a900933e7267e2b353594774fc0d07fb072b47eedcd5b54e1ea3269f8
|
||||
sha256: "4820fbfdb9478b1ebae27888254d445073732dae3d6ea81f0b7e06d5dedc3f02"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "2.1.7"
|
||||
version: "2.1.8"
|
||||
pointycastle:
|
||||
dependency: transitive
|
||||
description:
|
||||
@@ -2001,18 +2001,18 @@ packages:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: wakelock_plus
|
||||
sha256: f268ca2116db22e57577fb99d52515a24bdc1d570f12ac18bb762361d43b043d
|
||||
sha256: "14758533319a462ffb5aa3b7ddb198e59b29ac3b02da14173a1715d65d4e6e68"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "1.1.4"
|
||||
version: "1.2.5"
|
||||
wakelock_plus_platform_interface:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: wakelock_plus_platform_interface
|
||||
sha256: "40fabed5da06caff0796dc638e1f07ee395fb18801fbff3255a2372db2d80385"
|
||||
sha256: "422d1cdbb448079a8a62a5a770b69baa489f8f7ca21aef47800c726d404f9d16"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "1.1.0"
|
||||
version: "1.2.1"
|
||||
watcher:
|
||||
dependency: transitive
|
||||
description:
|
||||
@@ -2073,10 +2073,10 @@ packages:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: win32
|
||||
sha256: b0f37db61ba2f2e9b7a78a1caece0052564d1bc70668156cf3a29d676fe4e574
|
||||
sha256: a79dbe579cb51ecd6d30b17e0cae4e0ea15e2c0e66f69ad4198f22a6789e94f4
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "5.1.1"
|
||||
version: "5.5.1"
|
||||
win32_registry:
|
||||
dependency: transitive
|
||||
description:
|
||||
@@ -2110,5 +2110,5 @@ packages:
|
||||
source: hosted
|
||||
version: "3.1.2"
|
||||
sdks:
|
||||
dart: ">=3.3.0 <4.0.0"
|
||||
dart: ">=3.4.0 <4.0.0"
|
||||
flutter: ">=3.19.0"
|
||||
|
||||
@@ -64,13 +64,14 @@ dependencies:
|
||||
google_mlkit_text_recognition: ^0.13.0
|
||||
sign_in_with_apple: ^6.1.0
|
||||
firebase_auth: ^4.19.6
|
||||
package_info_plus: ^8.0.0
|
||||
|
||||
dev_dependencies:
|
||||
flutter_test:
|
||||
sdk: flutter
|
||||
flutter_lints: ^3.0.1
|
||||
envied_generator: ^0.5.2
|
||||
build_runner: ^2.4.6
|
||||
build_runner:
|
||||
|
||||
flutter_launcher_icons:
|
||||
android: "launcher_icon"
|
||||
|
||||
Reference in New Issue
Block a user