polidog / query-locator-bundle
1.0.2
2018-09-06 15:47 UTC
Requires
- php: >=5.6
- koriym/query-locator: ^1.3
- symfony/config: ^2.7|^3.0|^4.0
- symfony/dependency-injection: ^2.7|^3.0|^4.0
- symfony/http-kernel: ^2.7|^3.0|^4.0
Requires (Dev)
- friendsofphp/php-cs-fixer: ^2.2
- phpunit/phpunit: ^5.7
This package is auto-updated.
Last update: 2024-11-21 20:25:31 UTC
README
QueryLocatoer for Symfony Bundle.
using Koriym.QueryLocator.
Installation
Composer install
$ composer require polidog/query-locator-bundle
Usage
app/config.yml
polidog_query_locator: locators: user_queries: sql_dir: "../../sqldir" use_apc: false # Default to false.
Get Container
$query = $container->get('polidog_query_locator.locators.user_queries') // QueryLocator $sql = $query['admin/user']; $sql = $query->getCountQuery('admin/user');
SQL files
└── sql
└── admin
└── user.sql
Requirements
- PHP 5.6+