Commit 3e0fec0c authored by Niklas de Vries's avatar Niklas de Vries

removed assetic dependency

parent 52777940
......@@ -12,10 +12,9 @@ namespace Cwd\FroalaBundle\Controller;
use Cwd\MediaBundle\Service\MediaService;
use Sensio\Bundle\FrameworkExtraBundle\Configuration\ParamConverter;
use Sensio\Bundle\FrameworkExtraBundle\Configuration\Route;
use JMS\SecurityExtraBundle\Annotation\PreAuthorize;
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\HttpFoundation\Request;
use Cwd\GenericBundle\Controller\GenericController as CwdController;
/**
* Class ImageController
......@@ -23,10 +22,9 @@ use Cwd\GenericBundle\Controller\GenericController as CwdController;
* @package Cwd\FroalaBundle\Controller
* @author Ludwig Ruderstaller <lr@cwd.at>
*
* @PreAuthorize("hasRole('ROLE_ADMIN')")
* @Route("/image")
*/
class ImageController extends CwdController
class ImageController extends Controller
{
/**
* @Route("/upload")
......
{% stylesheets
'bundles/cwdfroala/vendor/froala/css/froala_editor.pkgd.min.css'
'bundles/cwdfroala/vendor/froala/css/froala_style.min.css'
'bundles/cwdfroala/vendor/codemirror/lib/codemirror.css'
'bundles/cwdfroala/cwd_froala.css'
filter='cssrewrite'
%}
<link rel="stylesheet" href="{{ asset_url }}" />
{% endstylesheets %}
<link rel="stylesheet" href="{{ asset('bundles/cwdfroala/vendor/froala/css/froala_editor.pkgd.min.css') }}" />
<link rel="stylesheet" href="{{ asset('bundles/cwdfroala/vendor/froala/css/froala_style.min.css') }}" />
<link rel="stylesheet" href="{{ asset('bundles/cwdfroala/vendor/codemirror/lib/codemirror.css') }}" />
<link rel="stylesheet" href="{{ asset('bundles/cwdfroala/cwd_froala.css') }}" />
{% javascripts
'bundles/cwdfroala/vendor/froala/js/froala_editor.pkgd.min.js'
'bundles/cwdfroala/vendor/froala/js/languages/de.js'
'bundles/cwdfroala/vendor/codemirror/lib/codemirror.js'
'bundles/cwdfroala/vendor/codemirror/mode/xml/xml.js'
'bundles/cwdfroala/cwd_froala.js'
%}
<script type="text/javascript" src="{{ asset_url }}"></script>
{% endjavascripts %}
<script src="{{ asset('bundles/cwdfroala/vendor/froala/js/froala_editor.pkgd.min.js') }}"></script>
<script src="{{ asset('bundles/cwdfroala/vendor/froala/js/languages/de.js') }}"></script>
<script src="{{ asset('bundles/cwdfroala/vendor/codemirror/lib/codemirror.js') }}"></script>
<script src="{{ asset('bundles/cwdfroala/vendor/codemirror/mode/xml/xml.js') }}"></script>
<script src="{{ asset('bundles/cwdfroala/cwd_froala.js') }}"></script>
<script type="text/javascript">
var cwdFroalaConfig = {{ config|json_encode|raw }};
cwdFroalaConfig.imageUploadURL = '{{ path(config.imageUploadURL) }}'
cwdFroalaConfig.imageManagerLoadURL = '{{ path(config.imageManagerLoadURL) }}'
CwdFroala.init(cwdFroalaConfig);
var cwdFroalaConfig = {{ config|json_encode|raw }};
cwdFroalaConfig.imageUploadURL = '{{ path(config.imageUploadURL) }}'
cwdFroalaConfig.imageManagerLoadURL = '{{ path(config.imageManagerLoadURL) }}'
CwdFroala.init(cwdFroalaConfig);
</script>
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