refactor: remove unused local and remote data sources, models, and tests for chicken and poultry features to streamline codebase

This commit is contained in:
2025-12-08 16:10:34 +03:30
parent 890be0ded6
commit 455a5a5571
230 changed files with 2812 additions and 3471 deletions

View File

@@ -1,14 +1,16 @@
import 'package:rasadyar_chicken/data/di/chicken_di.dart';
import 'package:rasadyar_chicken/data/repositories/chicken/chicken_repository.dart';
import 'package:rasadyar_chicken/features/common/data/repositories/common/common_repository.dart';
import 'package:rasadyar_core/core.dart';
import '../../../data/models/response/user_profile/user_profile.dart';
import '../../../features/common/data/model/response/user_profile/user_profile.dart';
class ChickenBaseLogic extends BasePageLogic {
var tokenService = Get.find<TokenStorageService>();
ChickenRepository chickenRepository = diChicken.get<ChickenRepository>();
CommonRepository commonRepository = diChicken.get<CommonRepository>();
Rx<Resource<UserProfile>> userProfile = Rx<Resource<UserProfile>>(Resource.loading());
Rx<Resource<UserProfile>> userProfile = Rx<Resource<UserProfile>>(
Resource.loading(),
);
@override
void onInit() {
@@ -19,8 +21,9 @@ class ChickenBaseLogic extends BasePageLogic {
Future<void> getUserProfile() async {
userProfile.value = Resource.loading();
await safeCall<UserProfile?>(
call: () async =>
await chickenRepository.getUserProfile(token: tokenService.accessToken.value!),
call: () async => await commonRepository.getUserProfile(
token: tokenService.accessToken.value!,
),
onSuccess: (result) {
if (result != null) {
userProfile.value = Resource.success(result);