All threads / Advanced Mailboxer: Multiple User Conversations Discussion
Ask A Question


You’re not receiving notifications from this thread.

Advanced Mailboxer: Multiple User Conversations Discussion

Itzik Ben Hutta ·

Cool music entrance :) Great video of course.

Thought it was about time to spruce up the videos. :)

Great one! Can you cover mailboxer attachments? Thanks!

Absolutely will cover that! :D

hiyas this line videos is for using imap, pop to recive emial or is only to make messages between users in the app ?

Keyword args are the best part of ruby 2 (IMO). I use them in my own code whenever a method takes more than 1 arg. I try to keep methods simple so that there is only one to start with, but when I can't, it adds a lot of clarity. Thanks for bringing it up. I hope it becomes more common.

Thank you chris for this cover on this great gem

Hey Chris Just a thought but instead user_id could you cover how to make first_name & last_name as the parameters?

For the select box, you can customize it to display user names using this:

hey chris, if i want to NOT send email s for every message that i send to a user, how can i do that? how can i just keep these messages internal in my app? thanks

Just update the Mailboxer config to disable sending emails and you should be all set:

  config.uses_emails = false

Hey @excid3:disqus do you think you will come back to this and explain the cross model conversations? E.g. I might have a Client model and User model

and/or have message types like Feedback or Support but use Mailboxer for both?


I wasn't planning to dive more into it, but I could be persuaded.

As far as multiple models, there's nothing special other than including the acts_as_messageable on them I think. See:

For different conversation types, you can probably add a column to the mailboxer_conversations table for the conversation_type and then you'd just have to create the Conversation record with that extra attribute. You may either need to create conversations directly through Mailboxer::Conversation model or you might do a send_message and then update the Mailboxer::Conversation record with the conversation_type after it has been created. I'm not sure which the best solution would be there but you can experiment with both and see what's cleanest / easiest. All in all that shouldn't be too bad.

Erick Recher ·

Do you discuss how to delete/trash messages?


Does anyone know how to fix this issue? The ampersand is showing up in html, rather than showing the ampersand symbol. Ironically, Chinese characters show up fine. :D

Thanks for any feedback.

I love the insight that an out-of-date gem can be an opportunity to learn how to level up your skills. BTW, here's an update about mailboxer: someone has forked and has answered some of the pull requests.

If you want a more updated version of mailboxer, check this out:

Join the discussion

Want to stay up-to-date with Ruby on Rails?

Join 70,078+ developers who get early access to new tutorials, screencasts, articles, and more.

    We care about the protection of your data. Read our Privacy Policy.

    logo Created with Sketch.

    Screencast tutorials to help you learn Ruby on Rails, Javascript, Hotwire, Turbo, Stimulus.js, PostgreSQL, MySQL, Ubuntu, and more. Icons by Icons8

    © 2023 GoRails, LLC. All rights reserved.