Code Monkey home page Code Monkey logo

shtumiusefulbundle's Introduction

ShtumiUsefulBundle - make typical things easier

ShtumiUsefulBundle provides some useful things that needed almost in every project. It's:

Form types:

DQL extra functions:

  • IF

  • IFNULL

  • ROUND

  • DATE_DIFF

You can use Ajax autocomplete form type as a filter type with SonataAdminBundle

Installation

Add the following lines to your deps file and then run php bin/vendors install:

[ShtumiUsefulBundle]
    git=https://github.com/shtumi/ShtumiUsefulBundle.git
    target=bundles/Shtumi/UsefulBundle

For Symfony 2.0 please use branch 2.0 of ShtumiUsefulBundle:

[ShtumiUsefulBundle]
    git=https://github.com/shtumi/ShtumiUsefulBundle.git
    target=bundles/Shtumi/UsefulBundle
    version=origin/2.0

You also should install SonataAdminBundle and all dependencies for it.

Add ShtumiUsefulBundle to your application kernel

    // app/AppKernel.php
    public function registerBundles()
    {
        return array(
            // ...
            new Shtumi\UsefulBundle\ShtumiUsefulBundle(),
            // ...
        );
    }

Register the ShtumiUsefulBundle namespace

    // app/autoload.php
    $loader->registerNamespaces(array(
        'Shtumi'            => __DIR__.'/../vendor/bundles',
        // your other namespaces
    ));

Import routes

// app/config/routing.yml

shtumi_useful:
    resource: '@ShtumiUsefulBundle/Resources/config/routing.xml'

Update your configuration

Add form theming to twig

twig:
    ...
    form:
        resources:
            - ShtumiUsefulBundle::fields.html.twig

Update your configuration in accordance with using ShtumiUsefulBundle things

Load jQuery to your views

    <script src="http://code.jquery.com/jquery-1.7.2.min.js" type="text/javascript"></script>

shtumiusefulbundle's People

Contributors

shtumi avatar valqk avatar ribeiropaulor avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.