This commit is contained in:
Hamza-Ayed
2024-02-04 23:53:13 +03:00
parent 87da645ae5
commit 481eff94c2
24 changed files with 708 additions and 332 deletions

View File

@@ -6,6 +6,8 @@ class BoxName {
static const String password = "password"; static const String password = "password";
static const String passwordDriver = "passwordDriver"; static const String passwordDriver = "passwordDriver";
static const String agreeTerms = "agreeTerms"; static const String agreeTerms = "agreeTerms";
static const String addWork = 'addWork';
static const String addHome = 'addHome';
static const String accountIdStripeConnect = "accountIdStripeConnect"; static const String accountIdStripeConnect = "accountIdStripeConnect";
static const String faceDetectTimes = "faceDetectTimes"; static const String faceDetectTimes = "faceDetectTimes";
static const String sosPhonePassenger = "sosPhonePassenger"; static const String sosPhonePassenger = "sosPhonePassenger";
@@ -56,4 +58,5 @@ class BoxName {
static const String color = "color"; static const String color = "color";
static const String owner = "owner"; static const String owner = "owner";
static const String registrationDate = "registrationDate"; static const String registrationDate = "registrationDate";
static const List recentLocations = [];
} }

View File

@@ -9,5 +9,5 @@ class AppColor {
static const Color blueColor = Color(0xFF4285F4); // Google Blue static const Color blueColor = Color(0xFF4285F4); // Google Blue
static const Color yellowColor = Color(0xFFFBBC05); // Google Yellow static const Color yellowColor = Color(0xFFFBBC05); // Google Yellow
static Color deepPurpleAccent = static Color deepPurpleAccent =
const Color.fromARGB(255, 123, 76, 254).withOpacity(0.3); // Google Yellow const Color.fromARGB(255, 123, 76, 254).withOpacity(0.3);
} }

View File

