local-packages/sideagroup/pimcore-assortment-calculator/SideagroupAssortmentCalculatorBundle.php line 9

Open in your IDE?
  1. <?php
  2. namespace Sideagroup\AssortmentCalculatorBundle;
  3. use Pimcore\Extension\Bundle\AbstractPimcoreBundle;
  4. use Pimcore\Extension\Bundle\Traits\PackageVersionTrait;
  5. use Sideagroup\AssortmentCalculatorBundle\Tools\Installer;
  6. class SideagroupAssortmentCalculatorBundle extends AbstractPimcoreBundle 
  7. {
  8.     use PackageVersionTrait {
  9.         getVersion as protected getComposerVersion;
  10.     }
  11.     /**
  12.      * @return string[]
  13.      */
  14.     public function getJsPaths()
  15.     {
  16.         return [
  17.             '/bundles/sideagroupassortmentcalculator/js/startup.js',
  18.             '/bundles/sideagroupassortmentcalculator/js/config/panel.js'
  19.         ];
  20.     }
  21.     /**
  22.      * @return string[]
  23.      */
  24.     public function getCssPaths()
  25.     {
  26.         return [
  27.             '/bundles/sideagroupassortmentcalculator/css/admin.css'
  28.         ];
  29.     }
  30.     /**
  31.      * Returns the composer package name used to resolve the version
  32.      */
  33.     protected function getComposerPackageName(): string
  34.     {
  35.         return 'sideagroup/pimcore-assortment-calculator';
  36.     }
  37.     /**
  38.      * @return string
  39.      */
  40.     public function getVersion()
  41.     {
  42.         try {
  43.             return $this->getComposerVersion();
  44.         } catch (\Exception $e) {
  45.             return 'unknown';
  46.         }
  47.     }
  48.     /**
  49.      * @return Installer
  50.      */
  51.     public function getInstaller()
  52.     {
  53.         return new Installer();
  54.     }
  55.     /**
  56.      * @return string
  57.      */
  58.     public function getNiceName()
  59.     {
  60.         return 'Sideagroup Assortment Calculator';
  61.     }
  62.     /**
  63.      * @return string
  64.      */
  65.     public function getDescription()
  66.     {
  67.         return 'Bundle per il calcolo automatico degli assortimenti nei Data Object di Pimcore';
  68.     }
  69. }