Issue I have the data in the following structure: stage/data/groups(coll)/ group_name group_id participants(coll)/userid My requirement is to write the firebase rule with the following condition. If user A calls the groups collection, then it should returns ALL the groups if
Continue readingTag: google-cloud-firestore
How to get the distance from center when using geoflutterfire with flutter
Issue I am using the geoflutterfire2 package to retrieve data within a certain radius. The documentation mention that for each document you can even get the distance from center. This is a code snippet that I got from Jeff Delaney
Continue readingChat app showing messages randomly when user sends a message and messages are not in proper order
Issue I have made a basic chat app using firebase after completing my tutorial. but the app does not always show messages in order. Also, my messages are supposed to start from the bottom but they don’t always do. I
Continue readinghow to direct user to their respective screen using firestore when they get logged in,in Flutter?
Issue I have developed a sign up system in my app using firestore in Flutter where user’s data can be retrieved from database with following method: //get user’s data from firestore Future<String?> getUser(String email) async { try { CollectionReference users
Continue readingCode cant read the document that has a studentID field
Issue I have the studentID string field in each of the documents of my Students Collection Future<Student> fetchStudentDetails(String studentID, String subjectID) async { try { // Replace this with your actual code to fetch student details from Firestore DocumentSnapshot studentSnapshot
Continue readingHow to get only the user's data from firestore rather than all data in the collection?
Issue I’m trying to make a flutter app that allows users to log into an account and then store contact details in a firebase firestore. It currently shows the contact details for all registered accounts. I want the user to
Continue readinghow to save user data in cloud firestore using flutter in 2024?
Issue I am tryna save each user’s data in cloud firestore, searched on stackoverflow, things felt like mixed, as the old solutions are giving errors in 2024, meanwhile am new to beginner, my code below creates a new user on
Continue readingI get an error with snapshot.data()["~~~"] flutter
Issue I’m trying to get the value from Firestore with the following code. But I’m sorry I got this error. Help me DocumentSnapshot snapshot = await FirebaseFirestore.instance.collection("users").doc(user.uid).get(); print(snapshot.data()["location"] as String); Details of the error The method ‘[]’ can’t be unconditionally
Continue readingHow to iterate over items inside a recyclerview adapter get a result and pass it to a fragment
Issue Below is my recyclerview adapter, whenever my recyclerview is populated I iterate through all views and calculate total incomes and expenses and get the balance in a variable called MainAccountBalance. how to pass this variable value to my Mainfragment
Continue readingMy flutter code is showing that a widget is considered dead code, why is this?
Issue While I’m making an app, my IDE raised an error that part of my code is dead. The only problem is that, I don’t know why it’s giving me that error I tried rewriting the code and even going
Continue reading