Refactor(Auth): Complete auth folder restructuring, security patches, and Flutter endpoint updates
This commit is contained in:
@@ -470,17 +470,17 @@ class AppLink {
|
||||
static String get updateTesterApp => "$auth/Tester/updateTesterApp.php";
|
||||
static String get signUp => "$auth/signup.php";
|
||||
static String get savePassengerLocation =>
|
||||
"$auth/save_passenger_location.php";
|
||||
"$auth/passenger/save_location.php";
|
||||
static String get sendVerifyEmail => "$auth/sendVerifyEmail.php";
|
||||
static String get loginFromGooglePassenger =>
|
||||
"$auth/loginFromGooglePassenger.php";
|
||||
"$auth/passenger/loginFromGoogle.php";
|
||||
static String get loginUsingCredentialsWithoutGooglePassenger =>
|
||||
"$auth/loginUsingCredentialsWithoutGooglePassenger.php";
|
||||
"$auth/passenger/loginUsingCredentialsWithoutGoogle.php";
|
||||
static String get checkPhoneNumberISVerfiedPassenger =>
|
||||
"$auth/checkPhoneNumberISVerfiedPassenger.php";
|
||||
|
||||
static String get passengerRemovedAccountEmail =>
|
||||
"$auth/passengerRemovedAccountEmail.php";
|
||||
"$auth/passenger/remove_account.php";
|
||||
static String get verifyEmail => "$auth/verifyEmail.php";
|
||||
//===================Auth Captin============
|
||||
static String get authCaptin => '$server/auth/captin';
|
||||
|
||||
@@ -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(),
|
||||
|
||||
Reference in New Issue
Block a user