macfja/tracy-doctrine-sql

A Tracy panel for Doctrine SQL queries

Installs: 18 102

Dependents: 3

Suggesters: 0

Security: 0

Stars: 2

Watchers: 3

Forks: 1

Open Issues: 0

Language:HTML

dev-master 2016-02-01 17:34 UTC

This package is auto-updated.

Last update: 2024-11-17 01:01:51 UTC


README

Add Sql requests made by Doctrine in the Tracy debugger bar.

Installation

Composer

composer require macfja/tracy-doctrine-sql

Usage

Somewhere, when your application start and you initialize Doctrine

use MacFJA\Tracy\DoctrineSql;
use Doctrine\ORM\EntityManager;

// ...

$entityManager = EntityManager::create($conn, $config);
DoctrineSql::init($entityManager);

Multiple Manager support

use MacFJA\Tracy\DoctrineSql;
use Doctrine\ORM\EntityManager;

// ...

$blogManager = EntityManager::create($conn1, $config2);
$configManager = EntityManager::create($conn2, $config2);
DoctrineSql::init($blogManager, 'Blog');
DoctrineSql::init($configManager, 'Config');

Similar projects