-
-
Notifications
You must be signed in to change notification settings - Fork 117
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sonata\FormatterBundle\Controller\CkeditorAdminController" has no container set, did you forget to define it as a service subscriber? #669
Comments
After adding this to ckeditor.xml the above bug disappears:
You may check my fork here: |
Indeed, we should add the config similar to MediaBundle: Do you want to provide a PR @t-works ? We should also migrate the config to the php one. |
Sure, I can provide a PR. Sorry it was busy week. I will look into that
during weekend.
wt., 7 cze 2022, 10:25 użytkownik Vincent Langlet ***@***.***>
napisał:
… Indeed, we should add the config similar to MediaBundle:
https://github.com/sonata-project/SonataMediaBundle/blob/4.x/src/Resources/config/controllers.php#L24-L27
Do you want to provide a PR @t-works <https://github.com/t-works> ?
We should also migrate the config to the php one.
I added this TODO here sonata-project/dev-kit#1715
<sonata-project/dev-kit#1715> then we should
create a pre-release.
—
Reply to this email directly, view it on GitHub
<#669 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AJDRXYO4N4NDHGS536HUHMTVN4BQNANCNFSM5X3Y3HWA>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
I had to do some more work to make it functional. Especially in the twig templates. Some lines triggered syntax errors. Also some references to variables in admin object passed to template were incorrect. It appears template was written with phpcr admin in mind (used variables/function calls that exist in phpcr model admin manager but not in ModelManagerInterface and not in SonataDoctrineORMAdminBundle ModelManager) |
Now the bundle tests browser and upload routes, with functional tests using doctrine orm admin bundle, from 4.4 up to 6.1 versions of Symfony. Can you check the 5.x-dev (without your PR) on your project to see if everything works? |
Anyway this error should not be reported anymore, let's close this issue and focus on the next problems (if there are any) |
Environment
Sonata packages
show
Symfony packages
show
PHP version
Subject
Clicking on the Browse Server in FCK editor causer error
Minimal repository with the bug
https://github.com/t-works/sonataFCKeditor_formatter_bug
Steps to reproduce
Expected results
Have the FCK upload/browse server
Actual results
"Sonata\FormatterBundle\Controller\CkeditorAdminController" has no container set, did you forget to define it as a service subscriber?
ExceptionStack Trace
LogicException
in [project path]vendor\symfony\framework-bundle\Controller\ControllerResolver.php (line 36)
ControllerResolver->instantiateController('Sonata\FormatterBundle\Controller\CkeditorAdminController')
in [project path]vendor\symfony\http-kernel\Controller\ControllerResolver.php (line 109)
ControllerResolver->createController('Sonata\FormatterBundle\Controller\CkeditorAdminController::browserAction')
in [project path]vendor\symfony\http-kernel\Controller\ControllerResolver.php (line 77)
ControllerResolver->getController(object(Request))
in [project path]vendor\symfony\http-kernel\Controller\TraceableControllerResolver.php (line 38)
TraceableControllerResolver->getController(object(Request))
in [project path]vendor\symfony\http-kernel\HttpKernel.php (line 135)
HttpKernel->handleRaw(object(Request), 1)
in [project path]vendor\symfony\http-kernel\HttpKernel.php (line 74)
HttpKernel->handle(object(Request), 1, true)
in [project path]vendor\symfony\http-kernel\Kernel.php (line 202)
Kernel->handle(object(Request))
in [project path]vendor\symfony\runtime\Runner\Symfony\HttpKernelRunner.php (line 35)
HttpKernelRunner->run()
in [project path]vendor\autoload_runtime.php (line 29)
require_once('C:\var\projects\stronaklubu2\vendor\autoload_runtime.php')
in [project path]public\index.php (line 5)
Notes
check in symfony/framework-bundle/Controller/ControllerResolver.php fails because the container is not set in Sonata\FormatterBundle\Controller\CkeditorAdminController
CkeditorAdminController does not implement ContainerAwareInterface
Container is not injected in any other way during the initialization
I didn't find any information in the sonata formatter docs describing a way or a need to inject container manually
The text was updated successfully, but these errors were encountered: