Save in a dataSheet the data that is saved in the slots


#1

Probably an easy thing to do but I don’t get to do it.

I have a already working the Login gate with Firebase configured and the user data is stored in the dataSlots. I also have a dataSheet connected with Firebase to save user data like email, photo, userName, etc. How can I link/save the data in the slots into the userList dataSheet?


#2

You cannot do this “automatically” without adding button interaction.

If you want to have this done automatically after successful login then you need to edit the login plugin and probably Firebase plugin code to do the saving.


#3

Ok. No problem doing it manually. I was preparing the dataSheet linked with the collection of users in my Firebase but some kind of error appeared. I don’t know what is wrong because I have done this before and it worked just fine. I leave a screenshot:


That is my users collection and I have placed a query to obtain just the user that has made the login. In the dataSlot I have manually entered the default value for my test user so I can test the query. I have done that before and it was working, however now I have the following error message:
38
Any idea what is happening?


#4

We’ve seen the similar kind of issues with our Firebase demo projects lately. Sometimes loading data works and sometimes it doesnt. So far we haven’t found what is causing this. It works on exported code but something breaks when loading data into Studio. It could be something related to Node etc. but we’ll keep investigating this.


#5

Ok. I am going to try on exported code and I’ll let you know. Thank you!


#6

Thanks, let us know if it works. Could you also zip and send us (hello@neonto.com) the project file so we can test it out.


#7

I just sent the email with the project indicating the dataSheet where the issue is. Also, I tried to run the project and see if there is an issue and apparently there is. It could also be that I am not doing things well but I leave the screenshot and I explain.

I am trying to display the picture of the user that is active at the moment. The authentication method is email, so the picture is referenced in the database as a value ==> userPhoto = [photoLink]. In React Studio I have placed two pictures to try both methods: the right picture in the screenshot is a “Placeholder” and I changed the default value for the generic profile icon that you can see in the screenshot. I also changed the data source to the field ‘userPhoto’ in the dataSheet that I am having issues querying to show only the active user data. As you can see the default picture is not changing for the one that is supposed to be showing.

The other picture next to it is the same but instead of a placeholder is a picture that I didn’t change (it is showing the default in React Studio) but I put the field ‘userPhoto’ as the data source. Same thing as before. It does not change.

In the console you can see that the query is just fine and it was supposed to be working.


#8

Hi, thanks for the project file. It seems that you had multiple lines of text in Data slots default value. Try going into data slot and edit it so that the value is correct.


#9

You are right. When I went into the code I found this:
45
However, in React Studio I can see this:


I imagine there is some kind of bug, as I don’t have any value in that field and there is nothing I can delete unless I go into the code.


#10

Just select the default value and click arrow down and you’ll see it :slight_smile:

If you copy (CMD+A) the value from Data slot view you’ll see that you’ve added (probably mistake while copying and pasteing values) line change which “hides” the rest of the text in Data slot view.


#11

Oh my… I am sorry about that. You were right absolutely right. This was embarrassing :joy:

Already solved. Thank you!