implements notification
This commit is contained in:
@@ -7,12 +7,15 @@
|
||||
// ignore_for_file: type=lint
|
||||
|
||||
import 'package:connectivity_plus/src/connectivity_plus_web.dart';
|
||||
import 'package:firebase_core_web/firebase_core_web.dart';
|
||||
import 'package:firebase_messaging_web/firebase_messaging_web.dart';
|
||||
import 'package:flutter_inappwebview_web/web/main.dart';
|
||||
import 'package:fluttertoast/fluttertoast_web.dart';
|
||||
import 'package:geolocator_web/geolocator_web.dart';
|
||||
import 'package:google_maps_flutter_web/google_maps_flutter_web.dart';
|
||||
import 'package:image_picker_for_web/image_picker_for_web.dart';
|
||||
import 'package:package_info_plus/src/package_info_plus_web.dart';
|
||||
import 'package:permission_handler_html/permission_handler_html.dart';
|
||||
import 'package:shared_preferences_web/shared_preferences_web.dart';
|
||||
import 'package:url_launcher_web/url_launcher_web.dart';
|
||||
import 'package:flutter_web_plugins/flutter_web_plugins.dart';
|
||||
@@ -20,12 +23,15 @@ import 'package:flutter_web_plugins/flutter_web_plugins.dart';
|
||||
void registerPlugins([final Registrar? pluginRegistrar]) {
|
||||
final Registrar registrar = pluginRegistrar ?? webPluginRegistrar;
|
||||
ConnectivityPlusWebPlugin.registerWith(registrar);
|
||||
FirebaseCoreWeb.registerWith(registrar);
|
||||
FirebaseMessagingWeb.registerWith(registrar);
|
||||
InAppWebViewFlutterPlugin.registerWith(registrar);
|
||||
FluttertoastWebPlugin.registerWith(registrar);
|
||||
GeolocatorPlugin.registerWith(registrar);
|
||||
GoogleMapsPlugin.registerWith(registrar);
|
||||
ImagePickerPlugin.registerWith(registrar);
|
||||
PackageInfoPlusWebPlugin.registerWith(registrar);
|
||||
WebPermissionHandler.registerWith(registrar);
|
||||
SharedPreferencesPlugin.registerWith(registrar);
|
||||
UrlLauncherPlugin.registerWith(registrar);
|
||||
registrar.registerMessageHandler();
|
||||
|
||||
@@ -1,31 +0,0 @@
|
||||
Extension Discovery Cache
|
||||
=========================
|
||||
|
||||
This folder is used by `package:extension_discovery` to cache lists of
|
||||
packages that contains extensions for other packages.
|
||||
|
||||
DO NOT USE THIS FOLDER
|
||||
----------------------
|
||||
|
||||
* Do not read (or rely) the contents of this folder.
|
||||
* Do write to this folder.
|
||||
|
||||
If you're interested in the lists of extensions stored in this folder use the
|
||||
API offered by package `extension_discovery` to get this information.
|
||||
|
||||
If this package doesn't work for your use-case, then don't try to read the
|
||||
contents of this folder. It may change, and will not remain stable.
|
||||
|
||||
Use package `extension_discovery`
|
||||
---------------------------------
|
||||
|
||||
If you want to access information from this folder.
|
||||
|
||||
Feel free to delete this folder
|
||||
-------------------------------
|
||||
|
||||
Files in this folder act as a cache, and the cache is discarded if the files
|
||||
are older than the modification time of `.dart_tool/package_config.json`.
|
||||
|
||||
Hence, it should never be necessary to clear this cache manually, if you find a
|
||||
need to do please file a bug.
|
||||
@@ -1 +0,0 @@
|
||||
{"version":2,"entries":[{"package":"grocery_app","rootUri":"../","packageUri":"lib/"}]}
|
||||
452
.dart_tool/flutter_build/dart_plugin_registrant.dart
Normal file
452
.dart_tool/flutter_build/dart_plugin_registrant.dart
Normal file
@@ -0,0 +1,452 @@
|
||||
//
|
||||
// Generated file. Do not edit.
|
||||
// This file is generated from template in file `flutter_tools/lib/src/flutter_plugins.dart`.
|
||||
//
|
||||
|
||||
// @dart = 3.4
|
||||
|
||||
import 'dart:io'; // flutter_ignore: dart_io_import.
|
||||
import 'package:flutter_inappwebview_android/flutter_inappwebview_android.dart';
|
||||
import 'package:flutter_local_notifications/flutter_local_notifications.dart';
|
||||
import 'package:geocoding_android/geocoding_android.dart';
|
||||
import 'package:geolocator_android/geolocator_android.dart';
|
||||
import 'package:google_maps_flutter_android/google_maps_flutter_android.dart';
|
||||
import 'package:image_picker_android/image_picker_android.dart';
|
||||
import 'package:path_provider_android/path_provider_android.dart';
|
||||
import 'package:shared_preferences_android/shared_preferences_android.dart';
|
||||
import 'package:sqflite/sqflite.dart';
|
||||
import 'package:url_launcher_android/url_launcher_android.dart';
|
||||
import 'package:flutter_inappwebview_ios/flutter_inappwebview_ios.dart';
|
||||
import 'package:flutter_local_notifications/flutter_local_notifications.dart';
|
||||
import 'package:geocoding_ios/geocoding_ios.dart';
|
||||
import 'package:geolocator_apple/geolocator_apple.dart';
|
||||
import 'package:google_maps_flutter_ios/google_maps_flutter_ios.dart';
|
||||
import 'package:image_picker_ios/image_picker_ios.dart';
|
||||
import 'package:path_provider_foundation/path_provider_foundation.dart';
|
||||
import 'package:shared_preferences_foundation/shared_preferences_foundation.dart';
|
||||
import 'package:sqflite/sqflite.dart';
|
||||
import 'package:url_launcher_ios/url_launcher_ios.dart';
|
||||
import 'package:connectivity_plus/connectivity_plus.dart';
|
||||
import 'package:file_selector_linux/file_selector_linux.dart';
|
||||
import 'package:flutter_local_notifications_linux/flutter_local_notifications_linux.dart';
|
||||
import 'package:image_picker_linux/image_picker_linux.dart';
|
||||
import 'package:package_info_plus/package_info_plus.dart';
|
||||
import 'package:path_provider_linux/path_provider_linux.dart';
|
||||
import 'package:shared_preferences_linux/shared_preferences_linux.dart';
|
||||
import 'package:url_launcher_linux/url_launcher_linux.dart';
|
||||
import 'package:file_selector_macos/file_selector_macos.dart';
|
||||
import 'package:flutter_inappwebview_macos/flutter_inappwebview_macos.dart';
|
||||
import 'package:flutter_local_notifications/flutter_local_notifications.dart';
|
||||
import 'package:geolocator_apple/geolocator_apple.dart';
|
||||
import 'package:image_picker_macos/image_picker_macos.dart';
|
||||
import 'package:path_provider_foundation/path_provider_foundation.dart';
|
||||
import 'package:shared_preferences_foundation/shared_preferences_foundation.dart';
|
||||
import 'package:sqflite/sqflite.dart';
|
||||
import 'package:url_launcher_macos/url_launcher_macos.dart';
|
||||
import 'package:file_selector_windows/file_selector_windows.dart';
|
||||
import 'package:image_picker_windows/image_picker_windows.dart';
|
||||
import 'package:package_info_plus/package_info_plus.dart';
|
||||
import 'package:path_provider_windows/path_provider_windows.dart';
|
||||
import 'package:shared_preferences_windows/shared_preferences_windows.dart';
|
||||
import 'package:url_launcher_windows/url_launcher_windows.dart';
|
||||
|
||||
@pragma('vm:entry-point')
|
||||
class _PluginRegistrant {
|
||||
|
||||
@pragma('vm:entry-point')
|
||||
static void register() {
|
||||
if (Platform.isAndroid) {
|
||||
try {
|
||||
AndroidInAppWebViewPlatform.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`flutter_inappwebview_android` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
AndroidFlutterLocalNotificationsPlugin.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`flutter_local_notifications` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
GeocodingAndroid.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`geocoding_android` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
GeolocatorAndroid.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`geolocator_android` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
GoogleMapsFlutterAndroid.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`google_maps_flutter_android` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
ImagePickerAndroid.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`image_picker_android` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
PathProviderAndroid.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`path_provider_android` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
SharedPreferencesAndroid.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`shared_preferences_android` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
SqflitePlugin.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`sqflite` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
UrlLauncherAndroid.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`url_launcher_android` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
} else if (Platform.isIOS) {
|
||||
try {
|
||||
IOSInAppWebViewPlatform.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`flutter_inappwebview_ios` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
IOSFlutterLocalNotificationsPlugin.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`flutter_local_notifications` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
GeocodingIOS.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`geocoding_ios` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
GeolocatorApple.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`geolocator_apple` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
GoogleMapsFlutterIOS.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`google_maps_flutter_ios` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
ImagePickerIOS.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`image_picker_ios` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
PathProviderFoundation.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`path_provider_foundation` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
SharedPreferencesFoundation.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`shared_preferences_foundation` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
SqflitePlugin.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`sqflite` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
UrlLauncherIOS.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`url_launcher_ios` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
} else if (Platform.isLinux) {
|
||||
try {
|
||||
ConnectivityPlusLinuxPlugin.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`connectivity_plus` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
FileSelectorLinux.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`file_selector_linux` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
LinuxFlutterLocalNotificationsPlugin.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`flutter_local_notifications_linux` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
ImagePickerLinux.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`image_picker_linux` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
PackageInfoPlusLinuxPlugin.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`package_info_plus` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
PathProviderLinux.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`path_provider_linux` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
SharedPreferencesLinux.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`shared_preferences_linux` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
UrlLauncherLinux.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`url_launcher_linux` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
} else if (Platform.isMacOS) {
|
||||
try {
|
||||
FileSelectorMacOS.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`file_selector_macos` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
MacOSInAppWebViewPlatform.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`flutter_inappwebview_macos` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
MacOSFlutterLocalNotificationsPlugin.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`flutter_local_notifications` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
GeolocatorApple.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`geolocator_apple` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
ImagePickerMacOS.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`image_picker_macos` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
PathProviderFoundation.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`path_provider_foundation` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
SharedPreferencesFoundation.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`shared_preferences_foundation` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
SqflitePlugin.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`sqflite` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
UrlLauncherMacOS.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`url_launcher_macos` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
} else if (Platform.isWindows) {
|
||||
try {
|
||||
FileSelectorWindows.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`file_selector_windows` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
ImagePickerWindows.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`image_picker_windows` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
PackageInfoPlusWindowsPlugin.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`package_info_plus` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
PathProviderWindows.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`path_provider_windows` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
SharedPreferencesWindows.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`shared_preferences_windows` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
try {
|
||||
UrlLauncherWindows.registerWith();
|
||||
} catch (err) {
|
||||
print(
|
||||
'`url_launcher_windows` threw an error: $err. '
|
||||
'The app may not function as expected until you remove this plugin from pubspec.yaml'
|
||||
);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -1 +1 @@
|
||||
3.24.3
|
||||
3.24.1
|
||||
113
.flutter-plugins
113
.flutter-plugins
@@ -1,52 +1,63 @@
|
||||
# This is a generated file; do not edit or check into version control.
|
||||
connectivity_plus=/Users/apple/.pub-cache/hosted/pub.dev/connectivity_plus-6.1.3/
|
||||
file_selector_linux=/Users/apple/.pub-cache/hosted/pub.dev/file_selector_linux-0.9.3+2/
|
||||
file_selector_macos=/Users/apple/.pub-cache/hosted/pub.dev/file_selector_macos-0.9.4+2/
|
||||
file_selector_windows=/Users/apple/.pub-cache/hosted/pub.dev/file_selector_windows-0.9.3+3/
|
||||
flutter_inappwebview=/Users/apple/.pub-cache/hosted/pub.dev/flutter_inappwebview-6.0.0/
|
||||
flutter_inappwebview_android=/Users/apple/.pub-cache/hosted/pub.dev/flutter_inappwebview_android-1.0.13/
|
||||
flutter_inappwebview_ios=/Users/apple/.pub-cache/hosted/pub.dev/flutter_inappwebview_ios-1.0.13/
|
||||
flutter_inappwebview_macos=/Users/apple/.pub-cache/hosted/pub.dev/flutter_inappwebview_macos-1.0.11/
|
||||
flutter_inappwebview_web=/Users/apple/.pub-cache/hosted/pub.dev/flutter_inappwebview_web-1.0.8/
|
||||
flutter_plugin_android_lifecycle=/Users/apple/.pub-cache/hosted/pub.dev/flutter_plugin_android_lifecycle-2.0.22/
|
||||
fluttertoast=/Users/apple/.pub-cache/hosted/pub.dev/fluttertoast-8.2.11/
|
||||
geocoding=/Users/apple/.pub-cache/hosted/pub.dev/geocoding-3.0.0/
|
||||
geocoding_android=/Users/apple/.pub-cache/hosted/pub.dev/geocoding_android-3.3.1/
|
||||
geocoding_ios=/Users/apple/.pub-cache/hosted/pub.dev/geocoding_ios-3.0.1/
|
||||
geolocator=/Users/apple/.pub-cache/hosted/pub.dev/geolocator-13.0.2/
|
||||
geolocator_android=/Users/apple/.pub-cache/hosted/pub.dev/geolocator_android-4.6.1/
|
||||
geolocator_apple=/Users/apple/.pub-cache/hosted/pub.dev/geolocator_apple-2.3.8+1/
|
||||
geolocator_web=/Users/apple/.pub-cache/hosted/pub.dev/geolocator_web-4.1.1/
|
||||
geolocator_windows=/Users/apple/.pub-cache/hosted/pub.dev/geolocator_windows-0.2.3/
|
||||
google_api_headers=/Users/apple/.pub-cache/hosted/pub.dev/google_api_headers-1.6.0/
|
||||
google_maps_flutter=/Users/apple/.pub-cache/hosted/pub.dev/google_maps_flutter-2.10.0/
|
||||
google_maps_flutter_android=/Users/apple/.pub-cache/hosted/pub.dev/google_maps_flutter_android-2.14.7/
|
||||
google_maps_flutter_ios=/Users/apple/.pub-cache/hosted/pub.dev/google_maps_flutter_ios-2.13.2/
|
||||
google_maps_flutter_web=/Users/apple/.pub-cache/hosted/pub.dev/google_maps_flutter_web-0.5.10/
|
||||
image_picker=/Users/apple/.pub-cache/hosted/pub.dev/image_picker-1.1.2/
|
||||
image_picker_android=/Users/apple/.pub-cache/hosted/pub.dev/image_picker_android-0.8.12+12/
|
||||
image_picker_for_web=/Users/apple/.pub-cache/hosted/pub.dev/image_picker_for_web-3.0.6/
|
||||
image_picker_ios=/Users/apple/.pub-cache/hosted/pub.dev/image_picker_ios-0.8.12+2/
|
||||
image_picker_linux=/Users/apple/.pub-cache/hosted/pub.dev/image_picker_linux-0.2.1+1/
|
||||
image_picker_macos=/Users/apple/.pub-cache/hosted/pub.dev/image_picker_macos-0.2.1+2/
|
||||
image_picker_windows=/Users/apple/.pub-cache/hosted/pub.dev/image_picker_windows-0.2.1+1/
|
||||
package_info_plus=/Users/apple/.pub-cache/hosted/pub.dev/package_info_plus-4.2.0/
|
||||
path_provider=/Users/apple/.pub-cache/hosted/pub.dev/path_provider-2.1.5/
|
||||
path_provider_android=/Users/apple/.pub-cache/hosted/pub.dev/path_provider_android-2.2.10/
|
||||
path_provider_foundation=/Users/apple/.pub-cache/hosted/pub.dev/path_provider_foundation-2.4.1/
|
||||
path_provider_linux=/Users/apple/.pub-cache/hosted/pub.dev/path_provider_linux-2.2.1/
|
||||
path_provider_windows=/Users/apple/.pub-cache/hosted/pub.dev/path_provider_windows-2.3.0/
|
||||
shared_preferences=/Users/apple/.pub-cache/hosted/pub.dev/shared_preferences-2.3.3/
|
||||
shared_preferences_android=/Users/apple/.pub-cache/hosted/pub.dev/shared_preferences_android-2.3.2/
|
||||
shared_preferences_foundation=/Users/apple/.pub-cache/hosted/pub.dev/shared_preferences_foundation-2.5.4/
|
||||
shared_preferences_linux=/Users/apple/.pub-cache/hosted/pub.dev/shared_preferences_linux-2.4.1/
|
||||
shared_preferences_web=/Users/apple/.pub-cache/hosted/pub.dev/shared_preferences_web-2.4.2/
|
||||
shared_preferences_windows=/Users/apple/.pub-cache/hosted/pub.dev/shared_preferences_windows-2.4.1/
|
||||
sqflite=/Users/apple/.pub-cache/hosted/pub.dev/sqflite-2.3.3+1/
|
||||
url_launcher=/Users/apple/.pub-cache/hosted/pub.dev/url_launcher-6.3.1/
|
||||
url_launcher_android=/Users/apple/.pub-cache/hosted/pub.dev/url_launcher_android-6.3.9/
|
||||
url_launcher_ios=/Users/apple/.pub-cache/hosted/pub.dev/url_launcher_ios-6.3.2/
|
||||
url_launcher_linux=/Users/apple/.pub-cache/hosted/pub.dev/url_launcher_linux-3.2.1/
|
||||
url_launcher_macos=/Users/apple/.pub-cache/hosted/pub.dev/url_launcher_macos-3.2.2/
|
||||
url_launcher_web=/Users/apple/.pub-cache/hosted/pub.dev/url_launcher_web-2.3.3/
|
||||
url_launcher_windows=/Users/apple/.pub-cache/hosted/pub.dev/url_launcher_windows-3.1.4/
|
||||
connectivity_plus=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/connectivity_plus-6.1.3/
|
||||
file_selector_linux=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/file_selector_linux-0.9.3+2/
|
||||
file_selector_macos=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/file_selector_macos-0.9.4+2/
|
||||
file_selector_windows=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/file_selector_windows-0.9.3+3/
|
||||
firebase_core=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/firebase_core-3.13.0/
|
||||
firebase_core_web=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/firebase_core_web-2.22.0/
|
||||
firebase_messaging=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/firebase_messaging-15.2.5/
|
||||
firebase_messaging_web=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/firebase_messaging_web-3.10.5/
|
||||
flutter_inappwebview=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/flutter_inappwebview-6.0.0/
|
||||
flutter_inappwebview_android=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/flutter_inappwebview_android-1.0.13/
|
||||
flutter_inappwebview_ios=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/flutter_inappwebview_ios-1.0.13/
|
||||
flutter_inappwebview_macos=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/flutter_inappwebview_macos-1.0.11/
|
||||
flutter_inappwebview_web=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/flutter_inappwebview_web-1.0.8/
|
||||
flutter_local_notifications=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/flutter_local_notifications-18.0.1/
|
||||
flutter_local_notifications_linux=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/flutter_local_notifications_linux-5.0.0/
|
||||
flutter_plugin_android_lifecycle=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/flutter_plugin_android_lifecycle-2.0.22/
|
||||
fluttertoast=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/fluttertoast-8.2.11/
|
||||
geocoding=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/geocoding-3.0.0/
|
||||
geocoding_android=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/geocoding_android-3.3.1/
|
||||
geocoding_ios=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/geocoding_ios-3.0.1/
|
||||
geolocator=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/geolocator-13.0.2/
|
||||
geolocator_android=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/geolocator_android-4.6.1/
|
||||
geolocator_apple=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/geolocator_apple-2.3.8+1/
|
||||
geolocator_web=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/geolocator_web-4.1.1/
|
||||
geolocator_windows=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/geolocator_windows-0.2.3/
|
||||
google_api_headers=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/google_api_headers-1.6.0/
|
||||
google_maps_flutter=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/google_maps_flutter-2.10.0/
|
||||
google_maps_flutter_android=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/google_maps_flutter_android-2.14.7/
|
||||
google_maps_flutter_ios=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/google_maps_flutter_ios-2.13.2/
|
||||
google_maps_flutter_web=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/google_maps_flutter_web-0.5.10/
|
||||
image_picker=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/image_picker-1.1.2/
|
||||
image_picker_android=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/image_picker_android-0.8.12+12/
|
||||
image_picker_for_web=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/image_picker_for_web-3.0.6/
|
||||
image_picker_ios=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/image_picker_ios-0.8.12+2/
|
||||
image_picker_linux=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/image_picker_linux-0.2.1+1/
|
||||
image_picker_macos=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/image_picker_macos-0.2.1+2/
|
||||
image_picker_windows=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/image_picker_windows-0.2.1+1/
|
||||
package_info_plus=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/package_info_plus-4.2.0/
|
||||
path_provider=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/path_provider-2.1.5/
|
||||
path_provider_android=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/path_provider_android-2.2.10/
|
||||
path_provider_foundation=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/path_provider_foundation-2.4.1/
|
||||
path_provider_linux=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/path_provider_linux-2.2.1/
|
||||
path_provider_windows=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/path_provider_windows-2.3.0/
|
||||
permission_handler=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/permission_handler-11.4.0/
|
||||
permission_handler_android=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/permission_handler_android-12.1.0/
|
||||
permission_handler_apple=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/permission_handler_apple-9.4.7/
|
||||
permission_handler_html=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/permission_handler_html-0.1.3+5/
|
||||
permission_handler_windows=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/permission_handler_windows-0.2.1/
|
||||
shared_preferences=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/shared_preferences-2.3.3/
|
||||
shared_preferences_android=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/shared_preferences_android-2.3.2/
|
||||
shared_preferences_foundation=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/shared_preferences_foundation-2.5.4/
|
||||
shared_preferences_linux=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/shared_preferences_linux-2.4.1/
|
||||
shared_preferences_web=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/shared_preferences_web-2.4.2/
|
||||
shared_preferences_windows=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/shared_preferences_windows-2.4.1/
|
||||
sqflite=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/sqflite-2.3.3+1/
|
||||
url_launcher=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/url_launcher-6.3.1/
|
||||
url_launcher_android=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/url_launcher_android-6.3.9/
|
||||
url_launcher_ios=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/url_launcher_ios-6.3.2/
|
||||
url_launcher_linux=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/url_launcher_linux-3.2.1/
|
||||
url_launcher_macos=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/url_launcher_macos-3.2.2/
|
||||
url_launcher_web=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/url_launcher_web-2.3.3/
|
||||
url_launcher_windows=/Users/rajeevsingh/.pub-cache/hosted/pub.dev/url_launcher_windows-3.1.4/
|
||||
|
||||
File diff suppressed because one or more lines are too long
BIN
android/.DS_Store
vendored
BIN
android/.DS_Store
vendored
Binary file not shown.
67
android/app/google-services.json
Normal file
67
android/app/google-services.json
Normal file
@@ -0,0 +1,67 @@
|
||||
{
|
||||
"project_info": {
|
||||
"project_number": "855851990714",
|
||||
"project_id": "frontshop-emporium-8f851",
|
||||
"storage_bucket": "frontshop-emporium-8f851.firebasestorage.app"
|
||||
},
|
||||
"client": [
|
||||
{
|
||||
"client_info": {
|
||||
"mobilesdk_app_id": "1:855851990714:android:00a09bb4d0b9f1df818c83",
|
||||
"android_client_info": {
|
||||
"package_name": "com.app.frontshop.delivery"
|
||||
}
|
||||
},
|
||||
"oauth_client": [],
|
||||
"api_key": [
|
||||
{
|
||||
"current_key": "AIzaSyD2my5NEUm5almYwz_vUWgoMNMT4OMpGHM"
|
||||
}
|
||||
],
|
||||
"services": {
|
||||
"appinvite_service": {
|
||||
"other_platform_oauth_client": []
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"client_info": {
|
||||
"mobilesdk_app_id": "1:855851990714:android:6fb061e1f508cfe1818c83",
|
||||
"android_client_info": {
|
||||
"package_name": "com.frontshop.userapp"
|
||||
}
|
||||
},
|
||||
"oauth_client": [],
|
||||
"api_key": [
|
||||
{
|
||||
"current_key": "AIzaSyD2my5NEUm5almYwz_vUWgoMNMT4OMpGHM"
|
||||
}
|
||||
],
|
||||
"services": {
|
||||
"appinvite_service": {
|
||||
"other_platform_oauth_client": []
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"client_info": {
|
||||
"mobilesdk_app_id": "1:855851990714:android:89710f18cd3afa02818c83",
|
||||
"android_client_info": {
|
||||
"package_name": "com.frontshop.vendor"
|
||||
}
|
||||
},
|
||||
"oauth_client": [],
|
||||
"api_key": [
|
||||
{
|
||||
"current_key": "AIzaSyD2my5NEUm5almYwz_vUWgoMNMT4OMpGHM"
|
||||
}
|
||||
],
|
||||
"services": {
|
||||
"appinvite_service": {
|
||||
"other_platform_oauth_client": []
|
||||
}
|
||||
}
|
||||
}
|
||||
],
|
||||
"configuration_version": "1"
|
||||
}
|
||||
@@ -16,17 +16,20 @@
|
||||
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
|
||||
<uses-permission android:name="android.permission.CAMERA"/>
|
||||
<uses-permission android:name="android.permission.CALL_PHONE"/>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<application
|
||||
<uses-permission android:name="android.permission.POST_NOTIFICATIONS"/>
|
||||
<uses-permission android:name="android.permission.FOREGROUND_SERVICE"/>
|
||||
<uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED"/>
|
||||
<uses-permission android:name="android.permission.WAKE_LOCK"/>
|
||||
<application
|
||||
android:requestLegacyExternalStorage="true"
|
||||
android:enableOnBackInvokedCallback="true"
|
||||
android:label="Frontshop"
|
||||
android:name="${applicationName}"
|
||||
android:icon="@mipmap/ic_launcher">
|
||||
|
||||
<meta-data
|
||||
android:name="com.google.firebase.messaging.default_notification_channel_id"
|
||||
android:value="high_importance_channel"/>
|
||||
<activity
|
||||
android:name=".MainActivity"
|
||||
android:exported="true"
|
||||
@@ -62,6 +65,15 @@
|
||||
<meta-data
|
||||
android:name="flutterEmbedding"
|
||||
android:value="2" />
|
||||
|
||||
<service
|
||||
android:name="io.flutter.plugins.firebase.messaging.FlutterFirebaseMessagingService"
|
||||
android:exported="true"
|
||||
tools:replace="android:exported">
|
||||
<intent-filter>
|
||||
<action android:name="com.google.firebase.MESSAGING_EVENT"/>
|
||||
</intent-filter>
|
||||
</service>
|
||||
</application>
|
||||
<!-- Required to query activities that can process text, see:
|
||||
https://developer.android.com/training/package-visibility and
|
||||
|
||||
1
build/1cd05ff6f2b20584594304ccc763bad3/_composite.stamp
Normal file
1
build/1cd05ff6f2b20584594304ccc763bad3/_composite.stamp
Normal file
@@ -0,0 +1 @@
|
||||
{"inputs":[],"outputs":[]}
|
||||
@@ -0,0 +1 @@
|
||||
{"inputs":["/Users/rajeevsingh/Documents/FlutterProject/Testing/groceryApp/.dart_tool/package_config_subset"],"outputs":["/Users/rajeevsingh/Documents/FlutterProject/Testing/groceryApp/.dart_tool/flutter_build/dart_plugin_registrant.dart"]}
|
||||
@@ -0,0 +1 @@
|
||||
{"inputs":[],"outputs":[]}
|
||||
@@ -1,7 +1,11 @@
|
||||
import 'package:firebase_core/firebase_core.dart';
|
||||
import 'package:firebase_messaging/firebase_messaging.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_local_notifications/flutter_local_notifications.dart';
|
||||
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
||||
import 'package:grocery_app/src/core/network_services/service_locator.dart';
|
||||
import 'package:grocery_app/src/core/routes/routes.dart';
|
||||
import 'package:grocery_app/src/firebase_options.dart';
|
||||
import 'package:grocery_app/src/logic/provider/addTocart_provider.dart';
|
||||
import 'package:grocery_app/src/logic/provider/address_provider.dart';
|
||||
import 'package:grocery_app/src/logic/provider/auth_provider.dart';
|
||||
@@ -9,20 +13,70 @@ import 'package:grocery_app/src/logic/provider/bottom_navbar_provider.dart';
|
||||
import 'package:grocery_app/src/logic/provider/home_provider.dart';
|
||||
import 'package:grocery_app/src/logic/provider/order_provider.dart';
|
||||
import 'package:grocery_app/src/logic/provider/profile_provider.dart';
|
||||
import 'package:grocery_app/src/logic/services/notification_service.dart';
|
||||
import 'package:grocery_app/src/ui/splash/splash_screen.dart';
|
||||
import 'package:grocery_app/utils/constants/color_constant.dart';
|
||||
import 'package:grocery_app/utils/constants/string_constant.dart';
|
||||
import 'package:loader_overlay/loader_overlay.dart';
|
||||
import 'package:permission_handler/permission_handler.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
//change the location and many tings
|
||||
|
||||
void main() {
|
||||
|
||||
@pragma('vm:entry-point')
|
||||
Future<void> _firebaseMessagingBackgroundHandler(RemoteMessage message) async {
|
||||
await Firebase.initializeApp();
|
||||
print("💬 Background Message Received: ${message.notification?.title}");
|
||||
if (message.notification != null) {
|
||||
NotificationService.flutterLocalNotificationsPlugin.show(
|
||||
message.hashCode,
|
||||
message.notification!.title,
|
||||
message.notification!.body,
|
||||
const NotificationDetails(
|
||||
android: AndroidNotificationDetails(
|
||||
'high_importance_channel',
|
||||
'High Importance Notifications',
|
||||
channelDescription: 'Used for important notifications.',
|
||||
importance: Importance.max,
|
||||
priority: Priority.high,
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
Future<void> main() async {
|
||||
WidgetsFlutterBinding.ensureInitialized();
|
||||
WidgetsFlutterBinding.ensureInitialized();
|
||||
await Firebase.initializeApp(
|
||||
options: DefaultFirebaseOptions.currentPlatform,
|
||||
);
|
||||
|
||||
FirebaseMessaging.onBackgroundMessage(_firebaseMessagingBackgroundHandler);
|
||||
await NotificationService.init();
|
||||
|
||||
ServiceLocator.setup();
|
||||
await requestNotificationPermission();
|
||||
runApp(const MyApplication());
|
||||
}
|
||||
|
||||
Future<void> requestNotificationPermission() async {
|
||||
PermissionStatus status = await Permission.notification.status;
|
||||
|
||||
if (status.isDenied || status.isPermanentlyDenied) {
|
||||
status = await Permission.notification.request();
|
||||
}
|
||||
|
||||
if (status.isGranted) {
|
||||
print("✅ Notification permission granted");
|
||||
} else if (status.isPermanentlyDenied) {
|
||||
print("⚠️ Notification permission permanently denied. Open settings.");
|
||||
openAppSettings();
|
||||
} else {
|
||||
print("❌ Notification permission denied.");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
class MyApplication extends StatelessWidget {
|
||||
const MyApplication({super.key});
|
||||
|
||||
|
||||
@@ -52,6 +52,8 @@ class APIURL {
|
||||
|
||||
static const String productReview = "${BASE_URL}products/";
|
||||
|
||||
static const String upDateDeviceToken = "${BASE_URL}devices/register";
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
70
lib/src/firebase_options.dart
Normal file
70
lib/src/firebase_options.dart
Normal file
@@ -0,0 +1,70 @@
|
||||
// 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:
|
||||
throw UnsupportedError(
|
||||
'DefaultFirebaseOptions have not been configured for macos - '
|
||||
'you can reconfigure this by running the FlutterFire CLI again.',
|
||||
);
|
||||
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: 'AIzaSyD2my5NEUm5almYwz_vUWgoMNMT4OMpGHM',
|
||||
appId: '1:855851990714:android:6fb061e1f508cfe1818c83',
|
||||
messagingSenderId: '855851990714',
|
||||
projectId: 'frontshop-emporium-8f851',
|
||||
storageBucket: 'frontshop-emporium-8f851.firebasestorage.app',
|
||||
);
|
||||
|
||||
static const FirebaseOptions ios = FirebaseOptions(
|
||||
apiKey: 'AIzaSyABDDHCwEU_Kd6ODtFDXw3tfOpCxteT1q8',
|
||||
appId: '1:206755694561:ios:2a43094871ef7917d474a0',
|
||||
messagingSenderId: '934018612864',
|
||||
projectId: 'bestonehrms',
|
||||
storageBucket: 'digitalhrm-7e9ae.appspot.com',
|
||||
androidClientId: '',
|
||||
iosClientId: '',
|
||||
iosBundleId: 'com.erp.bestone',
|
||||
);
|
||||
}
|
||||
@@ -1,3 +1,4 @@
|
||||
import 'package:firebase_messaging/firebase_messaging.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:grocery_app/src/core/network_services/service_locator.dart';
|
||||
import 'package:grocery_app/src/data/user_profile.dart';
|
||||
@@ -32,4 +33,7 @@ class BottomNavProvider with ChangeNotifier {
|
||||
},
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import 'dart:async';
|
||||
import 'dart:convert';
|
||||
|
||||
import 'package:firebase_messaging/firebase_messaging.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:fluttertoast/fluttertoast.dart';
|
||||
import 'package:geolocator/geolocator.dart';
|
||||
@@ -9,7 +10,7 @@ import 'package:grocery_app/src/core/network_services/service_locator.dart';
|
||||
import 'package:grocery_app/src/core/routes/routes.dart';
|
||||
import 'package:grocery_app/src/data/ProductCategoryModel.dart';
|
||||
import 'package:grocery_app/src/data/allProduct_model.dart';
|
||||
import 'package:grocery_app/src/data/all_cart_items.dart';
|
||||
|
||||
import 'package:grocery_app/src/data/banners.dart';
|
||||
import 'package:grocery_app/src/data/best_dealProduct.dart';
|
||||
import 'package:grocery_app/src/data/product_category.dart';
|
||||
@@ -20,8 +21,7 @@ import 'package:grocery_app/utils/constants/shared_pref_utils.dart';
|
||||
import 'package:grocery_app/utils/extensions/extensions.dart';
|
||||
|
||||
import 'package:http/http.dart' as http;
|
||||
import 'package:material_design_icons_flutter/material_design_icons_flutter.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
|
||||
|
||||
class ProductProvider extends ChangeNotifier {
|
||||
final _homeRepo = getIt<ProductRepo>();
|
||||
@@ -109,6 +109,26 @@ class ProductProvider extends ChangeNotifier {
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
Future<bool> updateDeviceToken(BuildContext context) async {
|
||||
var fcm = await FirebaseMessaging.instance.getToken();
|
||||
var data = {"deviceToken": fcm, "deviceTpe": "android"};
|
||||
|
||||
print("fcm token ${"hjsdgffghhhh ${data}"}");
|
||||
|
||||
var result = await _homeRepo.updateDeviceToken(data, context);
|
||||
return result.fold(
|
||||
(error) {
|
||||
|
||||
return true;
|
||||
},
|
||||
(response) {
|
||||
print("token update success");
|
||||
return true;
|
||||
},
|
||||
);
|
||||
}
|
||||
|
||||
bool isHomeLoadingg = false;
|
||||
|
||||
List<Product> homeproducts = [];
|
||||
|
||||
@@ -442,7 +442,8 @@ class ProductRepo {
|
||||
}
|
||||
}
|
||||
|
||||
FutureResult<String> refreshToken(data, BuildContext context) async {
|
||||
FutureResult<String> refreshToken(data, BuildContext context) async
|
||||
{
|
||||
try {
|
||||
var response = await _productService.refresh_token(data);
|
||||
LoginResponse loginResponse = loginResponseFromJson(response.toString());
|
||||
@@ -463,29 +464,15 @@ class ProductRepo {
|
||||
}
|
||||
}
|
||||
|
||||
// FutureResult<VendorModel> getMe(data) async {
|
||||
// try {
|
||||
// var response = await _homeService.getMe(data);
|
||||
|
||||
// final VendorModel vendorModel = vendorModelFromJson(response.toString());
|
||||
|
||||
// if (vendorModel != null)
|
||||
// {
|
||||
// SharedPrefUtils.USER_NAME =
|
||||
// vendorModel.firstName + " " + vendorModel.lastName;
|
||||
// SharedPrefUtils.PHONE = vendorModel.phone;
|
||||
|
||||
// print("dkfjhdkfhkfk ${SharedPrefUtils.USER_NAME}");
|
||||
// await SharedPrefUtils.setStoreId(storeId: vendorModel.storeId ?? "");
|
||||
|
||||
// }
|
||||
|
||||
// final String model = response.toString();
|
||||
|
||||
// return right(vendorModel);
|
||||
// } on DioException catch (e) {
|
||||
// var error = CustomDioExceptions.handleError(e);
|
||||
// return left(error);
|
||||
// }
|
||||
// }
|
||||
FutureResult<String> updateDeviceToken(data, BuildContext context) async
|
||||
{
|
||||
try {
|
||||
var response = await _productService.updateDeviceToken(data);
|
||||
final String model = response.toString();
|
||||
return right(model);
|
||||
} on DioException catch (e) {
|
||||
var error = CustomDioExceptions.handleError(e);
|
||||
return left(error);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -19,6 +19,14 @@ class ProductService extends ApiService {
|
||||
return response;
|
||||
}
|
||||
|
||||
|
||||
Future updateDeviceToken(data) async {
|
||||
var response =
|
||||
await api.post(APIURL.upDateDeviceToken, data: jsonEncode(data));
|
||||
|
||||
return response;
|
||||
}
|
||||
|
||||
Future getAllProduct(data, id) async {
|
||||
var response;
|
||||
|
||||
@@ -40,6 +48,8 @@ class ProductService extends ApiService {
|
||||
return response;
|
||||
}
|
||||
|
||||
|
||||
|
||||
//
|
||||
|
||||
Future getBestDealProduct(data) async {
|
||||
|
||||
73
lib/src/logic/services/notification_service.dart
Normal file
73
lib/src/logic/services/notification_service.dart
Normal file
@@ -0,0 +1,73 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_local_notifications/flutter_local_notifications.dart';
|
||||
import 'package:firebase_messaging/firebase_messaging.dart';
|
||||
|
||||
|
||||
class NotificationService {
|
||||
static final FlutterLocalNotificationsPlugin flutterLocalNotificationsPlugin =
|
||||
FlutterLocalNotificationsPlugin();
|
||||
|
||||
static Future<void> init() async {
|
||||
const AndroidInitializationSettings initializationSettingsAndroid =
|
||||
AndroidInitializationSettings('@mipmap/ic_launcher');
|
||||
|
||||
const DarwinInitializationSettings initializationSettingsIOS =
|
||||
DarwinInitializationSettings(
|
||||
requestAlertPermission: true,
|
||||
requestBadgePermission: true,
|
||||
requestSoundPermission: true,
|
||||
);
|
||||
|
||||
const InitializationSettings initializationSettings =
|
||||
InitializationSettings(
|
||||
android: initializationSettingsAndroid,
|
||||
iOS: initializationSettingsIOS,
|
||||
);
|
||||
|
||||
await flutterLocalNotificationsPlugin.initialize(
|
||||
initializationSettings,
|
||||
onDidReceiveNotificationResponse: (NotificationResponse response) {
|
||||
// Handle tap on notification
|
||||
debugPrint("🔔 Notification clicked: ${response.payload}");
|
||||
},
|
||||
);
|
||||
|
||||
// Listen when app is in foreground
|
||||
FirebaseMessaging.onMessage.listen((RemoteMessage message) {
|
||||
_showNotification(message);
|
||||
});
|
||||
|
||||
// Optional: listen when user taps notification while app is in background/terminated
|
||||
FirebaseMessaging.onMessageOpenedApp.listen((RemoteMessage message) {
|
||||
debugPrint(
|
||||
"📲 App opened via notification: ${message.notification?.title}");
|
||||
// Navigate to specific screen if needed
|
||||
});
|
||||
}
|
||||
|
||||
static Future<void> _showNotification(RemoteMessage message) async {
|
||||
RemoteNotification? notification = message.notification;
|
||||
AndroidNotification? android = message.notification?.android;
|
||||
|
||||
if (notification != null && android != null) {
|
||||
const AndroidNotificationDetails androidDetails =
|
||||
AndroidNotificationDetails(
|
||||
'high_importance_channel', // Match with AndroidManifest.xml
|
||||
'High Importance Notifications',
|
||||
channelDescription: 'Used for important notifications.',
|
||||
importance: Importance.max,
|
||||
priority: Priority.high,
|
||||
);
|
||||
|
||||
const NotificationDetails platformDetails =
|
||||
NotificationDetails(android: androidDetails);
|
||||
|
||||
await flutterLocalNotificationsPlugin.show(
|
||||
notification.hashCode,
|
||||
notification.title,
|
||||
notification.body,
|
||||
platformDetails,
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -85,13 +85,11 @@ class _FavouriteScreenState extends State<FavouriteScreen>
|
||||
top: 0,
|
||||
right: 0,
|
||||
child: AppNetworkImage(
|
||||
|
||||
radius: 10,
|
||||
imageUrl: wishListProvider
|
||||
.productDatumlastImageurl ??
|
||||
"https://5.imimg.com/data5/SELLER/Default/2024/2/385126988/OL/DA/VW/8627346/1l-fortune-sunflower-oil.jpg",
|
||||
backGroundColor: Colors.white,
|
||||
|
||||
),
|
||||
),
|
||||
],
|
||||
@@ -151,7 +149,7 @@ class _FavouriteScreenState extends State<FavouriteScreen>
|
||||
return Expanded(
|
||||
child: DataNotFound(
|
||||
imagePath: 'assets/images/wishlist.jpg',
|
||||
message: "Your Wish list is empty. Please add some items",
|
||||
message: "Data Not Found",
|
||||
width: 250.w,
|
||||
height: 200.h,
|
||||
));
|
||||
@@ -213,7 +211,6 @@ class _FavouriteScreenState extends State<FavouriteScreen>
|
||||
.product!.productImages!.first.url ??
|
||||
"https://i.pinimg.com/originals/a5/f3/5f/a5f35fb23e942809da3df91b23718e8d.png",
|
||||
backGroundColor: APPCOLOR.bgGrey,
|
||||
|
||||
radius: 10,
|
||||
),
|
||||
),
|
||||
|
||||
@@ -38,6 +38,8 @@ class _HomeScreenState extends State<HomeScreen> {
|
||||
productProvider.getHomeProduct(context, "", '', '', '', '');
|
||||
productProvider.getBestDealProduct(context, '');
|
||||
productProvider.getAllcategory(context);
|
||||
|
||||
productProvider.updateDeviceToken(context);
|
||||
// productProvider.getCategoryByLevel();
|
||||
|
||||
getUserDetails();
|
||||
@@ -602,7 +604,6 @@ class _HomeScreenState extends State<HomeScreen> {
|
||||
enlargeFactor: 0.3,
|
||||
),
|
||||
items: provider.banner.map((banner) {
|
||||
|
||||
return Builder(
|
||||
builder: (BuildContext context) {
|
||||
return Container(
|
||||
@@ -661,6 +662,7 @@ class _HomeScreenState extends State<HomeScreen> {
|
||||
imageUrl: banner.imageUrl ??
|
||||
'https://e7.pngegg.com/pngimages/742/816/png-clipart-coca-cola-can-illustration-coca-cola-soft-drink-surge-pepsi-coke-sweetness-cola-thumbnail.png',
|
||||
backGroundColor: Colors.transparent,
|
||||
// boxFit: BoxFit.contain,
|
||||
),
|
||||
),
|
||||
),
|
||||
|
||||
@@ -35,11 +35,18 @@ class _ProfileScreenState extends State<ProfileScreen> {
|
||||
super.initState();
|
||||
}
|
||||
|
||||
Future<String> getToken() async {
|
||||
return await SharedPrefUtils.getToken() ?? "";
|
||||
}
|
||||
|
||||
getUserDetails() async {
|
||||
print("dkjfghlfkgh ${await SharedPrefUtils.getToken()}");
|
||||
APPSTRING.userName = (await SharedPrefUtils.getFirstName())!;
|
||||
APPSTRING.emailName = (await SharedPrefUtils.getUserEmail())!;
|
||||
APPSTRING.userProfile = (await SharedPrefUtils.getUserProfile())!;
|
||||
APPSTRING.userLastName = (await SharedPrefUtils.getLastName())!;
|
||||
|
||||
setState(() async {});
|
||||
}
|
||||
|
||||
final _formKey = GlobalKey<FormState>();
|
||||
@@ -59,7 +66,6 @@ class _ProfileScreenState extends State<ProfileScreen> {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
||||
return Scaffold(
|
||||
body: NestedScrollView(
|
||||
headerSliverBuilder: (BuildContext context, bool innerBoxIsScrolled) {
|
||||
@@ -88,11 +94,9 @@ class _ProfileScreenState extends State<ProfileScreen> {
|
||||
context.customExtraBold(Colors.white, 14),
|
||||
)
|
||||
: const SizedBox(),
|
||||
|
||||
const SizedBox(
|
||||
height: 30,
|
||||
),
|
||||
|
||||
Row(
|
||||
crossAxisAlignment: CrossAxisAlignment.center,
|
||||
children: [
|
||||
@@ -194,26 +198,6 @@ class _ProfileScreenState extends State<ProfileScreen> {
|
||||
title: const Text('Edit Profile'),
|
||||
trailing: Icon(MdiIcons.chevronRight),
|
||||
),
|
||||
// ListTile(
|
||||
// onTap: () {
|
||||
// _showBottomSheet(context);
|
||||
// },
|
||||
// leading: Icon(MdiIcons.lockOutline),
|
||||
// title: const Text('Change Password'),
|
||||
// trailing: Icon(MdiIcons.chevronRight),
|
||||
// ),
|
||||
// ListTile(
|
||||
// onTap: () {
|
||||
// // Navigator.of(context).push(MaterialPageRoute(
|
||||
// // builder: (context) {
|
||||
// // return const CardCheckoutScreen();
|
||||
// // },
|
||||
// // ));
|
||||
// },
|
||||
// leading: Icon(MdiIcons.cardOutline),
|
||||
// title: const Text('Payment Method'),
|
||||
// trailing: Icon(MdiIcons.chevronRight),
|
||||
// ),
|
||||
ListTile(
|
||||
onTap: () {
|
||||
context.push(MyRoutes.MYORDER);
|
||||
@@ -222,43 +206,6 @@ class _ProfileScreenState extends State<ProfileScreen> {
|
||||
title: const Text('My Order'),
|
||||
trailing: Icon(MdiIcons.chevronRight),
|
||||
),
|
||||
// ListTile(
|
||||
// onTap: () {
|
||||
// Navigator.of(context).push(MaterialPageRoute(
|
||||
// builder: (context) {
|
||||
// return const NotificationScreen();
|
||||
// },
|
||||
// ));
|
||||
// },
|
||||
// leading: Icon(MdiIcons.bellOutline),
|
||||
// title: const Text('Notifications'),
|
||||
// trailing: Icon(MdiIcons.chevronRight),
|
||||
// ),
|
||||
// ListTile(
|
||||
// onTap: () {
|
||||
// Navigator.of(context).push(MaterialPageRoute(
|
||||
// builder: (context) {
|
||||
// return const RatingReviewScreen();
|
||||
// },
|
||||
// ));
|
||||
// },
|
||||
// leading: Icon(MdiIcons.starOutline),
|
||||
// title: const Text('Rating & Review'),
|
||||
// trailing: Icon(MdiIcons.chevronRight),
|
||||
// ),
|
||||
// ListTile(
|
||||
// onTap: () {
|
||||
// Navigator.of(context).push(MaterialPageRoute(
|
||||
// builder: (context) {
|
||||
// return const MessageScreen();
|
||||
// },
|
||||
// ));
|
||||
// },
|
||||
// leading: Icon(MdiIcons.messageOutline),
|
||||
// title: const Text('Driver Message'),
|
||||
// trailing: Icon(MdiIcons.chevronRight),
|
||||
// ),
|
||||
|
||||
ListTile(
|
||||
onTap: () {
|
||||
context.push(MyRoutes.PRIVACY);
|
||||
@@ -275,7 +222,6 @@ class _ProfileScreenState extends State<ProfileScreen> {
|
||||
title: const Text('Term & Conditions'),
|
||||
trailing: Icon(MdiIcons.chevronRight),
|
||||
),
|
||||
|
||||
],
|
||||
),
|
||||
),
|
||||
@@ -304,10 +250,18 @@ class _ProfileScreenState extends State<ProfileScreen> {
|
||||
const SizedBox(
|
||||
width: 10,
|
||||
),
|
||||
Text(
|
||||
"Logout",
|
||||
style: context.customMedium(Colors.white, 16),
|
||||
),
|
||||
if (APPSTRING.isToken == null ||
|
||||
APPSTRING.isToken == "") ...{
|
||||
Text(
|
||||
"login",
|
||||
style: context.customMedium(Colors.white, 16),
|
||||
),
|
||||
} else ...{
|
||||
Text(
|
||||
"Logout",
|
||||
style: context.customMedium(Colors.white, 16),
|
||||
),
|
||||
}
|
||||
],
|
||||
),
|
||||
),
|
||||
|
||||
@@ -33,6 +33,7 @@ class _SplashScreenState extends State<SplashScreen> {
|
||||
{
|
||||
|
||||
Provider.of<BottomNavProvider>(context, listen: false) .refreshToken(context);
|
||||
|
||||
if (await SharedPrefUtils.isFreshInstall())
|
||||
{
|
||||
context.clearAndPush(routePath: MyRoutes.ONBOARDING);
|
||||
|
||||
@@ -27,4 +27,5 @@ class APPSTRING {
|
||||
static String userLastName = "user_name";
|
||||
static String emailName = "user_email";
|
||||
static String userProfile = "user_profile";
|
||||
static String isToken = "isToken";
|
||||
}
|
||||
|
||||
@@ -7,7 +7,10 @@ import Foundation
|
||||
|
||||
import connectivity_plus
|
||||
import file_selector_macos
|
||||
import firebase_core
|
||||
import firebase_messaging
|
||||
import flutter_inappwebview_macos
|
||||
import flutter_local_notifications
|
||||
import geolocator_apple
|
||||
import package_info_plus
|
||||
import path_provider_foundation
|
||||
@@ -18,7 +21,10 @@ import url_launcher_macos
|
||||
func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) {
|
||||
ConnectivityPlusPlugin.register(with: registry.registrar(forPlugin: "ConnectivityPlusPlugin"))
|
||||
FileSelectorPlugin.register(with: registry.registrar(forPlugin: "FileSelectorPlugin"))
|
||||
FLTFirebaseCorePlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseCorePlugin"))
|
||||
FLTFirebaseMessagingPlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseMessagingPlugin"))
|
||||
InAppWebViewFlutterPlugin.register(with: registry.registrar(forPlugin: "InAppWebViewFlutterPlugin"))
|
||||
FlutterLocalNotificationsPlugin.register(with: registry.registrar(forPlugin: "FlutterLocalNotificationsPlugin"))
|
||||
GeolocatorPlugin.register(with: registry.registrar(forPlugin: "GeolocatorPlugin"))
|
||||
FPPPackageInfoPlusPlugin.register(with: registry.registrar(forPlugin: "FPPPackageInfoPlusPlugin"))
|
||||
PathProviderPlugin.register(with: registry.registrar(forPlugin: "PathProviderPlugin"))
|
||||
|
||||
140
pubspec.lock
140
pubspec.lock
@@ -1,6 +1,14 @@
|
||||
# Generated by pub
|
||||
# See https://dart.dev/tools/pub/glossary#lockfile
|
||||
packages:
|
||||
_flutterfire_internals:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: _flutterfire_internals
|
||||
sha256: de9ecbb3ddafd446095f7e833c853aff2fa1682b017921fe63a833f9d6f0e422
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "1.3.54"
|
||||
animation_list:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
@@ -273,6 +281,54 @@ packages:
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "0.9.3+3"
|
||||
firebase_core:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: firebase_core
|
||||
sha256: "017d17d9915670e6117497e640b2859e0b868026ea36bf3a57feb28c3b97debe"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "3.13.0"
|
||||
firebase_core_platform_interface:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: firebase_core_platform_interface
|
||||
sha256: d7253d255ff10f85cfd2adaba9ac17bae878fa3ba577462451163bd9f1d1f0bf
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "5.4.0"
|
||||
firebase_core_web:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: firebase_core_web
|
||||
sha256: "129a34d1e0fb62e2b488d988a1fc26cc15636357e50944ffee2862efe8929b23"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "2.22.0"
|
||||
firebase_messaging:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: firebase_messaging
|
||||
sha256: "5f8918848ee0c8eb172fc7698619b2bcd7dda9ade8b93522c6297dd8f9178356"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "15.2.5"
|
||||
firebase_messaging_platform_interface:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: firebase_messaging_platform_interface
|
||||
sha256: "0bbea00680249595fc896e7313a2bd90bd55be6e0abbe8b9a39d81b6b306acb6"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "4.6.5"
|
||||
firebase_messaging_web:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: firebase_messaging_web
|
||||
sha256: ffb392ce2a7e8439cd0a9a80e3c702194e73c927e5c7b4f0adf6faa00b245b17
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "3.10.5"
|
||||
fixnum:
|
||||
dependency: transitive
|
||||
description:
|
||||
@@ -374,6 +430,30 @@ packages:
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "3.0.2"
|
||||
flutter_local_notifications:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: flutter_local_notifications
|
||||
sha256: ef41ae901e7529e52934feba19ed82827b11baa67336829564aeab3129460610
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "18.0.1"
|
||||
flutter_local_notifications_linux:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: flutter_local_notifications_linux
|
||||
sha256: "8f685642876742c941b29c32030f6f4f6dacd0e4eaecb3efbb187d6a3812ca01"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "5.0.0"
|
||||
flutter_local_notifications_platform_interface:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: flutter_local_notifications_platform_interface
|
||||
sha256: "6c5b83c86bf819cdb177a9247a3722067dd8cc6313827ce7c77a4b238a26fd52"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "8.0.0"
|
||||
flutter_plugin_android_lifecycle:
|
||||
dependency: transitive
|
||||
description:
|
||||
@@ -952,6 +1032,54 @@ packages:
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "2.3.0"
|
||||
permission_handler:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: permission_handler
|
||||
sha256: "59adad729136f01ea9e35a48f5d1395e25cba6cea552249ddbe9cf950f5d7849"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "11.4.0"
|
||||
permission_handler_android:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: permission_handler_android
|
||||
sha256: d3971dcdd76182a0c198c096b5db2f0884b0d4196723d21a866fc4cdea057ebc
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "12.1.0"
|
||||
permission_handler_apple:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: permission_handler_apple
|
||||
sha256: f000131e755c54cf4d84a5d8bd6e4149e262cc31c5a8b1d698de1ac85fa41023
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "9.4.7"
|
||||
permission_handler_html:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: permission_handler_html
|
||||
sha256: "38f000e83355abb3392140f6bc3030660cfaef189e1f87824facb76300b4ff24"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "0.1.3+5"
|
||||
permission_handler_platform_interface:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: permission_handler_platform_interface
|
||||
sha256: eb99b295153abce5d683cac8c02e22faab63e50679b937fa1bf67d58bb282878
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "4.3.0"
|
||||
permission_handler_windows:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: permission_handler_windows
|
||||
sha256: "1a790728016f79a41216d88672dbc5df30e686e811ad4e698bfc51f76ad91f1e"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "0.2.1"
|
||||
petitparser:
|
||||
dependency: transitive
|
||||
description:
|
||||
@@ -1181,6 +1309,14 @@ packages:
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "0.7.2"
|
||||
timezone:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: timezone
|
||||
sha256: "2236ec079a174ce07434e89fcd3fcda430025eb7692244139a9cf54fdcf1fc7d"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "0.9.4"
|
||||
typed_data:
|
||||
dependency: transitive
|
||||
description:
|
||||
@@ -1334,5 +1470,5 @@ packages:
|
||||
source: hosted
|
||||
version: "6.5.0"
|
||||
sdks:
|
||||
dart: ">=3.4.4 <4.0.0"
|
||||
flutter: ">=3.22.0"
|
||||
dart: ">=3.5.0 <4.0.0"
|
||||
flutter: ">=3.24.0"
|
||||
|
||||
@@ -37,6 +37,11 @@ dependencies:
|
||||
blur:
|
||||
flutter_rating_bar:
|
||||
change_app_package_name: ^1.5.0
|
||||
permission_handler: ^11.3.1
|
||||
flutter_local_notifications: ^18.0.1
|
||||
firebase_core:
|
||||
firebase_messaging:
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -8,7 +8,9 @@
|
||||
|
||||
#include <connectivity_plus/connectivity_plus_windows_plugin.h>
|
||||
#include <file_selector_windows/file_selector_windows.h>
|
||||
#include <firebase_core/firebase_core_plugin_c_api.h>
|
||||
#include <geolocator_windows/geolocator_windows.h>
|
||||
#include <permission_handler_windows/permission_handler_windows_plugin.h>
|
||||
#include <url_launcher_windows/url_launcher_windows.h>
|
||||
|
||||
void RegisterPlugins(flutter::PluginRegistry* registry) {
|
||||
@@ -16,8 +18,12 @@ void RegisterPlugins(flutter::PluginRegistry* registry) {
|
||||
registry->GetRegistrarForPlugin("ConnectivityPlusWindowsPlugin"));
|
||||
FileSelectorWindowsRegisterWithRegistrar(
|
||||
registry->GetRegistrarForPlugin("FileSelectorWindows"));
|
||||
FirebaseCorePluginCApiRegisterWithRegistrar(
|
||||
registry->GetRegistrarForPlugin("FirebaseCorePluginCApi"));
|
||||
GeolocatorWindowsRegisterWithRegistrar(
|
||||
registry->GetRegistrarForPlugin("GeolocatorWindows"));
|
||||
PermissionHandlerWindowsPluginRegisterWithRegistrar(
|
||||
registry->GetRegistrarForPlugin("PermissionHandlerWindowsPlugin"));
|
||||
UrlLauncherWindowsRegisterWithRegistrar(
|
||||
registry->GetRegistrarForPlugin("UrlLauncherWindows"));
|
||||
}
|
||||
|
||||
@@ -5,7 +5,9 @@
|
||||
list(APPEND FLUTTER_PLUGIN_LIST
|
||||
connectivity_plus
|
||||
file_selector_windows
|
||||
firebase_core
|
||||
geolocator_windows
|
||||
permission_handler_windows
|
||||
url_launcher_windows
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user