Is that possible to use a toggle to favorite an item list with External Users?

Hi community,

Is that possible to use toggle to allow users to favourite items in a list with an External users collection? I have seen examples using internal collections but not with External Users Collection.

Is that possible? If so, could you share an example?

All the best,
Edu

@edumagol definitely possible, am assuming you have the external collection field set as boolean.

When you select the toggle, and add action to it, select update > the boolean field with true/false to update your data in external collection.

I sharing a screenshot from xano external collection here:

FYI, for this to work, you need to do a create action first followed by updating the action. Ideally, you can just do it in creation step.

If you’re in Xano, Maybe you can add a favorite’s table and have 1 boolean field and another linked field to original record, so when you toggle it, it will add to specific record in the referenced table.

1 Like

Hey @bhanu !

So glad that it is possible and thanks for the detailed infomation on how to do it.

Yes, for the backen I’m using Xano.

I will try it later tonight… and will let you know if it worked.

By the way, thanks a lot for the fast and helpful support that you guys provide to the community.

All the best,
Edu

1 Like

Hi @bhanu , after trying for a while, I am still stuck at this point…

I am now being able to create a an action and add a True label when I click in the toggle. But I am still having difficult on two things:

  1. I still do not know how to prevent it to create the same record twice or more (per example, for post 1, if I click several times in its toggle, I will add a record several times into Xano’s table.

  2. I still do not know how to update the added record to false, if per example I decide to unlike one of the post per examples.

Sorry for disturbing you with this topic, but your help would be very apprecciated.

All the best,

Edu

See attached some pictures of my data tables and the way I am configuring the Toggle in Adalo.






Hi all community and also @bhanu who is helping me with this difficulty.

Could anyone please provide some help on how to solve this?

All the best,
Edu

@edumagol sorry for the delayed response, was busy a bit.

Ok, from your post I think you’re trying to update using POST from Adalo to Xano, when you do that it’ll go ahead and create a new record.

Instead you should be doing PUT and pass the record ID in your API call to xano to update the existing record.

And for the boolean to update, is it possible for you to first check the current state for the record and reverse that state when the checkbox is ticked/unticked?

Thanks

1 Like

Hi @bhanu , no problem, I totally understand… I apologize for myself being too anxious…

I will try to use the put method as you recommended.

I confess I do not know if I understood your question correctly (I believe it is because I am a front-end no-code beginner)… anyway.

Are you asking if I can do that on the backend (Xano) or at Adalo?

If it is in the backend, I will check if I can do that (I believe so) and give a feedback for you.

Anyway, thanks again for your help.

were you able to solve this problem? I have the same obstacle. In “what does this toggle do?” I don’t see any option in third parties, in this case I also use xano.
When selecting the “on” action, for example, update logged in user appears, which is where the toggle is, but no option appears either. En crear usuario si que me aparece, pero me crearía un nuevo usuario.