Adding select2 and FOSJsRoutingBundle

1.10.x
Julio Montoya 10 years ago
parent 847753d5c2
commit 16b3031ad4
  1. 2
      app/AppKernel.php
  2. 25
      app/SymfonyRequirements.php
  3. 2
      app/config/assetic.yml
  4. 3
      app/config/routing.yml
  5. 6
      composer.json
  6. 2
      src/Chamilo/AdminThemeBundle/Resources/views/Layout/base-layout.html.twig

@ -158,6 +158,8 @@ class AppKernel extends Kernel
new Oro\Bundle\MigrationBundle\OroMigrationBundle(),
new Thrace\DataGridBundle\ThraceDataGridBundle(),
new FOS\JsRoutingBundle\FOSJsRoutingBundle(),
//new Vich\UploaderBundle\VichUploaderBundle(),
);

@ -403,7 +403,7 @@ class SymfonyRequirements extends RequirementCollection
);
$this->addRequirement(
is_dir($this->getComposerVendorDir()),
is_dir(__DIR__.'/../vendor/composer'),
'Vendor libraries must be installed',
'Vendor libraries are missing. Install composer following instructions from <a href="http://getcomposer.org/">http://getcomposer.org/</a>. '.
'Then run "<strong>php composer.phar install</strong>" to install them.'
@ -543,7 +543,7 @@ class SymfonyRequirements extends RequirementCollection
/* optional recommendations follow */
$this->addRecommendation(
file_get_contents(__FILE__) === file_get_contents($this->getComposerVendorDir().'/sensio/distribution-bundle/Sensio/Bundle/DistributionBundle/Resources/skeleton/app/SymfonyRequirements.php'),
file_get_contents(__FILE__) === file_get_contents(__DIR__.'/../vendor/sensio/distribution-bundle/Sensio/Bundle/DistributionBundle/Resources/skeleton/app/SymfonyRequirements.php'),
'Requirements file should be up-to-date',
'Your requirements file is outdated. Run composer install and re-check your configuration.'
);
@ -590,8 +590,8 @@ class SymfonyRequirements extends RequirementCollection
$this->addRecommendation(
class_exists('DomDocument'),
'PHP-XML module should be installed',
'Install and enable the <strong>PHP-XML</strong> module.'
'PHP-DOM and PHP-XML modules should be installed',
'Install and enable the <strong>PHP-DOM</strong> and the <strong>PHP-XML</strong> modules.'
);
$this->addRecommendation(
@ -736,21 +736,4 @@ class SymfonyRequirements extends RequirementCollection
return (int) $size;
}
}
/**
* In some special setups, the vendor/ directory isn't located in the project's
* root directory. To make this command work for every case, read Composer's
* vendor/ directory location directly from composer.json file.
*
* @return string
*/
private function getComposerVendorDir()
{
$composerJson = json_decode(file_get_contents(__DIR__.'/../composer.json'));
if (isset($composerJson->config)) {
return $composerJson->config->{'vendor-dir'};
}
return __DIR__.'/../vendor/composer';
}
}

@ -56,8 +56,8 @@ assetic:
chamilo_js:
inputs:
- @ChamiloAdminThemeBundle/Resources/public/components/jquery/dist/jquery.js
- @bootstrap_js
- @ChamiloAdminThemeBundle/Resources/public/components/jquery-ui/jquery-ui.min.js
- @bootstrap_js
- @ChamiloAdminThemeBundle/Resources/public/components/chosen-bower/chosen.jquery.js
- @moment_js
- @ChamiloAdminThemeBundle/Resources/public/components/fullcalendar/dist/fullcalendar.min.js

@ -66,6 +66,9 @@ thrace_data_grid:
resource: "@ThraceDataGridBundle/Resources/config/routing.xml"
prefix: /
fos_js_routing:
resource: "@FOSJsRoutingBundle/Resources/config/routing/routing.xml"
# Always at the end
core_bundle:
resource: "@ChamiloCoreBundle/Resources/config/routing.yml"

@ -153,7 +153,8 @@
"patchwork/utf8": "dev-master",
"vich/uploader-bundle": "~0.11",
"tilleuls/ckeditor-sonata-media-bundle": "dev-master",
"egeloen/ckeditor-bundle": "~2.0"
"egeloen/ckeditor-bundle": "~2.0",
"friendsofsymfony/jsrouting-bundle": "~1.5"
},
"require-dev": {
"akeneo/crowdin-api": "1.0.*@dev",
@ -189,7 +190,8 @@
]
},
"config": {
"bin-dir": "bin"
"bin-dir": "bin",
"vendor-dir": "vendor"
},
"extra": {
"symfony-app-dir": "app",

@ -38,6 +38,8 @@
{% endjavascripts %}
<script src="{{ asset('bundles/ivoryckeditor/ckeditor.js') }}" type="text/javascript"></script>
<script src="{{ asset('bundles/fosjsrouting/js/router.js') }}"></script>
<script src="{{ path('fos_js_routing_js', {"callback": "fos.Router.setData"}) }}"></script>
</head>
<body class="{{ admin_skin|default('skin-blue')}}">
{% block chamilo_admin_header %}

Loading…
Cancel
Save