Adding users and babies to each other

Hi all,

I’m building an app for parents, and would like to enable different “profiles” the parent user can use depending on the baby they want to use the app for.

I’ve managed to allow users to add, update and delete babies, and only see the babies they are linked with. However, I’d like for them to be able to “share” baby’s profiles with others, e.g. a spouse. I’ve tried everything I can think of but I can’t get parents to add other users to baby’s profiles within the app.

Notes: I have set relationships between babies and users as multiple connections both ways. I can add new parents to babies myself in the database (outside the app). I’ve tried using forms for users to type a new email address of the intended sharee, but I can’t get the form to update the baby’s record with the inputted email address, or the user (of the inputted email address) to update with a new baby.

Any ideas much appreciated! I’m pretty new to this, so apologies if this is easy!

Hi Sam,

Does the user that is to be added already exist?
The many-to-many relationship only works with existing records. So first create the user, then add them as a parent to the baby :wink:

1 Like

Hi Steven,

Thanks for the response. I thought so too - though I don’t find myself able to add existing users either.

Do you have screenshots from where you ARE able to add and where you ARE NOT?
I could take a look.

Did I understand your question correctly? :face_with_monocle:

Thank you

Hi @StevenU and @dilon_perera

First of all, thank you both very much for the kind help! Firstly in answer to Steven question, but relevant for both of you.

I can add new parents to babies in the database menu:

I want to be able to add new parents in a format like this:

Does that make sense?

Dilon, you’re example looks really close to what I’m trying to accomplish! So thank you! The only part that still needs solving is that I don’t want to display a list of all users (there might be hundreds). I’d rather the user type in a specific user to add them onto the list, as in my last photo above.

Any tips on getting the last step would be much appreciated! I’ll be back online this afternoon to try and figure it out based on the foundation provided in your video in any case.

Thanks again to both of you!

1 Like

Your welcome Samuel :+1:

I think the way that you are trying to do is not possible. Because to add existing users you need like a dropdown or a list and a toggle ( like I created ). Or you have to create new user and update that new user and add the current baby.( You can add a create user action and Update new user action and add current baby to the relationship property)

need a dropdown

Or you have to create new user and update that new user and add the current baby.( You can add a create user action and Update new user action and add current baby to the relationship property)

And welcome to the community :partying_face:

Thank you

Thank you once again! I didn’t want users to be able to add each other to each other’s baby profiles so easy, so was trying to avoid a drop down list or similar. I think I found a workable solution though, and thought I’d share here.

I’ve created a form for the other party (say spouse or partner) to log in (this will require them to be next to each other or happy to share login details admittedly, but I don’t know if there’s a better solution).

Following this, I can update the newly logged-on account, then log out the new user, as shown below. The original user will need to log in again, but the baby is then “shared” as intended.


Thanks once again.


1 Like

Hi Sam,

So I think you’ve got the functional part of ‘adding’ covered now right?
The other part is more about inviting and accepting. Kind of like a friend invite/request.

You could set up a separate db/screen with invites which the other user must accept before being added. Alternatively you could create like an invite code that can be shared. After the receiving users inputs this code in a special screen, look up if the code exists and is valid and if so then add the baby/user.

I think both are a bit cleaner then what you designed now. But if it works for you don’t change it! :wink:

1 Like

Thanks Steven. Yes, it’s working. I may yet try to improve it with an invite system as you suggested. I’m not quite sure how to build that yet, but I’ll probably come back to it after fleshing out a few other sections of the app.

Thanks again in any case!