Forum Academy Marketplace Showcase Pricing Features

How to get users interact with each other?

Okay so in my app I have a thing called Message. And I have a page where the user can create messages for other users. Now I am encountering a problem.I can display the message the user will get from others but I can’t display the messages that the user will send. In fact I can’t think of getting this thing done.

In my message thing I have the following fields:
receiver type user
sender type user
message type Text
read type true/false

This is the workflow when the button send is clicked. Can someone help me with this.

And this is how the repeating group looks on my page

You could try creating a new data field (for Message) that is a list:

for example:
Data type = “visible.to” (which is a list of users)

Then when you create a message add the sender and the receiver to the visible.to

Then for repeating group you can set condition that says "visible.to contains current user plus item: receiver


That may not exactly work; it kind of depends how you’ve set it all up.
Something like that, I think could work though.

I don’t really understand this. Do you mean that as a receiving user you can see messages sent to you but as the sending user you can’t see a list of messages you have sent? Please clarify.

Out of interest, what is the ‘deleted’ suffix in your Created by search-constraint for? I have never noticed it as an option. What does it do? Are you trying to exclude messages that the current user has sent? If so, I tend to use Created by <> Current user for that purpose.

Do you mean that as a receiving user you can see messages sent to you but as the sending user you can’t see a list of messages you have sent? Yes that is the problem

Well by mistake I deleted that field. In my messaging page a list is provided to the user from where he can click on the name of the user and the relevant messages between the pertaining user and the current user shows up in the repeating group. Whenever the current user clicks the name from the list provided i the messaging app a new selected user is created.

So, in the repeating group you’ve shown, what are you trying to display? Messages sent by the current user? If so, why not just set the constraint to sender = current user?

Sorry, I think maybe I just need to understand what you’re trying to do a bit more.

Okay so for example let say you are using my app. In the message page you have messaged me. In the repeating group you would not see the message you have send. But in my page(receiver’s page) I will see your message. And if I reply to your message then in the repeating group I will not see the message that have send you. But you will see the message.

I hope that explains the situtation

If so, why not just set the constraint to sender = current user?

I have done that i.e. in the constraint section But then I see no messages at all.

There are foundations for a messaging app (with multiple recipients etc) here…

https://buildingonbubble.com/block/message-app-1473140414981x593174850883289100

1 Like

I created the following before I saw @NigelG’s block, which is more comprehensive. Between the two, I hope you find the help you need.

https://bubble.io/page?type=page&name=messages&id=louisforum&tab=tabs-1