installation.rst 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. Installation
  2. ============
  3. First install the Sonata Admin Bundle which provides Core functionalities. The ``EntityAudit`` is an optional
  4. history feature (https://github.com/simplethings/EntityAudit).
  5. Download bundles
  6. ----------------
  7. Add the following lines to the file ``deps``::
  8. [SonataDoctrineORMAdminBundle]
  9. git=http://github.com/sonata-project/SonataDoctrineORMAdminBundle.git
  10. target=/bundles/Sonata/DoctrineORMAdminBundle
  11. # optional bundle
  12. [EntityAudit]
  13. git=git://github.com/simplethings/EntityAudit.git
  14. target=/bundles/SimpleThings/EntityAudit
  15. and run::
  16. bin/vendors install
  17. Configuration
  18. -------------
  19. Next, be sure to enable the bundles in your autoload.php and AppKernel.php
  20. files:
  21. .. code-block:: php
  22. <?php
  23. // app/AppKernel.php
  24. public function registerBundles()
  25. {
  26. return array(
  27. // ...
  28. new Sonata\DoctrineORMAdminBundle\SonataDoctrineORMAdminBundle(),
  29. new SimpleThings\EntityAudit\SimpleThingsEntityAuditBundle(),
  30. // ...
  31. );
  32. }
  33. // autoload.php
  34. $loader->registerNamespaces(array(
  35. // ...
  36. 'simplethings' => __dir__.'/../vendor/bundles',
  37. // ...
  38. ));