Support the ongoing development of Laravel.io →
posted 10 years ago
Packages
Last updated 2 years ago.
0

Can you have multiple conversation between the same users ? Or just one ?

Last updated 2 years ago.
0

You can have private multi conversations with all users you want :) all users can have chat with every numbers of others users in the same conversation or different .user ALPHA can have chat with user BETA but can have only 1 conversation between them. But ALPHA can have another chat with BETA & GAMMA.

Last updated 2 years ago.
0

This is exactly what I was making myself. But will probably switch to your package. Looking perfect.

Last updated 2 years ago.
0

That's good, I'm glad if I save you a bit of time. I think it is a good package. You can make a complex chat in 1 hour. Obviously this is still a fresh package released 2 hours ago, Is fully unit tested, and I implemented on my current project so i can use it and improve it and hopefully without find any bug :)

Last updated 2 years ago.
0

It's not working for me. The problem has something to do with

SQLSTATE[42S02]: Base table or view not found: 1146 Table 'trinity_development.participants' doesn't exist (SQL: select `conversation_joined`.*, `participants`.`participant_id` as `pivot_participant_id`, `participants`.`conversation_joined_id` as `pivot_conversation_joined_id` from `conversation_joined` inner join `participants` on `conversation_joined`.`id` = `participants`.`conversation_joined_id` where `conversation_joined`.`deleted_at` is null and `participants`.`participant_id` = 1 and `participants`.`participant_type` = Trinity\Models\User)
Last updated 2 years ago.
0

mmmh Can you tell me witch method you used i may miss something, can you be a bit more specific :)

I'm currently using the package i didn't meet this issue. I will glad to help you. Do a composer update i fixed other staff

Last updated 2 years ago.
0

I used the relationships provided at the documentation. That is causing this error.

I'm just getting the conversations like so

Auth::user()->conversations
Last updated 2 years ago.
0

If you want to get conversations of a specific user you have to use

Mex::conversation()->from($user_id)->lists();

Because like so Mex will check if the user has some conversations deleted or in archive, and it will not get them.

if you instead use Auth::user()->conversations it will get all the conversations even deleted or in archive so is not useful.

I got the same error trying to do what you said, but chancing the realtions to:

 public function conversations()
    {
        return $this->morphMany('Fenos\Mex\Models\ConversationJoined', 'participant');
    }

    public function messages()
    {
        return $this->morphMany('Fenos\Mex\Models\Messages', 'participant');
    }
 

Will fix the problem but still is not the right wait to use Mex :). Remember to update the version to 1.0.3 :) Hope you enjoy it

I'll create a trait, like so i can manage the relations for each update

Last updated 2 years ago.
0

Is there a live demo of this somewhere?

Last updated 2 years ago.
0

The first time that I have free time I'll make a demo of it :)

Last updated 2 years ago.
0

I agree .. a demo would be quite useful.

Last updated 2 years ago.
0

Sign in to participate in this thread!

Eventy

Your banner here too?

fenos fenos Joined 8 Feb 2014

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2024 Laravel.io - All rights reserved.