How do I access the original CONVERSATION in my messaging portion of app

In my app a user can contact a user via their profile page. A popup shows, a message is created and sent, this all works perfectly. In the database I have it create a new ‘CONVERSATION’ and set list with the two ‘PARTICIPANTS’. In the inbox section of the app, I want to access the current ‘CONVERSATION’ when the two users create messages back and forth. I have tried absolutely everything I can think of and am getting nowhere. My ‘CONVERSATION’ data type contains a field for ‘LISTS OF USERS’. This seems so simple but I can not figure out what I’m doing wrong.

Screenshot of the workflow from the create a new message button in the inbox of my app.

When the button is pressed a new message is created but it won’t tie it to the existing conversation or add the participants so the message doesn’t show anywhere.

2 parts here:

  1. The “Parent group’s Conversation” is not connected to the right data source. You have to set that parent group to the right datasource one way or another.

  2. When creating a message, you also want to have a step after that to “Make changes to a Conversation”. Your Conversation should have a “List of Messages”. This action should add the newly created Message to the intended “Conversation”.

If you need help more help, please share a screenshot of the parent group’s data source. Again, this is the reason why your intended Conversation is not saving to your newly created message.

Note: This also could be a privacy settings issue but I’d need more information to determine that.

Thanks for your help @dbevan, I added the list of messages to my conversation data type and added the message to it in the workflow. The one thing I simply can not figure out is why my parent group conversations are not connecting. Sorry, I’m so new to Bubble, is this what you mean by my parent groups data source? (screen shot)

Here’s the screenshot of the dynamic data I have it set to in the text of my RG cell.

Does this tell you anything I’m doing wrong? THANKS AGAIN!

This helps a little. Please screenshot the button and the group the button is in.

Right now, your repeating group is displaying a list of Conversations. Then inside each cell (Conversation) , you’re displaying the person the current user is having a conversation with.

That all makes sense but I’m not sure where the “Create New Message” button is.

@dbevan Thanks again, does this help?

Ok good, we’re getting closer!

So from my understanding, you’re clicking on a Conversation in your Conversations repeating group. Please show that workflow.

Please also show the data source of the Messages repeating group above the “send message” button.

Yes, you are correct, here is my workflow when clicking on a conversation in my RG.

Here is the data source of the Messages repeating group above the send button

Here is a screenshot of the data source of the main group - Messages

1 Like

Look at the workflow step “Display data in Messages”. Messages, I assume, is a Group with a Conversation as the Data Type.

So let’s go all the way back to the root of the problem. When you’re clicking the “send message” button and creating a new message, the Conversation field in that message should be the exact same data source.

So in this case, the newly created Message’s Conversation field should be something like “Messages’s Conversation”. “Messages” is the Group. “Conversation” is the Messages’s Group’s data source.

1 Like

Thanks @dbevan! That was it!

1 Like

Great work!!!