diff --git a/justfile b/justfile
index e02a2f8b3..b4f7add8b 100644
--- a/justfile
+++ b/justfile
@@ -270,6 +270,9 @@ all: services gen native run
# Run everything at once, tailored for iOS development
all-ios: services gen ios run
+# Run iOS on public regtest (useful for device testing, where local regtest is not available)
+all-ios-regtest: services gen ios run-regtest
+
# Run everything at once, tailored for Android development (rebuilds Android)
all-android: services gen android run-local-android
diff --git a/mobile/android/app/build.gradle b/mobile/android/app/build.gradle
index 3adfac498..4ae9e5143 100644
--- a/mobile/android/app/build.gradle
+++ b/mobile/android/app/build.gradle
@@ -22,6 +22,9 @@ if (flutterVersionName == null) {
}
apply plugin: 'com.android.application'
+// START: FlutterFire Configuration
+apply plugin: 'com.google.gms.google-services'
+// END: FlutterFire Configuration
apply plugin: 'kotlin-android'
apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle"
diff --git a/mobile/android/app/google-services.json b/mobile/android/app/google-services.json
new file mode 100644
index 000000000..fd5bf954b
--- /dev/null
+++ b/mobile/android/app/google-services.json
@@ -0,0 +1,46 @@
+{
+ "project_info": {
+ "project_number": "237191932527",
+ "project_id": "project-3195624368411891722",
+ "storage_bucket": "project-3195624368411891722.appspot.com"
+ },
+ "client": [
+ {
+ "client_info": {
+ "mobilesdk_app_id": "1:237191932527:android:651be56a933e8bda36bb9a",
+ "android_client_info": {
+ "package_name": "finance.get10101.app"
+ }
+ },
+ "oauth_client": [
+ {
+ "client_id": "237191932527-g0dgit9aosfg3nog348uqcm5mppr2003.apps.googleusercontent.com",
+ "client_type": 3
+ }
+ ],
+ "api_key": [
+ {
+ "current_key": "AIzaSyCDI7arcBp4uriwfLySgqrchkNVDVW94uk"
+ }
+ ],
+ "services": {
+ "appinvite_service": {
+ "other_platform_oauth_client": [
+ {
+ "client_id": "237191932527-g0dgit9aosfg3nog348uqcm5mppr2003.apps.googleusercontent.com",
+ "client_type": 3
+ },
+ {
+ "client_id": "237191932527-70uoogr06k3rrrmslr5u1r6i4st9ch39.apps.googleusercontent.com",
+ "client_type": 2,
+ "ios_info": {
+ "bundle_id": "finance.get10101.app"
+ }
+ }
+ ]
+ }
+ }
+ }
+ ],
+ "configuration_version": "1"
+}
diff --git a/mobile/android/app/src/main/AndroidManifest.xml b/mobile/android/app/src/main/AndroidManifest.xml
index d710c648d..70889ac29 100644
--- a/mobile/android/app/src/main/AndroidManifest.xml
+++ b/mobile/android/app/src/main/AndroidManifest.xml
@@ -31,7 +31,14 @@
-
+
+
+
+
+
+
+
+
10.12.0)
+ - firebase_core (2.15.0):
+ - Firebase/CoreOnly (= 10.12.0)
+ - Flutter
+ - firebase_messaging (14.6.5):
+ - Firebase/Messaging (= 10.12.0)
+ - firebase_core
+ - Flutter
+ - FirebaseCore (10.12.0):
+ - FirebaseCoreInternal (~> 10.0)
+ - GoogleUtilities/Environment (~> 7.8)
+ - GoogleUtilities/Logger (~> 7.8)
+ - FirebaseCoreInternal (10.13.0):
+ - "GoogleUtilities/NSData+zlib (~> 7.8)"
+ - FirebaseInstallations (10.13.0):
+ - FirebaseCore (~> 10.0)
+ - GoogleUtilities/Environment (~> 7.8)
+ - GoogleUtilities/UserDefaults (~> 7.8)
+ - PromisesObjC (~> 2.1)
+ - FirebaseMessaging (10.12.0):
+ - FirebaseCore (~> 10.0)
+ - FirebaseInstallations (~> 10.0)
+ - GoogleDataTransport (~> 9.2)
+ - GoogleUtilities/AppDelegateSwizzler (~> 7.8)
+ - GoogleUtilities/Environment (~> 7.8)
+ - GoogleUtilities/Reachability (~> 7.8)
+ - GoogleUtilities/UserDefaults (~> 7.8)
+ - nanopb (< 2.30910.0, >= 2.30908.0)
- Flutter (1.0.0)
+ - flutter_local_notifications (0.0.1):
+ - Flutter
- flutter_native_splash (0.0.1):
- Flutter
+ - GoogleDataTransport (9.2.5):
+ - GoogleUtilities/Environment (~> 7.7)
+ - nanopb (< 2.30910.0, >= 2.30908.0)
+ - PromisesObjC (< 3.0, >= 1.2)
+ - GoogleUtilities/AppDelegateSwizzler (7.11.5):
+ - GoogleUtilities/Environment
+ - GoogleUtilities/Logger
+ - GoogleUtilities/Network
+ - GoogleUtilities/Environment (7.11.5):
+ - PromisesObjC (< 3.0, >= 1.2)
+ - GoogleUtilities/Logger (7.11.5):
+ - GoogleUtilities/Environment
+ - GoogleUtilities/Network (7.11.5):
+ - GoogleUtilities/Logger
+ - "GoogleUtilities/NSData+zlib"
+ - GoogleUtilities/Reachability
+ - "GoogleUtilities/NSData+zlib (7.11.5)"
+ - GoogleUtilities/Reachability (7.11.5):
+ - GoogleUtilities/Logger
+ - GoogleUtilities/UserDefaults (7.11.5):
+ - GoogleUtilities/Logger
+ - nanopb (2.30909.0):
+ - nanopb/decode (= 2.30909.0)
+ - nanopb/encode (= 2.30909.0)
+ - nanopb/decode (2.30909.0)
+ - nanopb/encode (2.30909.0)
- package_info_plus (0.4.5):
- Flutter
- path_provider_foundation (0.0.1):
- Flutter
- FlutterMacOS
+ - PromisesObjC (2.3.1)
- share_plus (0.0.1):
- Flutter
- shared_preferences_foundation (0.0.1):
@@ -16,7 +77,10 @@ PODS:
- Flutter
DEPENDENCIES:
+ - firebase_core (from `.symlinks/plugins/firebase_core/ios`)
+ - firebase_messaging (from `.symlinks/plugins/firebase_messaging/ios`)
- Flutter (from `Flutter`)
+ - flutter_local_notifications (from `.symlinks/plugins/flutter_local_notifications/ios`)
- flutter_native_splash (from `.symlinks/plugins/flutter_native_splash/ios`)
- package_info_plus (from `.symlinks/plugins/package_info_plus/ios`)
- path_provider_foundation (from `.symlinks/plugins/path_provider_foundation/darwin`)
@@ -24,9 +88,27 @@ DEPENDENCIES:
- shared_preferences_foundation (from `.symlinks/plugins/shared_preferences_foundation/darwin`)
- social_share (from `.symlinks/plugins/social_share/ios`)
+SPEC REPOS:
+ trunk:
+ - Firebase
+ - FirebaseCore
+ - FirebaseCoreInternal
+ - FirebaseInstallations
+ - FirebaseMessaging
+ - GoogleDataTransport
+ - GoogleUtilities
+ - nanopb
+ - PromisesObjC
+
EXTERNAL SOURCES:
+ firebase_core:
+ :path: ".symlinks/plugins/firebase_core/ios"
+ firebase_messaging:
+ :path: ".symlinks/plugins/firebase_messaging/ios"
Flutter:
:path: Flutter
+ flutter_local_notifications:
+ :path: ".symlinks/plugins/flutter_local_notifications/ios"
flutter_native_splash:
:path: ".symlinks/plugins/flutter_native_splash/ios"
package_info_plus:
@@ -41,10 +123,22 @@ EXTERNAL SOURCES:
:path: ".symlinks/plugins/social_share/ios"
SPEC CHECKSUMS:
+ Firebase: 07150e75d142fb9399f6777fa56a187b17f833a0
+ firebase_core: e477125798fc37cd4ab43ca6a8536bf7e0929c00
+ firebase_messaging: 334d68c3a36b6d4d5cd91e4f42509e0d4ae49828
+ FirebaseCore: f86a1394906b97ac445ae49c92552a9425831bed
+ FirebaseCoreInternal: b342e37cd4f5b4454ec34308f073420e7920858e
+ FirebaseInstallations: b28af1b9f997f1a799efe818c94695a3728c352f
+ FirebaseMessaging: bb2c4f6422a753038fe137d90ae7c1af57251316
Flutter: f04841e97a9d0b0a8025694d0796dd46242b2854
+ flutter_local_notifications: 0c0b1ae97e741e1521e4c1629a459d04b9aec743
flutter_native_splash: 52501b97d1c0a5f898d687f1646226c1f93c56ef
+ GoogleDataTransport: 54dee9d48d14580407f8f5fbf2f496e92437a2f2
+ GoogleUtilities: 13e2c67ede716b8741c7989e26893d151b2b2084
+ nanopb: b552cce312b6c8484180ef47159bc0f65a1f0431
package_info_plus: fd030dabf36271f146f1f3beacd48f564b0f17f7
path_provider_foundation: eaf5b3e458fc0e5fbb9940fb09980e853fe058b8
+ PromisesObjC: c50d2056b5253dadbd6c2bea79b0674bd5a52fa4
share_plus: 599aa54e4ea31d4b4c0e9c911bcc26c55e791028
shared_preferences_foundation: 5b919d13b803cadd15ed2dc053125c68730e5126
social_share: 702a5e3842addd22db515aa9e1e00a4b80a0296d
diff --git a/mobile/ios/Runner.xcodeproj/project.pbxproj b/mobile/ios/Runner.xcodeproj/project.pbxproj
index 97e6e8f30..716abe57a 100644
--- a/mobile/ios/Runner.xcodeproj/project.pbxproj
+++ b/mobile/ios/Runner.xcodeproj/project.pbxproj
@@ -15,6 +15,7 @@
97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; };
97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; };
A3D4965429384D8600FB0055 /* libnative_static.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A309F0BC2927FD3600259411 /* libnative_static.a */; };
+ ECF6A2CDD51B59DF45C6E151 /* GoogleService-Info.plist in Resources */ = {isa = PBXBuildFile; fileRef = D316DC5FE93D254FB646122E /* GoogleService-Info.plist */; };
/* End PBXBuildFile section */
/* Begin PBXContainerItemProxy section */
@@ -62,6 +63,7 @@
3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = ""; };
5184B10636355E38189482F8 /* Pods-Runner.release-test.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.release-test.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.release-test.xcconfig"; sourceTree = ""; };
6BD9F8CC844A46FA976A5C20 /* Pods-Runner.debug-test.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.debug-test.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.debug-test.xcconfig"; sourceTree = ""; };
+ 6FAE43622A844F0100ABB0D1 /* Runner.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = Runner.entitlements; sourceTree = ""; };
74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Runner-Bridging-Header.h"; sourceTree = ""; };
74858FAE1ED2DC5600515810 /* AppDelegate.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; };
7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = ""; };
@@ -76,6 +78,7 @@
A35253292866B17200EFD9C6 /* native.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = native.xcodeproj; path = ../../native/native.xcodeproj; sourceTree = ""; };
A35253412866B24600EFD9C6 /* bridge_generated.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = bridge_generated.h; sourceTree = ""; };
A7CE085E4A6586C6ECEAE97D /* Pods_Runner.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Runner.framework; sourceTree = BUILT_PRODUCTS_DIR; };
+ D316DC5FE93D254FB646122E /* GoogleService-Info.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; name = "GoogleService-Info.plist"; path = "Runner/GoogleService-Info.plist"; sourceTree = ""; };
D447E3493D1BDF7CAB11C901 /* Pods-Runner.profile-test.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.profile-test.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.profile-test.xcconfig"; sourceTree = ""; };
/* End PBXFileReference section */
@@ -124,6 +127,7 @@
97C146EF1CF9000F007C117D /* Products */,
A352533F2866B1BF00EFD9C6 /* Frameworks */,
6350F610F6B04AE4C48FA32F /* Pods */,
+ D316DC5FE93D254FB646122E /* GoogleService-Info.plist */,
);
sourceTree = "";
};
@@ -138,6 +142,7 @@
97C146F01CF9000F007C117D /* Runner */ = {
isa = PBXGroup;
children = (
+ 6FAE43622A844F0100ABB0D1 /* Runner.entitlements */,
A35253292866B17200EFD9C6 /* native.xcodeproj */,
97C146FA1CF9000F007C117D /* Main.storyboard */,
97C146FD1CF9000F007C117D /* Assets.xcassets */,
@@ -201,6 +206,7 @@
97C146E61CF9000F007C117D /* Project object */ = {
isa = PBXProject;
attributes = {
+ BuildIndependentTargetsInParallel = YES;
LastUpgradeCheck = 1300;
ORGANIZATIONNAME = "";
TargetAttributes = {
@@ -260,6 +266,7 @@
3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */,
97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */,
97C146FC1CF9000F007C117D /* Main.storyboard in Resources */,
+ ECF6A2CDD51B59DF45C6E151 /* GoogleService-Info.plist in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@@ -436,6 +443,7 @@
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = YES;
+ CODE_SIGN_ENTITLEMENTS = Runner/Runner.entitlements;
CODE_SIGN_IDENTITY = "Apple Development";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution";
CODE_SIGN_STYLE = Manual;
@@ -583,11 +591,12 @@
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = YES;
+ CODE_SIGN_ENTITLEMENTS = Runner/Runner.entitlements;
CODE_SIGN_IDENTITY = "Apple Development";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution";
CODE_SIGN_STYLE = Manual;
CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
- DEVELOPMENT_TEAM = "";
+ DEVELOPMENT_TEAM = "";
"DEVELOPMENT_TEAM[sdk=iphoneos*]" = V3D64P9D6W;
ENABLE_BITCODE = NO;
INFOPLIST_FILE = Runner/Info.plist;
@@ -620,10 +629,11 @@
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = YES;
+ CODE_SIGN_ENTITLEMENTS = Runner/Runner.entitlements;
CODE_SIGN_IDENTITY = "Apple Development";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution";
CODE_SIGN_STYLE = Manual;
- CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
+ CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
DEVELOPMENT_TEAM = "";
"DEVELOPMENT_TEAM[sdk=iphoneos*]" = V3D64P9D6W;
ENABLE_BITCODE = NO;
@@ -713,6 +723,7 @@
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = "AppIcon-test";
CLANG_ENABLE_MODULES = YES;
+ CODE_SIGN_ENTITLEMENTS = Runner/Runner.entitlements;
CODE_SIGN_IDENTITY = "Apple Development";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution";
CODE_SIGN_STYLE = Manual;
@@ -804,6 +815,7 @@
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = "AppIcon-test";
CLANG_ENABLE_MODULES = YES;
+ CODE_SIGN_ENTITLEMENTS = Runner/Runner.entitlements;
CODE_SIGN_IDENTITY = "Apple Development";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution";
CODE_SIGN_STYLE = Manual;
@@ -892,6 +904,7 @@
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = "AppIcon-test";
CLANG_ENABLE_MODULES = YES;
+ CODE_SIGN_ENTITLEMENTS = Runner/Runner.entitlements;
CODE_SIGN_IDENTITY = "Apple Development";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution";
CODE_SIGN_STYLE = Manual;
diff --git a/mobile/ios/Runner/AppDelegate.swift b/mobile/ios/Runner/AppDelegate.swift
index 1958642ca..ecb21711d 100644
--- a/mobile/ios/Runner/AppDelegate.swift
+++ b/mobile/ios/Runner/AppDelegate.swift
@@ -8,7 +8,21 @@ import Flutter
didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?
) -> Bool {
print("dummy_value=\(dummy_method_to_enforce_bundling())");
+
+ // Set the delegate for the UNUserNotificationCenter
+ if #available(iOS 10.0, *) {
+ UNUserNotificationCenter.current().delegate = self
+ }
+
GeneratedPluginRegistrant.register(with: self)
return super.application(application, didFinishLaunchingWithOptions: launchOptions)
+}
+
+ // Implement the method to handle the display of notifications in the foreground
+ @available(iOS 10.0, *)
+ override func userNotificationCenter(_ center: UNUserNotificationCenter,
+ willPresent notification: UNNotification,
+ withCompletionHandler completionHandler: @escaping (UNNotificationPresentationOptions) -> Void) {
+ completionHandler([.sound, .alert, .badge])
}
}
diff --git a/mobile/ios/Runner/GoogleService-Info.plist b/mobile/ios/Runner/GoogleService-Info.plist
new file mode 100644
index 000000000..98cac5bce
--- /dev/null
+++ b/mobile/ios/Runner/GoogleService-Info.plist
@@ -0,0 +1,34 @@
+
+
+
+
+ CLIENT_ID
+ 237191932527-70uoogr06k3rrrmslr5u1r6i4st9ch39.apps.googleusercontent.com
+ REVERSED_CLIENT_ID
+ com.googleusercontent.apps.237191932527-70uoogr06k3rrrmslr5u1r6i4st9ch39
+ API_KEY
+ AIzaSyD1FiZUHkX-rdHUtAXU12ku2e7zmBHqLSQ
+ GCM_SENDER_ID
+ 237191932527
+ PLIST_VERSION
+ 1
+ BUNDLE_ID
+ finance.get10101.app
+ PROJECT_ID
+ project-3195624368411891722
+ STORAGE_BUCKET
+ project-3195624368411891722.appspot.com
+ IS_ADS_ENABLED
+
+ IS_ANALYTICS_ENABLED
+
+ IS_APPINVITE_ENABLED
+
+ IS_GCM_ENABLED
+
+ IS_SIGNIN_ENABLED
+
+ GOOGLE_APP_ID
+ 1:237191932527:ios:ed5586aaa838be1e36bb9a
+
+
\ No newline at end of file
diff --git a/mobile/ios/Runner/Info.plist b/mobile/ios/Runner/Info.plist
index ae74dc367..e49a84c59 100644
--- a/mobile/ios/Runner/Info.plist
+++ b/mobile/ios/Runner/Info.plist
@@ -1,62 +1,69 @@
+
+ CADisableMinimumFrameDurationOnPhone
+
+ CFBundleDevelopmentRegion
+ $(DEVELOPMENT_LANGUAGE)
+ CFBundleDisplayName
+ $(PRODUCT_NAME)
+ CFBundleExecutable
+ $(EXECUTABLE_NAME)
+ CFBundleIdentifier
+ $(PRODUCT_BUNDLE_IDENTIFIER)
+ CFBundleInfoDictionaryVersion
+ 6.0
+ CFBundleName
+ 10101
+ CFBundlePackageType
+ APPL
+ CFBundleShortVersionString
+ $(FLUTTER_BUILD_NAME)
+ CFBundleSignature
+ ????
+ CFBundleVersion
+ $(FLUTTER_BUILD_NUMBER)
+ ITSAppUsesNonExemptEncryption
+
+ LSRequiresIPhoneOS
+
+ NSAppTransportSecurity
- CFBundleDevelopmentRegion
- $(DEVELOPMENT_LANGUAGE)
- CFBundleDisplayName
- $(PRODUCT_NAME)
- CFBundleExecutable
- $(EXECUTABLE_NAME)
- CFBundleIdentifier
- $(PRODUCT_BUNDLE_IDENTIFIER)
- CFBundleInfoDictionaryVersion
- 6.0
- CFBundleName
- 10101
- CFBundlePackageType
- APPL
- CFBundleShortVersionString
- $(FLUTTER_BUILD_NAME)
- CFBundleSignature
- ????
- CFBundleVersion
- $(FLUTTER_BUILD_NUMBER)
- LSRequiresIPhoneOS
-
- UILaunchStoryboardName
- LaunchScreen
- UIMainStoryboardFile
- Main
- UISupportedInterfaceOrientations
-
- UIInterfaceOrientationPortrait
- UIInterfaceOrientationLandscapeLeft
- UIInterfaceOrientationLandscapeRight
-
- UISupportedInterfaceOrientations~ipad
-
- UIInterfaceOrientationPortrait
- UIInterfaceOrientationPortraitUpsideDown
- UIInterfaceOrientationLandscapeLeft
- UIInterfaceOrientationLandscapeRight
-
- UIViewControllerBasedStatusBarAppearance
-
- CADisableMinimumFrameDurationOnPhone
-
- UIApplicationSupportsIndirectInputEvents
-
- UIStatusBarHidden
-
- NSAppTransportSecurity
-
- NSAllowsArbitraryLoads
-
-
- ITSAppUsesNonExemptEncryption
-
- UIFileSharingEnabled
+ NSAllowsArbitraryLoads
+ UIApplicationSupportsIndirectInputEvents
+
+ UIBackgroundModes
+
+ fetch
+ remote-notification
+
+ UIFileSharingEnabled
+
+ UILaunchStoryboardName
+ LaunchScreen
+ UIMainStoryboardFile
+ Main
+ UIStatusBarHidden
+
+ UIStatusBarStyle
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UIViewControllerBasedStatusBarAppearance
+
+
diff --git a/mobile/ios/Runner/Runner.entitlements b/mobile/ios/Runner/Runner.entitlements
new file mode 100644
index 000000000..903def2af
--- /dev/null
+++ b/mobile/ios/Runner/Runner.entitlements
@@ -0,0 +1,8 @@
+
+
+
+
+ aps-environment
+ development
+
+
diff --git a/mobile/ios/firebase_app_id_file.json b/mobile/ios/firebase_app_id_file.json
new file mode 100644
index 000000000..8b69b6632
--- /dev/null
+++ b/mobile/ios/firebase_app_id_file.json
@@ -0,0 +1,7 @@
+{
+ "file_generated_by": "FlutterFire CLI",
+ "purpose": "FirebaseAppID & ProjectID for this Firebase app in this directory",
+ "GOOGLE_APP_ID": "1:237191932527:ios:ed5586aaa838be1e36bb9a",
+ "FIREBASE_PROJECT_ID": "project-3195624368411891722",
+ "GCM_SENDER_ID": "237191932527"
+}
diff --git a/mobile/lib/firebase_options.dart b/mobile/lib/firebase_options.dart
new file mode 100644
index 000000000..9b92248e9
--- /dev/null
+++ b/mobile/lib/firebase_options.dart
@@ -0,0 +1,75 @@
+// File generated by FlutterFire CLI.
+// ignore_for_file: lines_longer_than_80_chars, avoid_classes_with_only_static_members
+import 'package:firebase_core/firebase_core.dart' show FirebaseOptions;
+import 'package:flutter/foundation.dart' show defaultTargetPlatform, kIsWeb, TargetPlatform;
+
+/// Default [FirebaseOptions] for use with your Firebase apps.
+///
+/// Example:
+/// ```dart
+/// import 'firebase_options.dart';
+/// // ...
+/// await Firebase.initializeApp(
+/// options: DefaultFirebaseOptions.currentPlatform,
+/// );
+/// ```
+class DefaultFirebaseOptions {
+ static FirebaseOptions get currentPlatform {
+ if (kIsWeb) {
+ throw UnsupportedError(
+ 'DefaultFirebaseOptions have not been configured for web - '
+ 'you can reconfigure this by running the FlutterFire CLI again.',
+ );
+ }
+ switch (defaultTargetPlatform) {
+ case TargetPlatform.android:
+ return android;
+ case TargetPlatform.iOS:
+ return ios;
+ case TargetPlatform.macOS:
+ return macos;
+ case TargetPlatform.windows:
+ throw UnsupportedError(
+ 'DefaultFirebaseOptions have not been configured for windows - '
+ 'you can reconfigure this by running the FlutterFire CLI again.',
+ );
+ case TargetPlatform.linux:
+ throw UnsupportedError(
+ 'DefaultFirebaseOptions have not been configured for linux - '
+ 'you can reconfigure this by running the FlutterFire CLI again.',
+ );
+ default:
+ throw UnsupportedError(
+ 'DefaultFirebaseOptions are not supported for this platform.',
+ );
+ }
+ }
+
+ static const FirebaseOptions android = FirebaseOptions(
+ apiKey: 'AIzaSyCDI7arcBp4uriwfLySgqrchkNVDVW94uk',
+ appId: '1:237191932527:android:651be56a933e8bda36bb9a',
+ messagingSenderId: '237191932527',
+ projectId: 'project-3195624368411891722',
+ storageBucket: 'project-3195624368411891722.appspot.com',
+ );
+
+ static const FirebaseOptions ios = FirebaseOptions(
+ apiKey: 'AIzaSyD1FiZUHkX-rdHUtAXU12ku2e7zmBHqLSQ',
+ appId: '1:237191932527:ios:ed5586aaa838be1e36bb9a',
+ messagingSenderId: '237191932527',
+ projectId: 'project-3195624368411891722',
+ storageBucket: 'project-3195624368411891722.appspot.com',
+ iosClientId: '237191932527-70uoogr06k3rrrmslr5u1r6i4st9ch39.apps.googleusercontent.com',
+ iosBundleId: 'finance.get10101.app',
+ );
+
+ static const FirebaseOptions macos = FirebaseOptions(
+ apiKey: 'AIzaSyD1FiZUHkX-rdHUtAXU12ku2e7zmBHqLSQ',
+ appId: '1:237191932527:ios:ed5586aaa838be1e36bb9a',
+ messagingSenderId: '237191932527',
+ projectId: 'project-3195624368411891722',
+ storageBucket: 'project-3195624368411891722.appspot.com',
+ iosClientId: '237191932527-70uoogr06k3rrrmslr5u1r6i4st9ch39.apps.googleusercontent.com',
+ iosBundleId: 'finance.get10101.app',
+ );
+}
diff --git a/mobile/lib/main.dart b/mobile/lib/main.dart
index 480bca2af..30f9c1679 100644
--- a/mobile/lib/main.dart
+++ b/mobile/lib/main.dart
@@ -1,7 +1,10 @@
import 'dart:convert';
-
import 'package:f_logs/f_logs.dart';
+import 'package:firebase_core/firebase_core.dart';
+import 'package:firebase_messaging/firebase_messaging.dart';
+import 'package:flutter_local_notifications/flutter_local_notifications.dart';
import 'package:flutter/material.dart';
+import 'package:get_10101/firebase_options.dart';
import 'dart:io';
import 'package:http/http.dart' as http;
import 'package:flutter_native_splash/flutter_native_splash.dart';
@@ -233,6 +236,11 @@ class _TenTenOneAppState extends State {
init(config);
WidgetsBinding.instance.addPostFrameCallback((_) async {
+ await initFirebase();
+ await requestNotificationPermission();
+ final flutterLocalNotificationsPlugin = initLocalNotifications();
+ await configureFirebase(flutterLocalNotificationsPlugin);
+
PackageInfo packageInfo = await PackageInfo.fromPlatform();
final messenger = scaffoldMessengerKey.currentState!;
@@ -500,5 +508,111 @@ Future runBackend(bridge.Config config) async {
FLog.info(text: "App data will be stored in: $appDir");
FLog.info(text: "Seed data will be stored in: $seedDir");
- await rust.api.runInFlutter(config: config, appDir: appDir, seedDir: seedDir);
+ await startBackend(config: config, appDir: appDir, seedDir: seedDir);
+}
+
+FlutterLocalNotificationsPlugin initLocalNotifications() {
+ final flutterLocalNotificationsPlugin = FlutterLocalNotificationsPlugin();
+ const androidSettings = AndroidInitializationSettings('@mipmap/ic_launcher');
+ const darwinSettings = DarwinInitializationSettings();
+ const initializationSettings =
+ InitializationSettings(android: androidSettings, macOS: darwinSettings, iOS: darwinSettings);
+ flutterLocalNotificationsPlugin.initialize(initializationSettings);
+ return flutterLocalNotificationsPlugin;
+}
+
+Future initFirebase() async {
+ await Firebase.initializeApp(
+ options: DefaultFirebaseOptions.currentPlatform,
+ );
+}
+
+Future configureFirebase(FlutterLocalNotificationsPlugin localNotifications) async {
+ // Configure message handler
+ FirebaseMessaging.onMessage.listen((RemoteMessage message) {
+ // TODO: Handle messages from Firebase
+ FLog.debug(text: "Firebase message received: ${message.data}");
+
+ if (message.notification != null) {
+ FLog.debug(text: "Message also contained a notification: ${message.notification}");
+ showNotification(message.notification!.toMap(), localNotifications);
+ }
+ });
+
+ FirebaseMessaging messaging = FirebaseMessaging.instance;
+ // Subscribe to topic "all" to receive all messages
+ messaging.subscribeToTopic('all');
+}
+
+/// Ask the user for permission to send notifications via Firebase
+Future requestNotificationPermission() async {
+ FirebaseMessaging messaging = FirebaseMessaging.instance;
+ final token = await messaging.getToken();
+ FLog.info(text: "Firebase token: $token");
+
+ NotificationSettings settings = await messaging.requestPermission(
+ alert: true,
+ announcement: false,
+ badge: true,
+ carPlay: false,
+ criticalAlert: false,
+ provisional: false,
+ sound: true,
+ );
+
+ FLog.info(text: "User granted permission: ${settings.authorizationStatus}");
+}
+
+/// Start the backend and retry a number of times if it fails for whatever reason
+Future startBackend({config, appDir, seedDir}) async {
+ int retries = 3;
+
+ for (int i = 0; i < retries; i++) {
+ try {
+ await rust.api.runInFlutter(config: config, appDir: appDir, seedDir: seedDir);
+ break; // If successful, exit loop
+ } catch (e) {
+ FLog.info(text: "Attempt ${i + 1} failed: $e");
+ if (i < retries - 1) {
+ await Future.delayed(const Duration(seconds: 5));
+ } else {
+ FLog.error(text: "Max retries reached, backend could not start.");
+ exit(-1);
+ }
+ }
+ }
+}
+
+/// Display notification inside the `message` using the local notification plugin
+void showNotification(
+ Map message, FlutterLocalNotificationsPlugin localNotifications) async {
+ const androidPlatformChannelSpecifics = AndroidNotificationDetails(
+ 'channel_id',
+ 'channel_name',
+ channelDescription: 'channel_description',
+ importance: Importance.max,
+ priority: Priority.high,
+ );
+
+ const darwinPlatformChannelSpecifics = DarwinNotificationDetails(
+ presentAlert: true,
+ presentBadge: true,
+ presentSound: true,
+ );
+
+ const platformChannelSpecifics = NotificationDetails(
+ android: androidPlatformChannelSpecifics,
+ iOS: darwinPlatformChannelSpecifics,
+ macOS: darwinPlatformChannelSpecifics,
+ );
+
+ FLog.debug(text: "Showing notification: ${message['title']} with body ${message['body']}");
+
+ await localNotifications.show(
+ 0,
+ message['title'],
+ message['body'],
+ platformChannelSpecifics,
+ payload: 'item x',
+ );
}
diff --git a/mobile/macos/Flutter/GeneratedPluginRegistrant.swift b/mobile/macos/Flutter/GeneratedPluginRegistrant.swift
index 57446ae12..005839299 100644
--- a/mobile/macos/Flutter/GeneratedPluginRegistrant.swift
+++ b/mobile/macos/Flutter/GeneratedPluginRegistrant.swift
@@ -5,12 +5,18 @@
import FlutterMacOS
import Foundation
+import firebase_core
+import firebase_messaging
+import flutter_local_notifications
import package_info_plus
import path_provider_foundation
import share_plus
import shared_preferences_foundation
func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) {
+ FLTFirebaseCorePlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseCorePlugin"))
+ FLTFirebaseMessagingPlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseMessagingPlugin"))
+ FlutterLocalNotificationsPlugin.register(with: registry.registrar(forPlugin: "FlutterLocalNotificationsPlugin"))
FLTPackageInfoPlusPlugin.register(with: registry.registrar(forPlugin: "FLTPackageInfoPlusPlugin"))
PathProviderPlugin.register(with: registry.registrar(forPlugin: "PathProviderPlugin"))
SharePlusMacosPlugin.register(with: registry.registrar(forPlugin: "SharePlusMacosPlugin"))
diff --git a/mobile/macos/Podfile.lock b/mobile/macos/Podfile.lock
index e477f41bc..0e6b9801b 100644
--- a/mobile/macos/Podfile.lock
+++ b/mobile/macos/Podfile.lock
@@ -1,10 +1,70 @@
PODS:
+ - Firebase/CoreOnly (10.12.0):
+ - FirebaseCore (= 10.12.0)
+ - Firebase/Messaging (10.12.0):
+ - Firebase/CoreOnly
+ - FirebaseMessaging (~> 10.12.0)
+ - firebase_core (2.15.0):
+ - Firebase/CoreOnly (~> 10.12.0)
+ - FlutterMacOS
+ - firebase_messaging (14.6.5):
+ - Firebase/CoreOnly (~> 10.12.0)
+ - Firebase/Messaging (~> 10.12.0)
+ - firebase_core
+ - FlutterMacOS
+ - FirebaseCore (10.12.0):
+ - FirebaseCoreInternal (~> 10.0)
+ - GoogleUtilities/Environment (~> 7.8)
+ - GoogleUtilities/Logger (~> 7.8)
+ - FirebaseCoreInternal (10.13.0):
+ - "GoogleUtilities/NSData+zlib (~> 7.8)"
+ - FirebaseInstallations (10.13.0):
+ - FirebaseCore (~> 10.0)
+ - GoogleUtilities/Environment (~> 7.8)
+ - GoogleUtilities/UserDefaults (~> 7.8)
+ - PromisesObjC (~> 2.1)
+ - FirebaseMessaging (10.12.0):
+ - FirebaseCore (~> 10.0)
+ - FirebaseInstallations (~> 10.0)
+ - GoogleDataTransport (~> 9.2)
+ - GoogleUtilities/AppDelegateSwizzler (~> 7.8)
+ - GoogleUtilities/Environment (~> 7.8)
+ - GoogleUtilities/Reachability (~> 7.8)
+ - GoogleUtilities/UserDefaults (~> 7.8)
+ - nanopb (< 2.30910.0, >= 2.30908.0)
- FlutterMacOS (1.0.0)
+ - GoogleDataTransport (9.2.5):
+ - GoogleUtilities/Environment (~> 7.7)
+ - nanopb (< 2.30910.0, >= 2.30908.0)
+ - PromisesObjC (< 3.0, >= 1.2)
+ - GoogleUtilities/AppDelegateSwizzler (7.11.5):
+ - GoogleUtilities/Environment
+ - GoogleUtilities/Logger
+ - GoogleUtilities/Network
+ - GoogleUtilities/Environment (7.11.5):
+ - PromisesObjC (< 3.0, >= 1.2)
+ - GoogleUtilities/Logger (7.11.5):
+ - GoogleUtilities/Environment
+ - GoogleUtilities/Network (7.11.5):
+ - GoogleUtilities/Logger
+ - "GoogleUtilities/NSData+zlib"
+ - GoogleUtilities/Reachability
+ - "GoogleUtilities/NSData+zlib (7.11.5)"
+ - GoogleUtilities/Reachability (7.11.5):
+ - GoogleUtilities/Logger
+ - GoogleUtilities/UserDefaults (7.11.5):
+ - GoogleUtilities/Logger
+ - nanopb (2.30909.0):
+ - nanopb/decode (= 2.30909.0)
+ - nanopb/encode (= 2.30909.0)
+ - nanopb/decode (2.30909.0)
+ - nanopb/encode (2.30909.0)
- package_info_plus (0.0.1):
- FlutterMacOS
- path_provider_foundation (0.0.1):
- Flutter
- FlutterMacOS
+ - PromisesObjC (2.3.1)
- share_plus (0.0.1):
- FlutterMacOS
- shared_preferences_foundation (0.0.1):
@@ -12,13 +72,31 @@ PODS:
- FlutterMacOS
DEPENDENCIES:
+ - firebase_core (from `Flutter/ephemeral/.symlinks/plugins/firebase_core/macos`)
+ - firebase_messaging (from `Flutter/ephemeral/.symlinks/plugins/firebase_messaging/macos`)
- FlutterMacOS (from `Flutter/ephemeral`)
- package_info_plus (from `Flutter/ephemeral/.symlinks/plugins/package_info_plus/macos`)
- path_provider_foundation (from `Flutter/ephemeral/.symlinks/plugins/path_provider_foundation/darwin`)
- share_plus (from `Flutter/ephemeral/.symlinks/plugins/share_plus/macos`)
- shared_preferences_foundation (from `Flutter/ephemeral/.symlinks/plugins/shared_preferences_foundation/darwin`)
+SPEC REPOS:
+ trunk:
+ - Firebase
+ - FirebaseCore
+ - FirebaseCoreInternal
+ - FirebaseInstallations
+ - FirebaseMessaging
+ - GoogleDataTransport
+ - GoogleUtilities
+ - nanopb
+ - PromisesObjC
+
EXTERNAL SOURCES:
+ firebase_core:
+ :path: Flutter/ephemeral/.symlinks/plugins/firebase_core/macos
+ firebase_messaging:
+ :path: Flutter/ephemeral/.symlinks/plugins/firebase_messaging/macos
FlutterMacOS:
:path: Flutter/ephemeral
package_info_plus:
@@ -31,9 +109,20 @@ EXTERNAL SOURCES:
:path: Flutter/ephemeral/.symlinks/plugins/shared_preferences_foundation/darwin
SPEC CHECKSUMS:
+ Firebase: 07150e75d142fb9399f6777fa56a187b17f833a0
+ firebase_core: ff59797157ca9adda4440071643761b41fcd03b3
+ firebase_messaging: d489df2f5cf5eb4b1ffb0b920f1d8c6b911f6166
+ FirebaseCore: f86a1394906b97ac445ae49c92552a9425831bed
+ FirebaseCoreInternal: b342e37cd4f5b4454ec34308f073420e7920858e
+ FirebaseInstallations: b28af1b9f997f1a799efe818c94695a3728c352f
+ FirebaseMessaging: bb2c4f6422a753038fe137d90ae7c1af57251316
FlutterMacOS: 8f6f14fa908a6fb3fba0cd85dbd81ec4b251fb24
+ GoogleDataTransport: 54dee9d48d14580407f8f5fbf2f496e92437a2f2
+ GoogleUtilities: 13e2c67ede716b8741c7989e26893d151b2b2084
+ nanopb: b552cce312b6c8484180ef47159bc0f65a1f0431
package_info_plus: 02d7a575e80f194102bef286361c6c326e4c29ce
path_provider_foundation: eaf5b3e458fc0e5fbb9940fb09980e853fe058b8
+ PromisesObjC: c50d2056b5253dadbd6c2bea79b0674bd5a52fa4
share_plus: 76dd39142738f7a68dd57b05093b5e8193f220f7
shared_preferences_foundation: 5b919d13b803cadd15ed2dc053125c68730e5126
diff --git a/mobile/macos/Runner.xcodeproj/project.pbxproj b/mobile/macos/Runner.xcodeproj/project.pbxproj
index 67771ccc8..d74ef7d5a 100644
--- a/mobile/macos/Runner.xcodeproj/project.pbxproj
+++ b/mobile/macos/Runner.xcodeproj/project.pbxproj
@@ -28,6 +28,7 @@
33CC10F62044A3C60003C045 /* MainMenu.xib in Resources */ = {isa = PBXBuildFile; fileRef = 33CC10F42044A3C60003C045 /* MainMenu.xib */; };
33CC11132044BFA00003C045 /* MainFlutterWindow.swift in Sources */ = {isa = PBXBuildFile; fileRef = 33CC11122044BFA00003C045 /* MainFlutterWindow.swift */; };
A3D4964229384C8700FB0055 /* libnative_static.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A3D4963929384B5900FB0055 /* libnative_static.a */; };
+ BAE42EF86802724F1F2B5773 /* GoogleService-Info.plist in Resources */ = {isa = PBXBuildFile; fileRef = 364FAF5CA96245E001E42EE9 /* GoogleService-Info.plist */; };
/* End PBXBuildFile section */
/* Begin PBXContainerItemProxy section */
@@ -90,6 +91,7 @@
33E51913231747F40026EE4D /* DebugProfile.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = DebugProfile.entitlements; sourceTree = ""; };
33E51914231749380026EE4D /* Release.entitlements */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.entitlements; path = Release.entitlements; sourceTree = ""; };
33E5194F232828860026EE4D /* AppInfo.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = AppInfo.xcconfig; sourceTree = ""; };
+ 364FAF5CA96245E001E42EE9 /* GoogleService-Info.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; name = "GoogleService-Info.plist"; path = "Runner/GoogleService-Info.plist"; sourceTree = ""; };
40CE64B92307151D59147524 /* Pods-Runner.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.debug.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"; sourceTree = ""; };
5F94F1C162CEF0CE7D5CA1E6 /* Pods_Runner.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Runner.framework; sourceTree = BUILT_PRODUCTS_DIR; };
7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = Release.xcconfig; sourceTree = ""; };
@@ -132,6 +134,7 @@
D73912EC22F37F3D000D13A0 /* Frameworks */,
A352534B2866B29F00EFD9C6 /* native.xcodeproj */,
D27D4D37C9F24EFEE11BF2A9 /* Pods */,
+ 364FAF5CA96245E001E42EE9 /* GoogleService-Info.plist */,
);
sourceTree = "";
};
@@ -308,6 +311,7 @@
files = (
33CC10F32044A3C60003C045 /* Assets.xcassets in Resources */,
33CC10F62044A3C60003C045 /* MainMenu.xib in Resources */,
+ BAE42EF86802724F1F2B5773 /* GoogleService-Info.plist in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@@ -492,10 +496,10 @@
"$(inherited)",
"@executable_path/../Frameworks",
);
- OTHER_LDFLAGS = (
+ OTHER_LDFLAGS = (
"$(inherited)",
- "-lsqlite3",
- );
+ "-lsqlite3",
+ );
PROVISIONING_PROFILE_SPECIFIER = "";
SWIFT_OBJC_BRIDGING_HEADER = Runner/bridge_generated.h;
SWIFT_VERSION = 5.0;
@@ -623,10 +627,10 @@
"$(inherited)",
"@executable_path/../Frameworks",
);
- OTHER_LDFLAGS = (
- "$(inherited)",
- "-lsqlite3",
- );
+ OTHER_LDFLAGS = (
+ "$(inherited)",
+ "-lsqlite3",
+ );
PROVISIONING_PROFILE_SPECIFIER = "";
SWIFT_OBJC_BRIDGING_HEADER = Runner/bridge_generated.h;
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
@@ -648,10 +652,10 @@
"$(inherited)",
"@executable_path/../Frameworks",
);
- OTHER_LDFLAGS = (
- "$(inherited)",
- "-lsqlite3",
- );
+ OTHER_LDFLAGS = (
+ "$(inherited)",
+ "-lsqlite3",
+ );
PROVISIONING_PROFILE_SPECIFIER = "";
SWIFT_OBJC_BRIDGING_HEADER = Runner/bridge_generated.h;
SWIFT_VERSION = 5.0;
diff --git a/mobile/macos/Runner/GoogleService-Info.plist b/mobile/macos/Runner/GoogleService-Info.plist
new file mode 100644
index 000000000..98cac5bce
--- /dev/null
+++ b/mobile/macos/Runner/GoogleService-Info.plist
@@ -0,0 +1,34 @@
+
+
+
+
+ CLIENT_ID
+ 237191932527-70uoogr06k3rrrmslr5u1r6i4st9ch39.apps.googleusercontent.com
+ REVERSED_CLIENT_ID
+ com.googleusercontent.apps.237191932527-70uoogr06k3rrrmslr5u1r6i4st9ch39
+ API_KEY
+ AIzaSyD1FiZUHkX-rdHUtAXU12ku2e7zmBHqLSQ
+ GCM_SENDER_ID
+ 237191932527
+ PLIST_VERSION
+ 1
+ BUNDLE_ID
+ finance.get10101.app
+ PROJECT_ID
+ project-3195624368411891722
+ STORAGE_BUCKET
+ project-3195624368411891722.appspot.com
+ IS_ADS_ENABLED
+
+ IS_ANALYTICS_ENABLED
+
+ IS_APPINVITE_ENABLED
+
+ IS_GCM_ENABLED
+
+ IS_SIGNIN_ENABLED
+
+ GOOGLE_APP_ID
+ 1:237191932527:ios:ed5586aaa838be1e36bb9a
+
+
\ No newline at end of file
diff --git a/mobile/macos/firebase_app_id_file.json b/mobile/macos/firebase_app_id_file.json
new file mode 100644
index 000000000..8b69b6632
--- /dev/null
+++ b/mobile/macos/firebase_app_id_file.json
@@ -0,0 +1,7 @@
+{
+ "file_generated_by": "FlutterFire CLI",
+ "purpose": "FirebaseAppID & ProjectID for this Firebase app in this directory",
+ "GOOGLE_APP_ID": "1:237191932527:ios:ed5586aaa838be1e36bb9a",
+ "FIREBASE_PROJECT_ID": "project-3195624368411891722",
+ "GCM_SENDER_ID": "237191932527"
+}
diff --git a/mobile/native/src/api.rs b/mobile/native/src/api.rs
index eae549fbf..5d085b6e1 100644
--- a/mobile/native/src/api.rs
+++ b/mobile/native/src/api.rs
@@ -191,13 +191,10 @@ pub fn subscribe(stream: StreamSink) {
event::subscribe(FlutterSubscriber::new(stream))
}
-/// Wrapper for Flutter purposes, it ensures we do not return a Result, which
-/// would have otherwise be converted into an exception.
-/// There is no recovery possible, and panicking is the only option ensuring
-/// that we will get an adequate crash report.
-pub fn run_in_flutter(config: Config, app_dir: String, seed_dir: String) {
+/// Wrapper for Flutter purposes - can throw an exception.
+pub fn run_in_flutter(config: Config, app_dir: String, seed_dir: String) -> Result<()> {
run(config, app_dir, seed_dir, IncludeBacktraceOnPanic::Yes)
- .expect("Failed to start the backend");
+ .context("Failed to start the backend")
}
#[derive(PartialEq)]
diff --git a/mobile/pubspec.lock b/mobile/pubspec.lock
index b9dc3a870..051a983a7 100644
--- a/mobile/pubspec.lock
+++ b/mobile/pubspec.lock
@@ -9,6 +9,14 @@ packages:
url: "https://pub.dev"
source: hosted
version: "61.0.0"
+ _flutterfire_internals:
+ dependency: transitive
+ description:
+ name: _flutterfire_internals
+ sha256: "5dce45a06d386358334eb1689108db6455d90ceb0d75848d5f4819283d4ee2b8"
+ url: "https://pub.dev"
+ source: hosted
+ version: "1.3.4"
analyzer:
dependency: transitive
description:
@@ -249,6 +257,14 @@ packages:
url: "https://pub.dev"
source: hosted
version: "2.3.2"
+ dbus:
+ dependency: transitive
+ description:
+ name: dbus
+ sha256: "6f07cba3f7b3448d42d015bfd3d53fe12e5b36da2423f23838efc1d5fb31a263"
+ url: "https://pub.dev"
+ source: hosted
+ version: "0.7.8"
decimal:
dependency: "direct main"
description:
@@ -305,6 +321,54 @@ packages:
url: "https://pub.dev"
source: hosted
version: "6.1.4"
+ firebase_core:
+ dependency: "direct main"
+ description:
+ name: firebase_core
+ sha256: "2e9324f719e90200dc7d3c4f5d2abc26052f9f2b995d3b6626c47a0dfe1c8192"
+ url: "https://pub.dev"
+ source: hosted
+ version: "2.15.0"
+ firebase_core_platform_interface:
+ dependency: transitive
+ description:
+ name: firebase_core_platform_interface
+ sha256: b63e3be6c96ef5c33bdec1aab23c91eb00696f6452f0519401d640938c94cba2
+ url: "https://pub.dev"
+ source: hosted
+ version: "4.8.0"
+ firebase_core_web:
+ dependency: transitive
+ description:
+ name: firebase_core_web
+ sha256: "0fd5c4b228de29b55fac38aed0d9e42514b3d3bd47675de52bf7f8fccaf922fa"
+ url: "https://pub.dev"
+ source: hosted
+ version: "2.6.0"
+ firebase_messaging:
+ dependency: "direct main"
+ description:
+ name: firebase_messaging
+ sha256: "8ac91d83a028eef050de770f1dc98421e215714d245f34de7b154d436676fbd0"
+ url: "https://pub.dev"
+ source: hosted
+ version: "14.6.5"
+ firebase_messaging_platform_interface:
+ dependency: transitive
+ description:
+ name: firebase_messaging_platform_interface
+ sha256: b2995e3640efb646e9ebf0e2fa50dea84895f0746a31d7e3af0e5e009a533a1a
+ url: "https://pub.dev"
+ source: hosted
+ version: "4.5.4"
+ firebase_messaging_web:
+ dependency: transitive
+ description:
+ name: firebase_messaging_web
+ sha256: "5d8446a28339124a2cb4f57a6ca454a3aca7d0c5c0cdfa5707afb192f7c830a7"
+ url: "https://pub.dev"
+ source: hosted
+ version: "3.5.4"
fixnum:
dependency: transitive
description:
@@ -334,6 +398,30 @@ packages:
url: "https://pub.dev"
source: hosted
version: "2.0.2"
+ flutter_local_notifications:
+ dependency: "direct main"
+ description:
+ name: flutter_local_notifications
+ sha256: "3cc40fe8c50ab8383f3e053a499f00f975636622ecdc8e20a77418ece3b1e975"
+ url: "https://pub.dev"
+ source: hosted
+ version: "15.1.0+1"
+ flutter_local_notifications_linux:
+ dependency: transitive
+ description:
+ name: flutter_local_notifications_linux
+ sha256: "33f741ef47b5f63cc7f78fe75eeeac7e19f171ff3c3df054d84c1e38bedb6a03"
+ url: "https://pub.dev"
+ source: hosted
+ version: "4.0.0+1"
+ flutter_local_notifications_platform_interface:
+ dependency: transitive
+ description:
+ name: flutter_local_notifications_platform_interface
+ sha256: "7cf643d6d5022f3baed0be777b0662cce5919c0a7b86e700299f22dc4ae660ef"
+ url: "https://pub.dev"
+ source: hosted
+ version: "7.0.0+1"
flutter_native_splash:
dependency: "direct main"
description:
@@ -1013,6 +1101,14 @@ packages:
url: "https://pub.dev"
source: hosted
version: "3.3.0"
+ timezone:
+ dependency: transitive
+ description:
+ name: timezone
+ sha256: "1cfd8ddc2d1cfd836bc93e67b9be88c3adaeca6f40a00ca999104c30693cdca0"
+ url: "https://pub.dev"
+ source: hosted
+ version: "0.9.2"
timing:
dependency: transitive
description:
diff --git a/mobile/pubspec.yaml b/mobile/pubspec.yaml
index 707d77401..a807d6a7f 100644
--- a/mobile/pubspec.yaml
+++ b/mobile/pubspec.yaml
@@ -35,6 +35,9 @@ dependencies:
social_share: ^2.3.1
test: ^1.24.1
version: ^3.0.2
+ firebase_core: ^2.15.0
+ firebase_messaging: ^14.6.5
+ flutter_local_notifications: ^15.1.0+1
dev_dependencies:
flutter_launcher_icons: ^0.13.1
flutter_test:
diff --git a/mobile/windows/flutter/generated_plugin_registrant.cc b/mobile/windows/flutter/generated_plugin_registrant.cc
index c3384ec52..c3d3b6add 100644
--- a/mobile/windows/flutter/generated_plugin_registrant.cc
+++ b/mobile/windows/flutter/generated_plugin_registrant.cc
@@ -6,10 +6,13 @@
#include "generated_plugin_registrant.h"
+#include
#include
#include
void RegisterPlugins(flutter::PluginRegistry* registry) {
+ FirebaseCorePluginCApiRegisterWithRegistrar(
+ registry->GetRegistrarForPlugin("FirebaseCorePluginCApi"));
SharePlusWindowsPluginCApiRegisterWithRegistrar(
registry->GetRegistrarForPlugin("SharePlusWindowsPluginCApi"));
UrlLauncherWindowsRegisterWithRegistrar(
diff --git a/mobile/windows/flutter/generated_plugins.cmake b/mobile/windows/flutter/generated_plugins.cmake
index 01d383628..c04ddae9c 100644
--- a/mobile/windows/flutter/generated_plugins.cmake
+++ b/mobile/windows/flutter/generated_plugins.cmake
@@ -3,6 +3,7 @@
#
list(APPEND FLUTTER_PLUGIN_LIST
+ firebase_core
share_plus
url_launcher_windows
)