Assigning Calendar Event to another User

Hi!

I have an app where users sign up and then invite others to join and view their calendar.

The admin user creates an event and then “assigns” 1 of their users to that event.

I want the non-admin user’s calendar to only display events that have been assigned to them.

The way that I had set this up was the their calendar searched for events created by their admin and which contained their name. However, I know this will be cause the app to be slow because it will have to scan all the event data looking for the appropriate events to display.

So in the User type, I created a field called “list of events”. Now the non-admin user’s calendar displays “Current User’s List of Events”.

Now, when the admin creates an event, that event needs to be added to the specified user’s “list of events”. This is where I’m stuck. I can only find a way to add the event to the current user’s (admin) list of events, not another user specified by the admin when creating the event.

I hope this makes sense and that someone can shed some light :slight_smile:

Hey @mauraduquette

How do you let admin users choose which user they want to invite to the event? Are the users listed in a dropdown? RG? Searchbox?

Hey @ambroisedlg

It’s a dropdown menu which displays the names of the non-admin users (the choices source is a search for users who were created by the current admin user).

Thanks!

In the same workflow than for the admin user, just include an action Make changes to Dropdown’s User > Events add Result of step X (whichever Step used to create the event)

Let me know if that works

Hi @ambroisedlg

I can’t find that option in my “Make changes to thing” action.

This is how I have the dropdown set up:

When I try to make changes to the user after having created the event, I get stuck:

image

There’s no “add” option that I can see.

Thank you!

@mauraduquette can you share your editor in view-mode? it’ll probably be easier

@mauraduquette it shouldn’t be more complicated than this imo:

Editor: https://bubble.io/page?type=page&name=test&id=ambroisetestapps&tab=tabs-1
Demo: https://ambroisetestapps.bubbleapps.io/version-test/test?debug_mode=true

Yes, it was that simple :slight_smile: Thank you so much for the visual and for all your help!! I really appreciate it

1 Like

You’re welcome happy to help :slightly_smiling_face: