Update: 2026-06-26 17:29:23

This commit is contained in:
Hamza-Ayed
2026-06-26 17:29:23 +03:00
parent a323da29aa
commit 9ded734e38
139 changed files with 1815 additions and 2676 deletions

View File

@@ -10,6 +10,7 @@ import '../../constant/style.dart';
import '../../main.dart';
import '../../views/widgets/elevated_btn.dart';
import '../../views/widgets/my_textField.dart';
import '../../views/widgets/snackbar.dart';
import 'crud.dart';
class LogOutController extends GetxController {
@@ -20,12 +21,11 @@ class LogOutController extends GetxController {
Future deleteMyAccountDriver(String id) async {
await CRUD().post(link: AppLink.removeUser, payload: {'id': id}).then(
(value) => Get.snackbar('Deleted'.tr, 'Your Account is Deleted',
backgroundColor: AppColor.redColor));
(value) => mySnackbarWarning('Your Account is Deleted'.tr));
}
checkBeforeDelete() async {
var res = await CRUD().post(
await CRUD().post(
link: AppLink.deletecaptainAccounr,
payload: {'id': box.read(BoxName.driverID)}).then((value) => exit(0));
}
@@ -88,7 +88,7 @@ class LogOutController extends GetxController {
),
ElevatedButton(
style: ButtonStyle(
backgroundColor: MaterialStateProperty.all(AppColor.redColor),
backgroundColor: WidgetStateProperty.all(AppColor.redColor),
),
onPressed: () {
// box.remove(BoxName.agreeTerms);
@@ -131,7 +131,7 @@ class LogOutController extends GetxController {
),
ElevatedButton(
style: ButtonStyle(
backgroundColor: MaterialStateProperty.all(AppColor.redColor),
backgroundColor: WidgetStateProperty.all(AppColor.redColor),
),
onPressed: () {
// box.remove(BoxName.agreeTerms);
@@ -172,9 +172,7 @@ class LogOutController extends GetxController {
'email': box.read(BoxName.email),
});
} else {
Get.snackbar('Email Wrong'.tr, 'Email you inserted is Wrong.'.tr,
snackPosition: SnackPosition.BOTTOM,
backgroundColor: AppColor.redColor);
mySnackbarError('Email you inserted is Wrong.'.tr);
}
}
}