Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Message Bundle Laravel Package

braune-digital/message-bundle

View on GitHub
Deep Wiki
Context7

BrauneDigitalMessageBundle

This Symfony2-Bundle provides a base for user to user and system messaging.

Requirements

In order to install this bundle you will need:

  • DoctrineORM (Entity Persistence)
  • SonataEasyExtends (optional but strongly recommended)

Installation

Just run composer:

composer require braune-digital/message-bundle

And enable the Bundle in AppKernel.php:

public function registerBundles()
    {
        $bundles = array(
          ...
          new BrauneDigital\MessageBundle\BrauneDigitalMessageBundle(),
          ...
        );

In order to use the bundle you have to

Extend the Bundle

Just run:

php app/console sonata:easy-extends:generate --dest=src BrauneDigitalMessageBundle

Enable the extended Bundle in AppKernel.php:

public function registerBundles()
    {
        $bundles = array(
          ...
          new Application\BrauneDigital\MessageBundle\ApplicationBrauneDigitalMessageBundle(),
          ...
        );

Add the relations to your User-Entity

<one-to-many target-entity="Application\BrauneDigital\MessageBundle\Entity\UserHasConversation" field="conversations" mapped-by="user">
            <cascade><cascade-remove /></cascade>
            <order-by>
                <order-by-field name="joinedOn" direction="DESC"/>
            </order-by>
        </one-to-many>

        <one-to-many target-entity="Application\BrauneDigital\MessageBundle\Entity\UserHasMessage" field="messages" mapped-by="user">
            <cascade><cascade-remove /></cascade>
            <order-by>
                <order-by-field name="date" direction="ASC"/>
            </order-by>
        </one-to-many>

        <one-to-many target-entity="Application\BrauneDigital\MessageBundle\Entity\Message" field="sentMessages" mapped-by="by">
            <order-by>
                <order-by-field name="date" direction="ASC"/>
            </order-by>
        </one-to-many>

Todo

  • Add Document Version
  • Validation / Constraints
  • Security (Voters)
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
craftcms/url-validator
directorytree/privacy-filter-classifier
directorytree/privacy-filter
datacore/hub-sdk
develia/commons
cuci/prototurk-sdk
cuci/prototurk-sdk-symfony
develia/geo-bundle
dreamzy/livewire-charts
touchestate-sdk/php-sdk
22h/doctrine-garbage-collection-bundle
agtp/agtp-php
agtp/mod-php
splash/sonata-admin
splash/metadata
splash/openapi
splash/scopes
splash/toolkit
testo/output-teamcity
testo/bridge-symfony