firebase-realtime-database

How to copy ratingbar value to firebase database android?

拥有回忆 提交于 2021-02-08 10:44:24
问题 I'm making a simple app for my school that the user will rate the service and press submit, which sends the data to firebase, but at the same time, resets the value of the rating bar so the next user can rate again. But I am having some difficulties and misunderstandings. Please Help! Here is my main activity code: package com.timothy.ratingch; import android.support.v7.app.AppCompatActivity; import android.os.Bundle; import android.view.View; import android.widget.Button; import android

Updating a value in firebase using nodejs as admin

喜你入骨 提交于 2021-02-08 10:40:35
问题 var ref=db.ref("users"); var upref = ref.child("-KXpWvL3cgzHvFYgArTW"); upref.update({ "name": "Ayaz" }); I m using this I am creating a reference to the key but this is not the right way , in my db i have users and then i have keys under that i have the name. Here I am creating a reference directly to the key and updating it. the structure of my db is: users .... -->key ............. -->name:"" So how can I update a specific name.? 回答1: You'll need to know a property of the user that you

How to delete or remove CardView from RecyclerView? Android Studio

限于喜欢 提交于 2021-02-08 10:33:39
问题 On my RecyclerView are CardViews containing details about a certain exercise and on my CardView, there is an ImageDeleteBtn beside it. How do I delete the CardView from the RecyclerView and on Firebase? This is my Adapter package com.lim.fiture.fiture.adapters; import android.content.Context; import android.support.v7.widget.RecyclerView; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.widget.EditText; import android.widget

How to delete or remove CardView from RecyclerView? Android Studio

岁酱吖の 提交于 2021-02-08 10:33:29
问题 On my RecyclerView are CardViews containing details about a certain exercise and on my CardView, there is an ImageDeleteBtn beside it. How do I delete the CardView from the RecyclerView and on Firebase? This is my Adapter package com.lim.fiture.fiture.adapters; import android.content.Context; import android.support.v7.widget.RecyclerView; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.widget.EditText; import android.widget

No setter/field for found Android Firebase

吃可爱长大的小学妹 提交于 2021-02-08 08:42:12
问题 I used FirebaseRecyclerAdapter to get all the childs of "Pro" using a Model class named " Spacecraft" and now I want to retrieve all the candidates into a child of Pro like "1" I created a public static "candidat" into "Spacecraft" and I used the setters and getters but still the same error This is my database: this is the Model Class public class Spacecraft{ private String name; private String desc; private String last; private candidat candidat; public Spacecraft.candidat getCandidat() {

How to save data in current uid in Firebase

故事扮演 提交于 2021-02-08 08:23:48
问题 I can't save new data ("messages") to current user. my code for push user info to Firebase var ref: FIRDatabaseReference! = FIRDatabase.database().reference() self.ref.child("Users").child("UserID").childByAutoId().setValue(["Name": userName, "Email": userEmail]) code for push messages to Firebase var messageRef: FIRDatabaseReference = FIRDatabase.database().reference() let uid = FIRAuth.auth()?.currentUser?.uid messageRef.child("Users").child("UserID").child(self.uid!).child("Messages")

How to select all users data, Ionic Firebase

假装没事ソ 提交于 2021-02-08 06:46:33
问题 I have usersProfile table, where save data by uid How to select all users uid and data? I can select only Authorized users data. getUsersData(token: string) { const userId = this.authService.getActiveUser().uid; return this.http.get('https://mainapp.firebaseio.com/usersProfile/' + userId + '.json?auth=' + token) .map((response: Response) => { const usersData: UsersData[] = response.json() ? response.json(): []; return usersData; }) .do((userData : UsersData[]) => { if (userData) { this

Declaring a variable as final for Firebase function. Checking if username and email exist

蓝咒 提交于 2021-02-08 06:28:24
问题 I am trying to make a register page. Before registering that user I will try to validate the username and email do not exist in the database. But I somehow cannot set the variable to be false when the username/email already exist so it will end up still registering the user. How can I do this? Please guide me on this. Checking if username and email already exist before register user: if (!checkIfUsernameExists(userName) && !checkIfEmailExists(userEmail)){ registerUser(); } Method for checking

Use different GoogleService-Info.plist for single project in xcode using swift4

房东的猫 提交于 2021-02-08 04:56:23
问题 I have a single project but with 4 different environments (Dev,Stagging,QA,Production). I have given their (environment's webservice url) paths from mobile's setting. Now I want to use different GoogleService-info.plist for all these different environments. Like when I select Dev from backend the project should take GoogleService-Info.plist of Dev project only. These GoogleService-Info.plists are created on 4 different accounts. Project should take the path of GoogleService-info.plist

Use different GoogleService-Info.plist for single project in xcode using swift4

痞子三分冷 提交于 2021-02-08 04:55:57
问题 I have a single project but with 4 different environments (Dev,Stagging,QA,Production). I have given their (environment's webservice url) paths from mobile's setting. Now I want to use different GoogleService-info.plist for all these different environments. Like when I select Dev from backend the project should take GoogleService-Info.plist of Dev project only. These GoogleService-Info.plists are created on 4 different accounts. Project should take the path of GoogleService-info.plist