Commit 7454e6d6 authored by Nicolas Widart's avatar Nicolas Widart

Update to conform to the new pingpong/Modules package

parent 28790d59
<?php namespace Modules\Media\Image;
use Illuminate\Contracts\Config\Repository;
use Pingpong\Modules\Repository as Module;
class ThumbnailsManager
{
......@@ -16,11 +15,10 @@ class ThumbnailsManager
/**
* @param Repository $config
* @param Module $module
*/
public function __construct(Repository $config, Module $module)
public function __construct(Repository $config)
{
$this->module = $module;
$this->module = app('modules');
$this->config = $config;
}
......@@ -32,7 +30,7 @@ class ThumbnailsManager
{
$thumbnails = [];
foreach ($this->module->enabled() as $enabledModule) {
$configuration = $this->config->get(strtolower($enabledModule) . '::thumbnails');
$configuration = $this->config->get(strtolower($enabledModule->getName()) . '::thumbnails');
$thumbnails = array_merge($thumbnails, $configuration);
}
......
......@@ -3,8 +3,8 @@
<head>
<meta charset="UTF-8">
<title>{{ trans('media::media.file picker') }}</title>
<link href="{!! Module::asset('core', 'css/vendor/bootstrap.min.css') !!}" rel="stylesheet" type="text/css" />
<script src="{!! Module::asset('core', 'js/vendor/jquery.min.js') !!}"></script>
<link href="{!! Module::asset('core:css/vendor/bootstrap.min.css') !!}" rel="stylesheet" type="text/css" />
<script src="{!! Module::asset('core:js/vendor/jquery.min.js') !!}"></script>
<style>
</style>
</head>
......
......@@ -11,7 +11,7 @@
@stop
@section('styles')
<link href="{!! Module::asset('media', 'css/dropzone.css') !!}" rel="stylesheet" type="text/css" />
<link href="{!! Module::asset('media:css/dropzone.css') !!}" rel="stylesheet" type="text/css" />
<style>
.dropzone {
border: 1px dashed #CCC;
......@@ -109,7 +109,7 @@
@stop
@section('scripts')
<script src="{!! Module::asset('media', 'js/dropzone.js') !!}"></script>
<script src="{!! Module::asset('media:js/dropzone.js') !!}"></script>
<script>
$( document ).ready(function() {
Dropzone.autoDiscover = false;
......@@ -147,7 +147,7 @@ $( document ).ready(function() {
"bInfo": true,
"bAutoWidth": true,
"oLanguage": {
"sUrl": '<?php echo Module::asset('core', "js/vendor/datatables/{$locale}.json") ?>'
"sUrl": '<?php echo Module::asset("core:js/vendor/datatables/{$locale}.json") ?>'
},
"aoColumns": [
null,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment