bundles/Donatos/AdminBundle/DonatosAdminBundle.php line 26

Open in your IDE?
  1. <?php
  2. /**
  3.  * Pimcore
  4.  *
  5.  * This source file is available under two different licenses:
  6.  * - GNU General Public License version 3 (GPLv3)
  7.  * - Pimcore Commercial License (PCL)
  8.  * Full copyright and license information is available in
  9.  * LICENSE.md which is distributed with this source code.
  10.  *
  11.  *  @copyright  Copyright (c) Pimcore GmbH (http://www.pimcore.org)
  12.  *  @license    http://www.pimcore.org/license     GPLv3 and PCL
  13.  */
  14. namespace Donatos\AdminBundle;
  15. use Pimcore\Extension\Bundle\AbstractPimcoreBundle;
  16. use Pimcore\Extension\Bundle\Traits\StateHelperTrait;
  17. use Pimcore\Version;
  18. use Symfony\Component\DependencyInjection\ContainerBuilder;
  19. /**
  20.  * @internal
  21.  */
  22. class DonatosAdminBundle extends AbstractPimcoreBundle
  23. {
  24.     use StateHelperTrait;
  25.     /**
  26.      * {@inheritdoc}
  27.      */
  28.     public function getVersion()
  29.     {
  30.         return sprintf('%s build %s'Version::getVersion(), Version::getRevision());
  31.     }
  32.     /**
  33.      * {@inheritdoc}
  34.      */
  35.     public function build(ContainerBuilder $container)
  36.     {
  37.     }
  38.     /**
  39.      * Get path to include in admin iframe
  40.      *
  41.      * @return string|RouteReferenceInterface|null
  42.      */
  43.     public function getAdminIframePath() {
  44.         return '/admin/donatosadmin/bundle'.str_replace(__NAMESPACE__''__CLASS__);
  45.     }
  46.     /**
  47.      * @return array
  48.      */
  49.     public function getCssPaths()
  50.     {
  51.         return [
  52.             '/bundles/donatosadmin/css/backend.css',
  53.         ];
  54.     }
  55.     /**
  56.      * @return array
  57.      */
  58.     public function getJsPaths()
  59.     {
  60.         return [
  61.             '/bundles/donatosadmin/js/bundle.js',
  62.             '/admin/donatosadmin/config/js-config',
  63.             '/bundles/donatosadmin/js/donatos_frame.js'
  64.         ];
  65.     }
  66.     public function boot()
  67.     {
  68.         $container $this->container;
  69.     }
  70.     public function getEditmodeJsPaths()
  71.     {
  72.         return [
  73.             '/bundles/donatosadmin/js/pimcore/editmode.js'
  74.         ];
  75.     }
  76. }