I am building an inbox or private messaging system between my users. To do so i created a new thing called “Private talks” with the field “new message” inside. “New message” stores every input typed and send by users. I used a repeating group to display a list of “New message” . But the issue is i want “repeating group” to only display “New message” created by two specific users (the profile page owner and the visitor of this profile page) and ban anyone else from seeing this private message. Right now it’s working like a kind of forum everybody can see everything that is being said.
Your structure may need some re-organizing, but essentially each private message (or thread of private messages) should have an indicator of who they’re between. The creator of a thing is already a built in field, so you’d add another User type field to add the other person.
Then, filter your repeating group by these two users. For the visitor, they only want to see a RG that is constrained by the profile owner and themselves.
Share a link and I can take a look to help you more specifically.
Gaby | Coaching Bubble
Hello Gaby ! thx for replying me. if i share a link will you be able to open it??
Yes, just make sure your app is set to public. I’m about to be away for a couple hours, but leave the link here and I’ll check it out.
Just to chime in here, a suggestion is to create two data types. I created one for Message and another for Message Reply. The Message Reply has a data type for Message so all replies for that message show up when that Message is referenced. I know that this looks and sounds confusing, so I can share a link if it would help you.
yes please share
hello check pop up chat when you are in my workshop
Ok, the issue here is that you need to create the inbox interface first so that the profile owner knows which chat to use for different users.
I’d also restructure your data types like this:
- Users (type user, list)
- Messages (type text, list)
So, when the visitor is on the profile page and they want to message the profile owner for the first time, a new Private talk is created and User adds list “current user:plus item current profile page user”. Then messages add message input. So you have 1 private talk for each thread of messages between 2 users.
I’m assuming each user has their own profile, so you’d need to have a repeating group visible to the profile owner only: Search for Private Talks> Constraint: Users contain current user. This will return all private talks involving the profile owner - ones that they initiated and ones that were initiated by others. From there you can open a group to display a specific private talk’s messages list and add messages.
The first message (and private talk) can be created on the profile page or in this inbox area where you can search for other users, but the point is you need to create a “folder” system so that your users can easily access all of their private talks mainly so that the profile owner can keep them separated as well. Your current setup doesn’t allow the profile owner to distinguish between talks with users.
Let me know if you understand how to move from here.
Gaby | Coaching Bubble
okay i’m starting now doing what you just said and let you know what it gives !! THANK YOUUUUU
hello @romanmg , Gaby still i can"t buil the inbox part of my app despite your advices!