This commit is contained in:
Hamza-Ayed
2024-06-28 19:09:55 +03:00
parent 715726a52d
commit 6fb79baab4
17 changed files with 332 additions and 315 deletions

View File

@@ -18,7 +18,7 @@ import 'package:location/location.dart';
import '../../firebase/firbase_messge.dart';
class LoginCaptinController extends GetxController {
class LoginDriverController extends GetxController {
final formKey = GlobalKey<FormState>();
TextEditingController emailController = TextEditingController();
TextEditingController phoneController = TextEditingController();
@@ -110,7 +110,7 @@ class LoginCaptinController extends GetxController {
}
}
loginFromSignInGoogle(String driverID, email) async {
loginUsingCredentials(String driverID, email) async {
isloading = true;
update();
var res = await CRUD().get(link: AppLink.loginFromGoogleCaptin, payload: {

View File

@@ -124,13 +124,13 @@ class RegisterCaptainController extends GetxController {
sendVerifications() async {
var res = await CRUD().post(link: AppLink.verifyEmail, payload: {
'email': emailController.text.isEmpty
? Get.find<LoginCaptinController>().emailController.text.toString()
? Get.find<LoginDriverController>().emailController.text.toString()
: emailController.text,
'token': verifyCode.text,
});
if (res != 'failure') {
if (Get.find<LoginCaptinController>().emailController.text.toString() !=
if (Get.find<LoginDriverController>().emailController.text.toString() !=
'') {
Get.offAll(() => HomeCaptain());
} else {