Update: 2026-07-22 00:27:49
This commit is contained in:
@@ -119,7 +119,7 @@ class PhoneAuthHelper {
|
||||
var res = await CRUD()
|
||||
// this for register and login //
|
||||
.post(link: "${AppLink.server}/ride/firebase/addToken.php", payload: {
|
||||
'token': (box.read(BoxName.tokenFCM.toString())),
|
||||
'token': (box.read(BoxName.tokenFCM)),
|
||||
'passengerID': box.read(BoxName.passengerID).toString(),
|
||||
"fingerPrint": fingerPrint
|
||||
});
|
||||
|
||||
@@ -190,6 +190,15 @@ void showUpdateDialog(BuildContext context) {
|
||||
|
||||
class DeviceHelper {
|
||||
static Future<String> getDeviceFingerprint() async {
|
||||
// ── التحقق من وجود بصمة مخزّنة مسبقاً ──────────────────────
|
||||
// AES-GCM يستخدم IV عشوائي كل مرة، فالتشفير ينتج نتيجة مختلفة
|
||||
// حتى لو النص الأصلي نفسه. لذلك نخزّن البصمة المشفرة أول مرة
|
||||
// ونرجعها من التخزين في كل مرة بعدها لضمان الثبات.
|
||||
final String? cachedFp = box.read(BoxName.deviceFpEncrypted);
|
||||
if (cachedFp != null && cachedFp.isNotEmpty) {
|
||||
return cachedFp;
|
||||
}
|
||||
|
||||
final DeviceInfoPlugin deviceInfoPlugin = DeviceInfoPlugin();
|
||||
var deviceData;
|
||||
|
||||
|
||||
@@ -77,7 +77,8 @@ class MapMenuWidget extends StatelessWidget {
|
||||
decoration: BoxDecoration(
|
||||
color: _kBg.withValues(alpha: 0.88),
|
||||
borderRadius: BorderRadius.circular(16),
|
||||
border: Border.all(color: _kCyan.withValues(alpha: 0.25), width: 1),
|
||||
border: Border.all(
|
||||
color: _kCyan.withValues(alpha: 0.25), width: 1),
|
||||
boxShadow: [
|
||||
BoxShadow(
|
||||
color: _kCyan.withValues(alpha: 0.12),
|
||||
@@ -121,7 +122,8 @@ class MapMenuWidget extends StatelessWidget {
|
||||
decoration: BoxDecoration(
|
||||
color: _kBg.withValues(alpha: 0.97),
|
||||
border: Border(
|
||||
right: BorderSide(color: _kCyan.withValues(alpha: 0.12), width: 1),
|
||||
right:
|
||||
BorderSide(color: _kCyan.withValues(alpha: 0.12), width: 1),
|
||||
),
|
||||
boxShadow: [
|
||||
BoxShadow(
|
||||
@@ -149,11 +151,12 @@ class MapMenuWidget extends StatelessWidget {
|
||||
padding: const EdgeInsets.symmetric(
|
||||
horizontal: 12, vertical: 4),
|
||||
children: [
|
||||
// MenuListItem(
|
||||
// title: 'Mawasalati'.tr,
|
||||
// icon: Icons.directions_bus_filled_rounded,
|
||||
// onTap: () => Get.to(() => const TransitHomePage()),
|
||||
// ),
|
||||
MenuListItem(
|
||||
title: 'Mawasalati'.tr,
|
||||
icon: Icons.directions_bus_filled_rounded,
|
||||
onTap: () =>
|
||||
Get.to(() => const TransitHomePage()),
|
||||
),
|
||||
MenuListItem(
|
||||
title: 'My Balance'.tr,
|
||||
icon: Icons.account_balance_wallet_outlined,
|
||||
@@ -263,8 +266,8 @@ class MapMenuWidget extends StatelessWidget {
|
||||
_kAmber.withValues(alpha: 0.12),
|
||||
],
|
||||
),
|
||||
border:
|
||||
Border.all(color: _kCyan.withValues(alpha: 0.35), width: 1.5),
|
||||
border: Border.all(
|
||||
color: _kCyan.withValues(alpha: 0.35), width: 1.5),
|
||||
),
|
||||
child: Icon(Icons.person_rounded, color: _kCyan, size: 28),
|
||||
),
|
||||
@@ -281,7 +284,7 @@ class MapMenuWidget extends StatelessWidget {
|
||||
border: Border.all(color: _kBg, width: 2),
|
||||
boxShadow: [
|
||||
BoxShadow(
|
||||
color: const Color(0xFF00E676).withValues(alpha: 0.5),
|
||||
color: const Color(0xFF00E676).withValues(alpha: 0.5),
|
||||
blurRadius: 6,
|
||||
),
|
||||
],
|
||||
@@ -383,8 +386,7 @@ class MapMenuWidget extends StatelessWidget {
|
||||
driverAppUrl =
|
||||
'https://play.google.com/store/apps/details?id=com.siro_driver';
|
||||
} else if (defaultTargetPlatform == TargetPlatform.iOS) {
|
||||
driverAppUrl =
|
||||
'https://apps.apple.com/st/app/siro-driver/id6482995159';
|
||||
driverAppUrl = 'https://apps.apple.com/st/app/siro-driver/id6482995159';
|
||||
} else {
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user