marco.pms.mobileapp/lib/helpers/services/app_initializer.dart
Vaibhav Surve a0f1602f4e feat(directory): add contact profile and directory management features
- Implemented ContactProfileResponse and related models for handling contact details.
- Created ContactTagResponse and ContactTag models for managing contact tags.
- Added DirectoryCommentResponse and DirectoryComment models for comment management.
- Developed DirectoryFilterBottomSheet for filtering contacts.
- Introduced OrganizationListModel for organization data handling.
- Updated routes to include DirectoryMainScreen.
- Enhanced DashboardScreen to navigate to the new directory page.
- Created ContactDetailScreen for displaying detailed contact information.
- Developed DirectoryMainScreen for managing and displaying contacts.
- Added dependencies for font_awesome_flutter and flutter_html in pubspec.yaml.
2025-07-02 15:57:39 +05:30

49 lines
1.5 KiB
Dart

import 'package:flutter/services.dart';
import 'package:get/get.dart';
import 'package:marco/controller/permission_controller.dart';
import 'package:marco/controller/project_controller.dart';
import 'package:marco/helpers/services/storage/local_storage.dart';
import 'package:marco/helpers/theme/theme_customizer.dart';
import 'package:marco/helpers/theme/app_theme.dart';
import 'package:url_strategy/url_strategy.dart';
import 'package:marco/helpers/services/app_logger.dart';
Future<void> initializeApp() async {
try {
logSafe("💡 Starting app initialization...");
setPathUrlStrategy();
logSafe("💡 URL strategy set.");
SystemChrome.setSystemUIOverlayStyle(const SystemUiOverlayStyle(
statusBarColor: Color.fromARGB(255, 255, 0, 0),
statusBarIconBrightness: Brightness.light,
));
logSafe("💡 System UI overlay style set.");
await LocalStorage.init();
logSafe("💡 Local storage initialized.");
await ThemeCustomizer.init();
logSafe("💡 Theme customizer initialized.");
Get.put(PermissionController());
logSafe("💡 PermissionController injected.");
Get.put(ProjectController(), permanent: true);
logSafe("💡 ProjectController injected as permanent.");
AppStyle.init();
logSafe("💡 AppStyle initialized.");
logSafe("✅ App initialization completed successfully.");
} catch (e, stacktrace) {
logSafe("⛔ Error during app initialization",
level: LogLevel.error,
error: e,
stackTrace: stacktrace,
);
rethrow;
}
}