Weave 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

Extra Bundle Laravel Package

dacorp/extra-bundle

View on GitHub
Deep Wiki
Context7

Dacorp Extra Bundle

Collection of services, helper, and standard view for standard services you want to use in any kind of website.

It's a Work in Progress mainly used for other project. You can browse the repository, but I would not recommend you to use it unless you know what you want ;)

This branch (master) supports PUGXMultuUserBundle master, FOSUserBundle master and Symfony master.

The branch (1.0) supports PUGXMultuUserBundle 2.0, FOSUserBundle 2.0 and Symfony >=2.1, <2.4.

Some of the feature included :

  • Image Uploader Service : Integration of Punkave Image Uploader as a service tight to a generic Media Model (plan to update to https://github.com/1up-lab/OneupUploaderBundle)
  • Simple README functionality included by default on demand (usually dev environment only is fine) : give you a page with a html rendered version of the README.md Markdown file located in the root of your Project
  • Manage metas for twitter cards and open graph
  • Provide switch lang feature (routes, knpmenu action, and Handler)

##Using the ImageUploader Service:

include the default uploader {% include "DacorpExtraBundle:Common:file-upload-control.html.twig" %}

Twig extension to manage metas

Support Twitter Card and Facebook Open graph Meta in a simple way with Twig extension.

Add global twig variables for specific data

####Define specific account data in parameters.yml.dist parameters: facebook_app_id: XXX twitter_widget_id: XXX twitter_default_account: XXX

####Update globals twig: globals: facebook_app_id: %facebook_app_id% twitter_default_account: %twitter_default_account%

####Call twig extension within twig template

partner is an entity which has all needed informations to generate basic open graph meta and basic twitter card (only restaurant.restaurant supported for now).

{% block head_meta %}
    {{ allMetas({'title': partner.title, 'description':partner.description,
    'url': path('get_partner', { 'alias': partner.alias }) , 'object':partner, 'images': partner.partnerMedias}) }}
{% endblock %}

##Using the switch lang feature

Add the route

##Using some extended mopa forms

We extends the mopa form widget with some updated widgets. Have a look to Resources/views/Form/fields.html.twig

And setup mopa to use that form field definition file


mopa_bootstrap:
    form:
        templating:           DacorpExtraBundle:Form:fields.html.twig

##Some useful services ###ymlFileManager: service for loading ymlFile as array

namespace YourCorp\CoreBundle\Services\Manager;

use Dacorp\ExtraBundle\Services\YmlFileManager;

class YmlRankedListManager
{
    /**
     * @var YmlFileManager
     */
    private $ymlFileManager;


    public function __construct(YmlFileManager $ymlFileManager)
    {
        $this->ymlFileManager = $ymlFileManager;
    }
    # inject the serice "dacorp.manager.yml_file" in your service and use it like this
    public function loadYmlRankedList($fileName='default_ranked_list.yml')
    {
        $dataArray = $this->ymlFileManager->loadYmlFile($fileName);
        $dataArray = $this->ymlFileManager->loadYmlFile($fileName);
        foreach ($dataArray as $key => $data) {
            // do stuff with data
        }
    }
}

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.
dbravoan/dbcms-admin-theme-dbcms
dbravoan/dbcms-theme-db-cyber
dbravoan/dbcms-blocks-basic
dbravoan/dbcms-module-content-audit
dbravoan/dbcms-module-ai-assistant
paygate-to/paygate-php
padosoft/askmydocs-connector-base
defstudio/supercharged-carbon
bernskioldmedia/laravel-matomo
bernskioldmedia/laravel-harvest
bernskiold/laravel-data-scrubber
bernskiold/laravel-currency-converter
bernskiold/laravel-campaign-monitor
bernskioldmedia/laravel-autotranslate
siberfx/telegram-bot
roy-sandip/laravel-view-extended
gregsphotography/site-builder-core
roy-sandip/laravel-view
anodyne/blade-fluentui-icons
webx-ui/module-catalog-collections