chore : delete auth package because each project has different auth , must be separated auth logic

This commit is contained in:
2025-07-27 15:13:37 +03:30
parent d192419ac8
commit 94513867f6
93 changed files with 1140 additions and 678 deletions

View File

@@ -0,0 +1,36 @@
import 'dart:math';
import 'package:flutter/material.dart';
import 'package:rasadyar_core/core.dart';
import 'package:rasadyar_core/data/model/response/captcha/captcha_response_model.dart';
import 'package:rasadyar_inspection/data/repositories/auth_repository_imp.dart';
class CaptchaWidgetLogic extends GetxController with StateMixin<CaptchaResponseModel> {
TextEditingController textController = TextEditingController();
RxnString captchaKey = RxnString();
GlobalKey<FormState> formKey = GlobalKey<FormState>();
//AuthRepositoryImpl authRepository = .get<AuthRepositoryImpl>();
final Random random = Random();
@override
void onInit() {
super.onInit();
getCaptcha();
}
@override
void onClose() {
textController.clear();
textController.dispose();
super.onClose();
}
Future<void> getCaptcha() async {
change(null, status: RxStatus.loading());
textController.clear();
await Future.delayed(Duration(milliseconds: 800));
captchaKey.value = (random.nextInt(900000) + 100000).toString();
change(value, status: RxStatus.success());
}
}