Refactor(Auth): Complete auth folder restructuring, security patches, and Flutter endpoint updates

This commit is contained in:
Hamza-Ayed
2026-07-09 05:22:05 +03:00
parent 45859883a5
commit 87dc925ea7
37 changed files with 40 additions and 31 deletions
@@ -16,7 +16,7 @@ class PhoneAuthHelper {
// Define your server URLs
static final String _sendOtpUrl = '${AppLink.server}/auth/otp/request.php';
static final String _verifyOtpUrl = '${AppLink.server}/auth/otp/verify.php';
static final String _registerUrl = '${AppLink.server}/auth/syria/register_passenger.php';
static final String _registerUrl = '${AppLink.server}/auth/passenger/register.php';
// removed formatSyrianPhone
@@ -96,6 +96,15 @@ class OtpVerificationController extends GetxController {
);
if (response != 'failure' && response['status'] == 'success') {
// تحديث التوكن والبصمة الجديدة في الباك إند
await CRUD().post(
link: "${AppLink.server}/ride/firebase/addToken.php",
payload: {
'token': box.read(BoxName.tokenFCM).toString(),
'fingerPrint': fingerPrint.toString(),
'passengerID': box.read(BoxName.passengerID).toString(),
});
await NotificationService.sendNotification(
category: 'token change',
target: ptoken.toString(),