@@ -86,6 +86,11 @@ class AppLink {
static String getFeedBack = "$ride/feedBack/get.php"; static String getFeedBack = "$ride/feedBack/get.php";
static String updateFeedBack = "$ride/feedBack/updateFeedBack.php"; static String updateFeedBack = "$ride/feedBack/updateFeedBack.php";
//-----------------Tips------------------
static String addTips = "$ride/tips/add.php";
static String getTips = "$ride/tips/get.php";
static String updateTips = "$ride/tips/update.php";
//-----------------Help Center------------------ //-----------------Help Center------------------
static String addhelpCenter = "$ride/helpCenter/add.php"; static String addhelpCenter = "$ride/helpCenter/add.php";
static String gethelpCenter = "$ride/helpCenter/get.php"; static String gethelpCenter = "$ride/helpCenter/get.php";

View File

@@ -1,5 +1,6 @@
class TableName { class TableName {
static const String placesFavorite = "placesFavorite"; static const String placesFavorite = "placesFavorite";
static const String recentLocations = "recentLocations";
static const String carLocations = "carLocations"; static const String carLocations = "carLocations";
static const String driverOrdersRefuse = "driverOrdersRefuse"; static const String driverOrdersRefuse = "driverOrdersRefuse";
static const String faceDetectTimes = "faceDetectTimes"; static const String faceDetectTimes = "faceDetectTimes";

View File

@@ -5,6 +5,7 @@ import 'package:flutter/material.dart';
import 'package:flutter_local_notifications/flutter_local_notifications.dart'; import 'package:flutter_local_notifications/flutter_local_notifications.dart';
import 'package:get/get.dart'; import 'package:get/get.dart';
import 'package:http/http.dart' as http; import 'package:http/http.dart' as http;
import 'package:ride/controller/functions/crud.dart';
import 'package:ride/views/widgets/elevated_btn.dart'; import 'package:ride/views/widgets/elevated_btn.dart';
import '../../constant/api_key.dart'; import '../../constant/api_key.dart';
@@ -13,9 +14,11 @@ import '../../constant/colors.dart';
import '../../constant/links.dart'; import '../../constant/links.dart';
import '../../constant/style.dart'; import '../../constant/style.dart';
import '../../main.dart'; import '../../main.dart';
import '../../views/Rate/rate_captain.dart';
import '../../views/home/Captin/home_captain/home_captin.dart'; import '../../views/home/Captin/home_captain/home_captin.dart';
import '../../views/home/profile/promos_passenger_page.dart'; import '../../views/home/profile/promos_passenger_page.dart';
import '../../views/home/Captin/orderCaptin/order_request_page.dart'; import '../../views/home/Captin/orderCaptin/order_request_page.dart';
import '../home/map_passenger_controller.dart';
class FirebaseMessagesController extends GetxController { class FirebaseMessagesController extends GetxController {
final fcmToken = FirebaseMessaging.instance; final fcmToken = FirebaseMessaging.instance;
@@ -99,7 +102,7 @@ class FirebaseMessagesController extends GetxController {
FirebaseMessaging.onMessage.listen((RemoteMessage message) { FirebaseMessaging.onMessage.listen((RemoteMessage message) {
if (message.data.isNotEmpty) { if (message.data.isNotEmpty) {
firebasetitles(message); fireBaseTitles(message);
} }
// If the app is in the background or terminated, show a system tray message // If the app is in the background or terminated, show a system tray message
RemoteNotification? notification = message.notification; RemoteNotification? notification = message.notification;
@@ -108,7 +111,7 @@ class FirebaseMessagesController extends GetxController {
if (notification != null && android != null) { if (notification != null && android != null) {
// print('onMessageOpenedApp: ${notification.title} ${notification.body}'); // print('onMessageOpenedApp: ${notification.title} ${notification.body}');
if (message.data.isNotEmpty) { if (message.data.isNotEmpty) {
firebasetitles(message); fireBaseTitles(message);
} }
} }
}); });
@@ -117,11 +120,11 @@ class FirebaseMessagesController extends GetxController {
// print( // print(
// 'onMessageOpenedApp: ${message.notification!.title} ${message.notification!.body}'); // 'onMessageOpenedApp: ${message.notification!.title} ${message.notification!.body}');
RemoteNotification? notification = message.notification; RemoteNotification? notification = message.notification;
firebasetitles(message); fireBaseTitles(message);
}); });
} }
void firebasetitles(RemoteMessage message) { void fireBaseTitles(RemoteMessage message) {
if (message.notification!.title!.contains('Order')) { if (message.notification!.title!.contains('Order')) {
var myListString = message.data['DriverList']; var myListString = message.data['DriverList'];
print(myListString); print(myListString);
@@ -181,13 +184,49 @@ class FirebaseMessagesController extends GetxController {
Get.snackbar('RideIsBegin', '', backgroundColor: AppColor.greenColor); Get.snackbar('RideIsBegin', '', backgroundColor: AppColor.greenColor);
// mapController.driverArrivePassenger(); // mapController.driverArrivePassenger();
update(); update();
} else if (message.notification!.title!.contains('Captain Finish Trip')) { } else if (message.notification!.title!.contains('Driver Finish Trip')) {
// MapPassengerController mapController = var myListString = message.data['passengerList'];
// Get.find<MapPassengerController>(); var driverList = jsonDecode(myListString) as List<dynamic>;
Get.snackbar('Ride Finished'.tr, '', Get.defaultDialog(
backgroundColor: AppColor.greenColor); title: 'Driver Finish Trip'.tr,
// mapController.isRideFinished = true;//todo fix that for dfinish ride in passenger app content: Column(
update(); mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Text(
'Your fee is ${Get.find<MapPassengerController>().totalPassenger.toStringAsFixed(2)}'),
Text('Do you want to pay Tips for this Driver'.tr)
],
),
confirm: MyElevatedButton(
title: 'Yes'.tr,
onPressed: () async {
var res = await CRUD().post(link: AppLink.addTips, payload: {
'passengerID': box.read(BoxName.passengerID),
'driverID': driverList[0].toString(),
'rideID': driverList[1].toString(),
'tipAmount': '1',
});
if (res != 'failure') {
FirebaseMessagesController().sendNotificationToAnyWithoutData(
'You Have Tips',
'1\$ tips',
driverList[2].toString(),
);
}
Get.to(() => RateCaptainFromPassenger(), arguments: {
'driverId': driverList[0].toString(),
'rideId': driverList[1].toString(),
});
},
kolor: AppColor.greenColor,
),
cancel: MyElevatedButton(
title: 'No,I want'.tr,
onPressed: () {
Get.offAll(() => RateCaptainFromPassenger());
},
kolor: AppColor.redColor,
));
} }
} }

View File

@@ -209,6 +209,61 @@ class CRUD {
} }
} }
Future<void> sendVerificationRequest(String phoneNumber) async {
final accountSid = "ACb4ad857efe0903bfd6238a763a2ce4d1";
final authToken = "14f39ef4628bb8a4f18469f462f8af75";
final verifySid = "VAf6e6022a7e95186aa5b1da25411859bd";
final Uri verificationUri = Uri.parse(
'https://verify.twilio.com/v2/Services/$verifySid/Verifications');
// Send the verification request
final response = await http.post(
verificationUri,
headers: {
'Authorization':
'Basic ' + base64Encode(utf8.encode('$accountSid:$authToken')),
'Content-Type': 'application/x-www-form-urlencoded',
},
body: {
'To': phoneNumber,
'Channel': 'sms',
},
);
if (response.statusCode == 201) {
print('Verification request sent');
} else {
print('Failed to send verification request');
}
// Prompt the user to enter the OTP
final otpCode = "123456"; // Replace with user input
// Check the verification code
final checkUri = Uri.parse(
'https://verify.twilio.com/v2/Services/$verifySid/VerificationCheck');
final checkResponse = await http.post(
checkUri,
headers: {
'Authorization':
'Basic ' + base64Encode(utf8.encode('$accountSid:$authToken')),
'Content-Type': 'application/x-www-form-urlencoded',
},
body: {
'To': phoneNumber,
'Code': otpCode,
},
);
if (checkResponse.statusCode == 201) {
print('Verification successful');
} else {
print('Verification failed');
}
}
Future<dynamic> getGoogleApi({ Future<dynamic> getGoogleApi({
required String link, required String link,
Map<String, dynamic>? payload, Map<String, dynamic>? payload,
@@ -220,7 +275,7 @@ class CRUD {
url, url,
body: payload, body: payload,
); );
//print(response.request); print(response.request);
var jsonData = jsonDecode(response.body); var jsonData = jsonDecode(response.body);
// //print(jsonData); // //print(jsonData);
if (jsonData['status'] == 'OK') { if (jsonData['status'] == 'OK') {

View File

@@ -267,10 +267,14 @@ class MapDriverController extends GetxController {
'passengerId': passengerId, 'passengerId': passengerId,
'driverId': driverId 'driverId': driverId
}); });
FirebaseMessagesController().sendNotificationToAnyWithoutData( FirebaseMessagesController().sendNotificationToPassengerToken(
'Captain Finish Trip', 'Driver Finish Trip',
box.read(BoxName.name).toString(), box.read(BoxName.name).toString(),
tokenPassenger); tokenPassenger, [
box.read(BoxName.driverID),
rideId,
box.read(BoxName.tokenDriver),
]);
} }
void cancelCheckRidefromPassenger() async { void cancelCheckRidefromPassenger() async {

View File

@@ -93,6 +93,8 @@ class MapPassengerController extends GetxController {
double mainBottomMenuMapHeight = Get.height * .2; double mainBottomMenuMapHeight = Get.height * .2;
double wayPointSheetHeight = 0; double wayPointSheetHeight = 0;
bool startLocationFromMap = false; bool startLocationFromMap = false;
bool workLocationFromMap = false;
bool homeLocationFromMap = false;
bool startLocationFromMap0 = false; bool startLocationFromMap0 = false;
bool startLocationFromMap1 = false; bool startLocationFromMap1 = false;
bool startLocationFromMap2 = false; bool startLocationFromMap2 = false;
@@ -161,7 +163,7 @@ class MapPassengerController extends GetxController {
List<String> currentLocationStringAll = []; List<String> currentLocationStringAll = [];
List<String> hintTextwayPointStringAll = []; List<String> hintTextwayPointStringAll = [];
var placesCoordinate = <String>[]; var placesCoordinate = <String>[];
String hintTextDestinationPoint = 'Search for your destination'.tr; String hintTextDestinationPoint = 'Select your destination'.tr;
late String rideId; late String rideId;
bool noCarString = false; bool noCarString = false;
bool isCashSelectedBeforeConfirmRide = false; bool isCashSelectedBeforeConfirmRide = false;
@@ -218,6 +220,7 @@ class MapPassengerController extends GetxController {
durationToRide = 0; durationToRide = 0;
distanceOfDestnation = 0; distanceOfDestnation = 0;
wayPointSheetHeight = 0; wayPointSheetHeight = 0;
haveSteps = true;
for (var i = 0; i < Get.find<WayPointController>().wayPoints.length; i++) { for (var i = 0; i < Get.find<WayPointController>().wayPoints.length; i++) {
if (placesCoordinate[i + 1].toString() != '') { if (placesCoordinate[i + 1].toString() != '') {
await getMapPoints( await getMapPoints(
@@ -346,6 +349,16 @@ class MapPassengerController extends GetxController {
} }
} }
void convertHintTextDestinationNewPlacesFromRecent(
List recentLocations, int index) {
hintTextDestinationPoint = recentLocations[index]['name'];
double lat = recentLocations[index]['latitude'];
double lng = recentLocations[index]['longitude'];
newMyLocation = LatLng(lat, lng);
update();
}
// final mainBottomMenuMap = GlobalKey<AnimatedContainer>(); // final mainBottomMenuMap = GlobalKey<AnimatedContainer>();
void changeBottomSheetShown() { void changeBottomSheetShown() {
isBottomSheetShown = !isBottomSheetShown; isBottomSheetShown = !isBottomSheetShown;
@@ -486,10 +499,10 @@ class MapPassengerController extends GetxController {
'passenger_id': box.read(BoxName.passengerID).toString(), 'passenger_id': box.read(BoxName.passengerID).toString(),
'balance': ((-1) * totalPassenger).toString() 'balance': ((-1) * totalPassenger).toString()
}); });
Get.to(() => RateCaptainFromPassenger(), arguments: { // Get.to(() => RateCaptainFromPassenger(), arguments: {
'driverId': driverId.toString(), // 'driverId': driverId.toString(),
'rideId': rideId.toString(), // 'rideId': rideId.toString(),
}); // });
} }
void getBeginRideFromDriver() async { void getBeginRideFromDriver() async {
@@ -634,7 +647,7 @@ class MapPassengerController extends GetxController {
'${data[0]["end_location"]['lat']},${data[0]["end_location"]['lng']}', '${data[0]["end_location"]['lat']},${data[0]["end_location"]['lng']}',
totalPassenger.toString(), totalPassenger.toString(),
totalDriver.toString(), totalDriver.toString(),
duration.toString(), durationToRide.toString(),
distance.toString(), distance.toString(),
dataCarsLocationByPassenger['message'][carsOrder]['driver_id'] dataCarsLocationByPassenger['message'][carsOrder]['driver_id']
.toString(), .toString(),
@@ -985,7 +998,7 @@ class MapPassengerController extends GetxController {
} else { } else {
isMainBottomMenuMap = !isMainBottomMenuMap; isMainBottomMenuMap = !isMainBottomMenuMap;
mainBottomMenuMapHeight = mainBottomMenuMapHeight =
isMainBottomMenuMap == true ? Get.height * .2 : Get.height * .6; isMainBottomMenuMap == true ? Get.height * .2 : Get.height * .5;
isWayPointSheet = false; isWayPointSheet = false;
if (heightMenuBool == true) { if (heightMenuBool == true) {
getDrawerMenu(); getDrawerMenu();
@@ -1499,10 +1512,10 @@ class MapPassengerController extends GetxController {
double distanceOfDestnation = 0; double distanceOfDestnation = 0;
bool haveSteps = false; bool haveSteps = false;
late LatLng latestPosition; late LatLng latestPosition = LatLng(0, 0);
getMapPoints(String originSteps, String destinationSteps, int index) async { getMapPoints(String originSteps, String destinationSteps, int index) async {
isWayPointStopsSheetUtilGetMap = false; isWayPointStopsSheetUtilGetMap = false;
haveSteps = true; // haveSteps = true;
await getCarsLocationByPassenger(); await getCarsLocationByPassenger();
// isLoading = true; // isLoading = true;
update(); update();
@@ -1521,9 +1534,11 @@ class MapPassengerController extends GetxController {
final points = final points =
decodePolyline(response["routes"][0]["overview_polyline"]["points"]); decodePolyline(response["routes"][0]["overview_polyline"]["points"]);
for (int i = 0; i < points.length; i++) { for (int i = 0; i < points.length; i++) {
double lat = points[i][0].toDouble(); if (points[i][0].toString() != '') {
double lng = points[i][1].toDouble(); double lat = points[i][0].toDouble();
polylineCoordinatesPointsAll[index].add(LatLng(lat, lng)); double lng = points[i][1].toDouble();
polylineCoordinatesPointsAll[index].add(LatLng(lat, lng));
}
} }
// Define the northeast and southwest coordinates // Define the northeast and southwest coordinates

View File

@@ -73,6 +73,8 @@ class CaptainWalletController extends GetxController {
//check if account bank is created or not //check if account bank is created or not
Future checkAccountCaptainBank() async { Future checkAccountCaptainBank() async {
isLoading = false;
update();
if (box.read(BoxName.accountIdStripeConnect).toString().isEmpty) { if (box.read(BoxName.accountIdStripeConnect).toString().isEmpty) {
var res = await CRUD().get(link: AppLink.getAccount, payload: { var res = await CRUD().get(link: AppLink.getAccount, payload: {
'id': box.read(BoxName.driverID).toString(), 'id': box.read(BoxName.driverID).toString(),
@@ -83,6 +85,8 @@ class CaptainWalletController extends GetxController {
d['message'][0]['accountBank'].toString()); d['message'][0]['accountBank'].toString());
} }
} }
isLoading = true;
update();
} }
@override @override

View File

@@ -27,7 +27,7 @@ Future<void> backgroundMessageHandler(RemoteMessage message) async {
await Firebase.initializeApp(); await Firebase.initializeApp();
print('===========back===${message.notification?.title}'); print('===========back===${message.notification?.title}');
FirebaseMessagesController().firebasetitles(message); FirebaseMessagesController().fireBaseTitles(message);
} }
void main() async { void main() async {

View File

@@ -42,6 +42,16 @@ class DbSql {
rate TEXT rate TEXT
) )
'''); ''');
await db.execute(
'''
CREATE TABLE IF NOT EXISTS ${TableName.recentLocations}(
id INTEGER PRIMARY KEY AUTOINCREMENT,
latitude REAL,
longitude REAL,
name TEXT UNIQUE,
rate TEXT
)
''');
await db.execute( await db.execute(
''' '''
CREATE TABLE IF NOT EXISTS ${TableName.driverOrdersRefuse}( CREATE TABLE IF NOT EXISTS ${TableName.driverOrdersRefuse}(

View File

@@ -15,7 +15,9 @@ GetBuilder<MapDriverController> driverEndRideBar() {
right: 5, right: 5,
child: Container( child: Container(
decoration: AppStyle.boxDecoration, decoration: AppStyle.boxDecoration,
height: mapDriverController.driverEndPage, height: mapDriverController.remainingTimeTimerRideBegin < 60
? mapDriverController.driverEndPage = 160
: 100,
width: 200, width: 200,
child: Column( child: Column(
children: [ children: [

View File

@@ -33,7 +33,7 @@ GetBuilder<MapPassengerController> hexagonClipper() {
crossAxisAlignment: CrossAxisAlignment.center, crossAxisAlignment: CrossAxisAlignment.center,
children: [ children: [
Text( Text(
'Waiting for Captin ...'.tr, 'Waiting for Driver ...'.tr,
style: AppStyle.title, style: AppStyle.title,
), ),
// IconButton( // IconButton(
@@ -42,12 +42,12 @@ GetBuilder<MapPassengerController> hexagonClipper() {
// }, // },
// icon: const Icon(Icons.add), // icon: const Icon(Icons.add),
// ), // ),
Text( // Text(
controller.dataCarsLocationByPassenger['message'] // controller.dataCarsLocationByPassenger['message']
[controller.carsOrder]['phone'] // [controller.carsOrder]['phone']
.toString(), // .toString(),
style: AppStyle.title, // style: AppStyle.title,
), // ),
Row( Row(
mainAxisAlignment: MainAxisAlignment.spaceEvenly, mainAxisAlignment: MainAxisAlignment.spaceEvenly,
children: [ children: [
@@ -87,12 +87,12 @@ GetBuilder<MapPassengerController> hexagonClipper() {
.toString(), .toString(),
style: AppStyle.title, style: AppStyle.title,
), ),
Text( // Text(
controller.dataCarsLocationByPassenger['message'] // controller.dataCarsLocationByPassenger['message']
[controller.carsOrder]['seats'] // [controller.carsOrder]['seats']
.toString(), // .toString(),
style: AppStyle.title, // style: AppStyle.title,
), // ),
], ],
), ),
Text( Text(

View File

@@ -1,178 +0,0 @@
import 'package:flutter/material.dart';
import 'package:get/get.dart';
import 'package:ride/constant/table_names.dart';
import '../../../constant/colors.dart';
import '../../../constant/style.dart';
import '../../../controller/functions/toast.dart';
import '../../../controller/home/map_passenger_controller.dart';
import '../../../main.dart';
GetBuilder<MapPassengerController> formSearchPlaces() {
// DbSql sql = DbSql.instance;
return GetBuilder<MapPassengerController>(
builder: (controller) => Column(
children: [
Padding(
padding: const EdgeInsets.all(12),
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Container(
width: Get.width * .8,
decoration:
const BoxDecoration(color: AppColor.secondaryColor),
child: TextField(
decoration: InputDecoration(
border: const OutlineInputBorder(
borderRadius: BorderRadius.only(),
gapPadding: 4,
borderSide: BorderSide(
color: AppColor.redColor,
width: 2,
)),
suffixIcon: const Icon(Icons.search),
hintText: controller.hintTextDestinationPoint,
hintStyle: AppStyle.title,
hintMaxLines: 1,
prefixIcon: IconButton(
onPressed: () {
controller.placeDestinationController.clear();
controller.clearPlacesDestination();
},
icon: Icon(
Icons.clear,
color: Colors.red[300],
),
),
),
controller: controller.placeDestinationController,
onChanged: (value) {
if (controller
.placeDestinationController.text.length >
5) {
controller.getPlaces();
controller.changeHeightPlaces();
}
},
// onEditingComplete: () => controller.changeHeight(),
),
),
IconButton(
onPressed: () {
controller.changeMainBottomMenuMap();
controller.changePickerShown();
},
icon: const Icon(
Icons.map_outlined,
color: AppColor.greenColor,
),
),
],
),
),
// controller.placesDestination.isEmpty
// ? InkWell(
// onTap: () {
// controller.changeMainBottomMenuMap();
// controller.changePickerShown();
// },
// child: Text(
// 'Choose from Map'.tr,
// style:
// AppStyle.title.copyWith(color: AppColor.blueColor),
// ),
// )
// : const SizedBox(),
Container(
height: controller.placesDestination.isNotEmpty
? controller.height
: 0,
color: AppColor.secondaryColor,
child: ListView.builder(
itemCount: controller.placesDestination.length,
itemBuilder: (BuildContext context, int index) {
var res = controller.placesDestination[index];
return InkWell(
onTap: () async {
controller.changeHeightPlaces();
controller.changeHeightPlaces();
controller.passengerLocation = controller.newMyLocation;
controller.convertHintTextDestinationNewPlaces(index);
controller.placesDestination = [];
controller.placeDestinationController.clear();
},
child: Padding(
padding: const EdgeInsets.symmetric(horizontal: 10),
child: Column(
children: [
Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Column(
children: [
Image.network(
res['icon'],
width: 20,
),
IconButton(
onPressed: () async {
await sql.insertData({
'latitude': res['geometry']
['location']['lat'],
'longitude': res['geometry']
['location']['lng'],
'name': res['name'].toString(),
'rate': res['rating'].toString(),
}, TableName.placesFavorite);
Toast.show(
context,
'${res['name']} ${'Saved Sucssefully'.tr}',
AppColor.primaryColor);
},
icon: const Icon(Icons.favorite_border),
),
],
),
Column(
children: [
Text(
res['name'].toString(),
style: AppStyle.title,
),
Text(
res['vicinity'].toString(),
style: AppStyle.subtitle,
),
],
),
Column(
children: [
Text(
'rate',
style: AppStyle.subtitle,
),
Text(
res['rating'].toString(),
style: AppStyle.subtitle,
),
],
),
],
),
const Divider(
thickness: 1,
)
],
),
),
);
},
),
)
],
));
}

View File

@@ -0,0 +1,365 @@
import 'package:flutter/material.dart';
import 'package:get/get.dart';
import 'package:google_maps_flutter/google_maps_flutter.dart';
import 'package:ride/constant/box_name.dart';
import 'package:ride/constant/table_names.dart';
import 'package:ride/views/widgets/elevated_btn.dart';
import '../../../constant/colors.dart';
import '../../../constant/style.dart';
import '../../../controller/functions/toast.dart';
import '../../../controller/home/map_passenger_controller.dart';
import '../../../main.dart';
GetBuilder<MapPassengerController> formSearchPlacesDestenation() {
// DbSql sql = DbSql.instance;
if (box.read(BoxName.addWork).toString() == '' ||
box.read(BoxName.addHome).toString() == '') {
box.write(BoxName.addWork, 'addWork');
box.write(BoxName.addHome, 'addHome');
}
return GetBuilder<MapPassengerController>(
builder: (controller) => Column(
children: [
Padding(
padding: const EdgeInsets.all(6),
child: Column(
children: [
Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Container(
width: Get.width * .7,
height: 40,
decoration: const BoxDecoration(
color: AppColor.secondaryColor),
child: TextField(
decoration: InputDecoration(
border: const OutlineInputBorder(
borderRadius: BorderRadius.only(),
gapPadding: 4,
borderSide: BorderSide(
color: AppColor.redColor,
width: 2,
)),
suffixIcon: const Icon(Icons.search),
hintText: controller.hintTextDestinationPoint,
hintStyle: AppStyle.title,
hintMaxLines: 1,
prefixIcon: IconButton(
onPressed: () {
controller.placeDestinationController.clear();
controller.clearPlacesDestination();
},
icon: Icon(
Icons.clear,
color: Colors.red[300],
),
),
),
controller: controller.placeDestinationController,
onChanged: (value) {
if (controller
.placeDestinationController.text.length >
5) {
controller.getPlaces();
controller.changeHeightPlaces();
}
},
// onEditingComplete: () => controller.changeHeight(),
),
),
IconButton(
onPressed: () {
controller.changeMainBottomMenuMap();
controller.changePickerShown();
},
icon: const Icon(
Icons.map_outlined,
color: AppColor.greenColor,
),
),
IconButton(
onPressed: () async {
List recentLocations = await sql.getCustomQuery(
'''
SELECT * FROM ${TableName.recentLocations}
ORDER BY id DESC
LIMIT 4
''');
Get.defaultDialog(
title: 'Latest Recent Trip'.tr,
content: recentLocations.isEmpty
? Center(
child: Column(
mainAxisAlignment:
MainAxisAlignment.center,
children: [
const Icon(
Icons.hourglass_empty_rounded,
size: 99,
color: AppColor.primaryColor,
),
Text(
'You Dont Have Any places yet !'.tr,
style: AppStyle.title,
),
],
),
)
: SizedBox(
height: Get.width * .5,
width: Get.width * .8,
child: ListView.builder(
itemCount: recentLocations.length,
itemBuilder:
(BuildContext context, int index) {
return Row(
mainAxisAlignment:
MainAxisAlignment.spaceBetween,
children: [
TextButton(
onPressed: () async {
Get.back();
controller
.convertHintTextDestinationNewPlacesFromRecent(
recentLocations,
index);
},
child: Text(
recentLocations[index]
['name'],
style: AppStyle.title,
),
),
IconButton(
onPressed: () async {
await sql.deleteData(
TableName.placesFavorite,
recentLocations[index]
['id']);
Get.back();
// ignore: use_build_context_synchronously
Toast.show(
context,
'${'You are Delete'.tr} ${recentLocations[index]['name']} from your list',
AppColor.redColor);
// Get.snackbar('Deleted'.tr,
// '${'You are Delete'.tr} ${favoritePlaces[index]['name']} from your list',
// backgroundColor:
// AppColor.accentColor);
},
icon: const Icon(
Icons.favorite_outlined),
),
],
);
},
),
),
);
// controller.changeMainBottomMenuMap();
// controller.changePickerShown();
},
icon: const Icon(
Icons.recent_actors,
color: AppColor.blueColor,
),
),
],
),
SizedBox(
height: 50,
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceAround,
children: [
InkWell(
onTap: () {
if (box.read(BoxName.addWork) == 'addWork') {
controller.workLocationFromMap = true;
controller.changeMainBottomMenuMap();
controller.changePickerShown();
} else {
controller.hintTextDestinationPoint = 'To Work';
print(box.read(BoxName.addWork));
final latLng = LatLng(
double.parse(
box.read(BoxName.addWork).split(',')[0]),
double.parse(
box.read(BoxName.addWork).split(',')[1]),
);
print(latLng);
controller.newMyLocation = latLng;
controller.update();
}
},
onLongPress: () {
Get.defaultDialog(
title: 'Do you want to change Work location',
middleText: '',
confirm: MyElevatedButton(
title: 'Yes'.tr,
onPressed: () {
Get.back();
controller.workLocationFromMap = true;
controller.changeMainBottomMenuMap();
controller.changePickerShown();
}));
},
child: Text(
'Work : ${box.read(BoxName.addWork) == 'addWork' ? 'Add Work' : box.read(BoxName.addWork).toString().split(',')[0] + box.read(BoxName.addWork).toString().split(',')[1]} '),
),
InkWell(
onLongPress: () {
Get.defaultDialog(
title: 'Do you want to change Home location',
middleText: '',
confirm: MyElevatedButton(
title: 'Yes'.tr,
onPressed: () {
Get.back();
controller.homeLocationFromMap = true;
controller.changeMainBottomMenuMap();
controller.changePickerShown();
}));
},
onTap: () {
if (box.read(BoxName.addHome) == 'addHome') {
controller.homeLocationFromMap = true;
controller.changeMainBottomMenuMap();
controller.changePickerShown();
} else {
controller.hintTextDestinationPoint = 'To Home';
print(box.read(BoxName.addHome));
final latLng = LatLng(
double.parse(
box.read(BoxName.addHome).split(',')[0]),
double.parse(
box.read(BoxName.addHome).split(',')[1]),
);
print(latLng);
controller.newMyLocation = latLng;
controller.update();
}
},
child: Text(
'Home : ${box.read(BoxName.addHome) == 'addHome' ? 'Add Home' : box.read(BoxName.addHome)} '),
),
],
),
)
],
),
),
// controller.placesDestination.isEmpty
// ? InkWell(
// onTap: () {
// controller.changeMainBottomMenuMap();
// controller.changePickerShown();
// },
// child: Text(
// 'Choose from Map'.tr,
// style:
// AppStyle.title.copyWith(color: AppColor.blueColor),
// ),
// )
// : const SizedBox(),
Container(
height: controller.placesDestination.isNotEmpty
? controller.height
: 0,
color: AppColor.secondaryColor,
child: ListView.builder(
itemCount: controller.placesDestination.length,
itemBuilder: (BuildContext context, int index) {
var res = controller.placesDestination[index];
return InkWell(
onTap: () async {
controller.changeHeightPlaces();
await sql.insertData({
'latitude': res['geometry']['location']['lat'],
'longitude': res['geometry']['location']['lng'],
'name': res['name'].toString(),
'rate': res['rating'].toString(),
}, TableName.recentLocations);
controller.changeHeightPlaces();
controller.passengerLocation = controller.newMyLocation;
controller.convertHintTextDestinationNewPlaces(index);
controller.placesDestination = [];
controller.placeDestinationController.clear();
},
child: Padding(
padding: const EdgeInsets.symmetric(horizontal: 10),
child: Column(
children: [
Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Column(
children: [
Image.network(
res['icon'],
width: 20,
),
IconButton(
onPressed: () async {
await sql.insertData({
'latitude': res['geometry']
['location']['lat'],
'longitude': res['geometry']
['location']['lng'],
'name': res['name'].toString(),
'rate': res['rating'].toString(),
}, TableName.placesFavorite);
Toast.show(
context,
'${res['name']} ${'Saved Sucssefully'.tr}',
AppColor.primaryColor);
},
icon: const Icon(Icons.favorite_border),
),
],
),
Column(
children: [
Text(
res['name'].toString(),
style: AppStyle.title,
),
Text(
res['vicinity'].toString(),
style: AppStyle.subtitle,
),
],
),
Column(
children: [
Text(
'rate',
style: AppStyle.subtitle,
),
Text(
res['rating'].toString(),
style: AppStyle.subtitle,
),
],
),
],
),
const Divider(
thickness: 1,
)
],
),
),
);
},
),
)
],
));
}

View File

@@ -15,15 +15,16 @@ GetBuilder<MapPassengerController> formSearchPlacesStart() {
builder: (controller) => Column( builder: (controller) => Column(
children: [ children: [
Padding( Padding(
padding: const EdgeInsets.all(12), padding: const EdgeInsets.all(8),
child: Row( child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween, mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [ children: [
Container( Container(
width: Get.width * .8, width: Get.width * .8,
height: 40,
decoration: decoration:
const BoxDecoration(color: AppColor.secondaryColor), const BoxDecoration(color: AppColor.secondaryColor),
child: TextField( child: TextFormField(
decoration: InputDecoration( decoration: InputDecoration(
border: const OutlineInputBorder( border: const OutlineInputBorder(
borderRadius: BorderRadius.only(), borderRadius: BorderRadius.only(),

View File

@@ -2,10 +2,9 @@ import 'package:flutter/material.dart';
import 'package:get/get.dart'; import 'package:get/get.dart';
import 'package:ride/constant/box_name.dart'; import 'package:ride/constant/box_name.dart';
import 'package:ride/constant/style.dart'; import 'package:ride/constant/style.dart';
import 'package:ride/controller/firebase/firbase_messge.dart';
import 'package:ride/controller/home/map_passenger_controller.dart'; import 'package:ride/controller/home/map_passenger_controller.dart';
import 'package:ride/main.dart'; import 'package:ride/main.dart';
import 'package:ride/views/home/map_widget.dart/form_search_places.dart'; import 'package:ride/views/home/map_widget.dart/form_search_places_destenation.dart';
import 'package:ride/views/widgets/elevated_btn.dart'; import 'package:ride/views/widgets/elevated_btn.dart';
import '../../../constant/colors.dart'; import '../../../constant/colors.dart';
@@ -69,18 +68,53 @@ class MainBottomMenuMap extends StatelessWidget {
controller.newMyLocation = controller.newMyLocation =
controller controller
.newStartPointLocation; .newStartPointLocation;
controller.hintTextStartPoint =
'${controller.newStartPointLocation.latitude.toStringAsFixed(4)} , ${controller.newStartPointLocation.longitude.toStringAsFixed(4)}';
controller.startLocationFromMap = controller.startLocationFromMap =
false; false;
controller.isPickerShown = false; controller.isPickerShown = false;
// print(controller.myLocation); } else if (controller
// print(controller .workLocationFromMap ==
// .newStartPointLocation); true) {
} else { controller
.hintTextDestinationPoint =
'To Work'.tr;
box.write(BoxName.addWork,
'${controller.newMyLocation.latitude.toStringAsFixed(4)} , ${controller.newMyLocation.longitude.toStringAsFixed(4)}');
controller.newMyLocation =
controller.newMyLocation;
controller.isPickerShown = false;
controller.workLocationFromMap =
false;
Toast.show(
context,
'Work Saved'.tr,
AppColor.greenColor);
} else if (controller
.homeLocationFromMap ==
true) {
controller
.hintTextDestinationPoint =
'To Home'.tr;
box.write(BoxName.addHome,
'${controller.newMyLocation.latitude.toStringAsFixed(4)} , ${controller.newMyLocation.longitude.toStringAsFixed(4)}');
controller.newMyLocation =
controller.newMyLocation;
controller.isPickerShown = false;
controller.homeLocationFromMap =
false;
controller.update();
Toast.show(
context,
'Home Saved'.tr,
AppColor.greenColor);
} else {
controller
.hintTextDestinationPoint =
'${controller.newMyLocation.latitude.toStringAsFixed(4)} , ${controller.newMyLocation.longitude.toStringAsFixed(4)}';
controller.newMyLocation = controller.newMyLocation =
controller.newMyLocation; controller.newMyLocation;
controller.isPickerShown = false; controller.isPickerShown = false;
// print(controller.myLocation);
// print(controller.newMyLocation);
} }
controller.placesDestination = []; controller.placesDestination = [];
@@ -121,94 +155,96 @@ class MainBottomMenuMap extends StatelessWidget {
], ],
), ),
) )
: Column( : Row(
mainAxisAlignment: mainAxisAlignment:
MainAxisAlignment.center, MainAxisAlignment.spaceEvenly,
children: [ children: [
SizedBox( IconButton(
height: 30, onPressed: () {
child: Row( controller
children: [ .changeMainBottomMenuMap();
IconButton( },
onPressed: () { icon:
controller controller.isMainBottomMenuMap
.changeMainBottomMenuMap(); ? const Icon(
}, Icons
icon: controller .arrow_circle_up_rounded,
.isMainBottomMenuMap size: 35,
? const Icon( )
Icons : const Icon(
.arrow_circle_up_rounded, Icons
size: 35, .arrow_circle_down_rounded,
) size: 35,
: const Icon( ),
Icons ),
.arrow_circle_down_rounded, Column(
size: 35,
),
),
Text(
'${'Where to'.tr} ${box.read(BoxName.name)}'),
],
)),
Row(
mainAxisAlignment: mainAxisAlignment:
MainAxisAlignment.center, MainAxisAlignment.center,
children: [ children: [
const SizedBox( SizedBox(
width: 10, height: 30,
), child: Text(
controller.noCarString == false '${'Where to'.tr} ${box.read(BoxName.name)}')),
? Text( Row(
'Nearest Car for you about ' mainAxisAlignment:
.tr) MainAxisAlignment.center,
: Container( children: [
decoration: controller.noCarString ==
BoxDecoration( false
borderRadius: ? Text(
BorderRadius 'Nearest Car for you about '
.circular(12), .tr)
color: : Container(
AppColor.redColor, decoration:
), BoxDecoration(
child: Padding( borderRadius:
padding: BorderRadius
const EdgeInsets .circular(
.all(6), 12),
child: Text( color: AppColor
'No Car in your site. Sorry!' .redColor,
.tr, ),
style: AppStyle child: Padding(
.title padding:
.copyWith( const EdgeInsets
color: AppColor .all(6),
.secondaryColor), child: Text(
'No Car in your site. Sorry!'
.tr,
style: AppStyle
.title
.copyWith(
color: AppColor
.secondaryColor),
),
),
), ),
), controller.noCarString ==
), false
controller.noCarString == false ? Container(
? Container( decoration: BoxDecoration(
decoration: BoxDecoration( border: Border.all(
border: Border.all( color: AppColor
color: AppColor .redColor,
.redColor, width: 3)),
width: 3)), child: Padding(
child: Padding( padding:
padding: const EdgeInsets
const EdgeInsets .all(4),
.all(4), child: Text((controller
child: Text((controller .nearestCar !=
.nearestCar != null
null ? controller
? controller .durationByPassenger
.durationByPassenger .toString()
.toString() : 'N/A')),
: 'N/A')), ),
), )
) : const SizedBox(),
: const SizedBox(), ],
)
], ],
) ),
], ],
), ),
), ),
@@ -236,12 +272,12 @@ class MainBottomMenuMap extends StatelessWidget {
controller.currentLocationToFormPlaces controller.currentLocationToFormPlaces
? const SizedBox() ? const SizedBox()
: formSearchPlacesStart(), : formSearchPlacesStart(),
formSearchPlaces(), formSearchPlacesDestenation(),
const SizedBox( const SizedBox(
height: 30, height: 10,
), ),
MyElevatedButton( MyElevatedButton(
title: 'Get Direction of Trip'.tr, title: 'Get Details of Trip'.tr,
onPressed: () async { onPressed: () async {
controller.changeMainBottomMenuMap(); controller.changeMainBottomMenuMap();
@@ -269,20 +305,6 @@ class MainBottomMenuMap extends StatelessWidget {
style: AppStyle.title, style: AppStyle.title,
), ),
), ),
// IconButton(
// onPressed: () {
// FirebaseMessagesController()
// .sendNotificationToAnyWithoutData(
// 'title',
// 'body',
// // 'e5IXztYGS1W9zFvv-gmMRL:APA91bF7-fFzksCRXIk0Fm7IfQuhHL0df-vnDW8DNNKa3sWea649j3Obc8PhyJo9UOxKBtrvoJxYcbjclFKpvycAuhG0lv_e4hkavy-LZ6SsAu5J5bYrPz6-0BbyLdLUHoBuOFlNMvmN');
// 'eoV61-RSFUxLrCa88xaSG2:APA91bFmgGVTVH0mhjGhFqrB2_rMf0l0udBUzEUW-V2XlxtnYeDTnpESYRRCI_tMQnbDqQ3PK7pFMzW0-CZolS-pURSkwbwvnbVtV9VHB2UuOrKG3MYpGFsWfmjUdyRIOe30nx-eVkOu');
// },
// icon: const Icon(
// Icons.add,
// color: AppColor.blueColor,
// ),
// ),
], ],
) )
], ],

View File

@@ -7,7 +7,7 @@ import '../../../constant/style.dart';
import '../../../controller/home/map_passenger_controller.dart'; import '../../../controller/home/map_passenger_controller.dart';
import '../../../main.dart'; import '../../../main.dart';
import '../../widgets/elevated_btn.dart'; import '../../widgets/elevated_btn.dart';
import 'form_search_places.dart'; import 'form_search_places_destenation.dart';
class PickerAnimtionContainerFormPlaces extends StatelessWidget { class PickerAnimtionContainerFormPlaces extends StatelessWidget {
PickerAnimtionContainerFormPlaces({ PickerAnimtionContainerFormPlaces({
@@ -73,7 +73,7 @@ class PickerAnimtionContainerFormPlaces extends StatelessWidget {
controller.isPickerShown controller.isPickerShown
? InkWell( ? InkWell(
onTap: () {}, onTap: () {},
child: formSearchPlaces(), child: formSearchPlacesDestenation(),
) )
: Row( : Row(
mainAxisAlignment: mainAxisAlignment:

View File

@@ -19,7 +19,6 @@ class WaletCaptain extends StatelessWidget {
Get.put(CaptainWalletController()); Get.put(CaptainWalletController());
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
Get.put(CreditCardController());
return MyScafolld( return MyScafolld(
title: 'Captain Wallet'.tr, title: 'Captain Wallet'.tr,
body: [ body: [

View File

@@ -5,6 +5,7 @@
import FlutterMacOS import FlutterMacOS
import Foundation import Foundation
import agora_rtc_engine
import audio_session import audio_session
import device_info_plus import device_info_plus
import file_selector_macos import file_selector_macos
@@ -13,6 +14,7 @@ import firebase_messaging
import flutter_local_notifications import flutter_local_notifications
import flutter_secure_storage_macos import flutter_secure_storage_macos
import geolocator_apple import geolocator_apple
import iris_method_channel
import just_audio import just_audio
import location import location
import package_info_plus import package_info_plus
@@ -23,6 +25,7 @@ import video_player_avfoundation
import wakelock_plus import wakelock_plus
func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) { func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) {
AgoraRtcNgPlugin.register(with: registry.registrar(forPlugin: "AgoraRtcNgPlugin"))
AudioSessionPlugin.register(with: registry.registrar(forPlugin: "AudioSessionPlugin")) AudioSessionPlugin.register(with: registry.registrar(forPlugin: "AudioSessionPlugin"))
DeviceInfoPlusMacosPlugin.register(with: registry.registrar(forPlugin: "DeviceInfoPlusMacosPlugin")) DeviceInfoPlusMacosPlugin.register(with: registry.registrar(forPlugin: "DeviceInfoPlusMacosPlugin"))
FileSelectorPlugin.register(with: registry.registrar(forPlugin: "FileSelectorPlugin")) FileSelectorPlugin.register(with: registry.registrar(forPlugin: "FileSelectorPlugin"))
@@ -31,6 +34,7 @@ func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) {
FlutterLocalNotificationsPlugin.register(with: registry.registrar(forPlugin: "FlutterLocalNotificationsPlugin")) FlutterLocalNotificationsPlugin.register(with: registry.registrar(forPlugin: "FlutterLocalNotificationsPlugin"))
FlutterSecureStoragePlugin.register(with: registry.registrar(forPlugin: "FlutterSecureStoragePlugin")) FlutterSecureStoragePlugin.register(with: registry.registrar(forPlugin: "FlutterSecureStoragePlugin"))
GeolocatorPlugin.register(with: registry.registrar(forPlugin: "GeolocatorPlugin")) GeolocatorPlugin.register(with: registry.registrar(forPlugin: "GeolocatorPlugin"))
IrisMethodChannelPlugin.register(with: registry.registrar(forPlugin: "IrisMethodChannelPlugin"))
JustAudioPlugin.register(with: registry.registrar(forPlugin: "JustAudioPlugin")) JustAudioPlugin.register(with: registry.registrar(forPlugin: "JustAudioPlugin"))
LocationPlugin.register(with: registry.registrar(forPlugin: "LocationPlugin")) LocationPlugin.register(with: registry.registrar(forPlugin: "LocationPlugin"))
FPPPackageInfoPlusPlugin.register(with: registry.registrar(forPlugin: "FPPPackageInfoPlusPlugin")) FPPPackageInfoPlusPlugin.register(with: registry.registrar(forPlugin: "FPPPackageInfoPlusPlugin"))

View File

@@ -17,6 +17,14 @@ packages:
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "1.3.16" version: "1.3.16"
agora_rtc_engine:
dependency: "direct main"
description:
name: agora_rtc_engine
sha256: "1ff249665a6a86fe0db13c7026853a92a715abeb819d8ad68bf5927f890e2c45"
url: "https://pub.dev"
source: hosted
version: "6.2.6"
analyzer: analyzer:
dependency: transitive dependency: transitive
description: description:
@@ -1096,6 +1104,14 @@ packages:
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "1.0.4" version: "1.0.4"
iris_method_channel:
dependency: transitive
description:
name: iris_method_channel
sha256: "708a862849b26452d86a0ab1ff010eb43d03cc811084b185270ceda45ff473e6"
url: "https://pub.dev"
source: hosted
version: "2.0.0-dev.4"
js: js:
dependency: transitive dependency: transitive
description: description:

View File

@@ -50,6 +50,7 @@ dependencies:
cached_network_image: ^3.3.0 cached_network_image: ^3.3.0
calendar_builder: ^0.0.6 calendar_builder: ^0.0.6
fl_chart: ^0.66.0 fl_chart: ^0.66.0
agora_rtc_engine: ^6.2.6

View File

@@ -6,14 +6,18 @@
#include "generated_plugin_registrant.h" #include "generated_plugin_registrant.h"
#include <agora_rtc_engine/agora_rtc_engine_plugin.h>
#include <file_selector_windows/file_selector_windows.h> #include <file_selector_windows/file_selector_windows.h>
#include <firebase_core/firebase_core_plugin_c_api.h> #include <firebase_core/firebase_core_plugin_c_api.h>
#include <flutter_secure_storage_windows/flutter_secure_storage_windows_plugin.h> #include <flutter_secure_storage_windows/flutter_secure_storage_windows_plugin.h>
#include <geolocator_windows/geolocator_windows.h> #include <geolocator_windows/geolocator_windows.h>
#include <iris_method_channel/iris_method_channel_plugin_c_api.h>
#include <local_auth_windows/local_auth_plugin.h> #include <local_auth_windows/local_auth_plugin.h>
#include <url_launcher_windows/url_launcher_windows.h> #include <url_launcher_windows/url_launcher_windows.h>
void RegisterPlugins(flutter::PluginRegistry* registry) { void RegisterPlugins(flutter::PluginRegistry* registry) {
AgoraRtcEnginePluginRegisterWithRegistrar(
registry->GetRegistrarForPlugin("AgoraRtcEnginePlugin"));
FileSelectorWindowsRegisterWithRegistrar( FileSelectorWindowsRegisterWithRegistrar(
registry->GetRegistrarForPlugin("FileSelectorWindows")); registry->GetRegistrarForPlugin("FileSelectorWindows"));
FirebaseCorePluginCApiRegisterWithRegistrar( FirebaseCorePluginCApiRegisterWithRegistrar(
@@ -22,6 +26,8 @@ void RegisterPlugins(flutter::PluginRegistry* registry) {
registry->GetRegistrarForPlugin("FlutterSecureStorageWindowsPlugin")); registry->GetRegistrarForPlugin("FlutterSecureStorageWindowsPlugin"));
GeolocatorWindowsRegisterWithRegistrar( GeolocatorWindowsRegisterWithRegistrar(
registry->GetRegistrarForPlugin("GeolocatorWindows")); registry->GetRegistrarForPlugin("GeolocatorWindows"));
IrisMethodChannelPluginCApiRegisterWithRegistrar(
registry->GetRegistrarForPlugin("IrisMethodChannelPluginCApi"));
LocalAuthPluginRegisterWithRegistrar( LocalAuthPluginRegisterWithRegistrar(
registry->GetRegistrarForPlugin("LocalAuthPlugin")); registry->GetRegistrarForPlugin("LocalAuthPlugin"));
UrlLauncherWindowsRegisterWithRegistrar( UrlLauncherWindowsRegisterWithRegistrar(

View File

@@ -3,10 +3,12 @@
# #
list(APPEND FLUTTER_PLUGIN_LIST list(APPEND FLUTTER_PLUGIN_LIST
agora_rtc_engine
file_selector_windows file_selector_windows
firebase_core firebase_core
flutter_secure_storage_windows flutter_secure_storage_windows
geolocator_windows geolocator_windows
iris_method_channel
local_auth_windows local_auth_windows
url_launcher_windows url_launcher_windows
) )