Skip to content

Commit bd703e1

Browse files
adriendupuismnocon
andauthored
Fix ibexa_content::viewAction (#2873)
* Use ibexa_content::viewAction w/ two colons `Controller "ibexa_content:viewAction" does neither exist as service nor as class.` See https://doc.ibexa.co/en/5.0/release_notes/ibexa_dxp_v5.0_deprecations/#ibexacore "Dropped single colon notation" --------- Co-authored-by: Marek Nocoń <[email protected]>
1 parent 0d6b96a commit bd703e1

File tree

3 files changed

+26
-26
lines changed

3 files changed

+26
-26
lines changed

code_samples/front/render_content_in_php/src/Command/ViewCommand.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ protected function execute(InputInterface $input, OutputInterface $output): int
4747

4848
$viewParameters = [
4949
'viewType' => $input->getOption('view-type'),
50-
'_controller' => 'ibexa_content:viewAction',
50+
'_controller' => 'ibexa_content::viewAction',
5151
];
5252

5353
if (!empty($locationId)) {
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
<div class="row">
22
<div class="block-form {{ block_class }}">
33
{{ ibexa_http_cache_tag_relation_location_ids(locationId) }}
4-
{{ render(controller('ibexa_content:viewAction', {
4+
{{ render(controller('ibexa_content::viewAction', {
55
'contentId': contentId,
66
'locationId': locationId,
77
'viewType': 'embed'
88
})) }}
99
<style type="text/css">{{ block_style|raw }}</style>
1010
</div>
11-
</div>
11+
</div>

docs/infrastructure_and_maintenance/request_lifecycle.md

Lines changed: 23 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ If a wildcard matches, the request's `semanticPathinfo` is updated and the route
110110

111111
`UrlAliasRouter` (`Ibexa\Bundle\Core\Routing\UrlAliasRouter`):
112112
This router uses the `UrlAliasService` to associate the `semanticPathinfo` to a location.
113-
If it finds a location, the request receives the attributes **`locationId`** and **`contentId`**, **`viewType`** is set to `full`, and the **`_controller`** is set to `ibexa_content:viewAction` for now.
113+
If it finds a location, the request receives the attributes **`locationId`** and **`contentId`**, **`viewType`** is set to `full`, and the **`_controller`** is set to `ibexa_content::viewAction` for now.
114114

115115
The `locale_listener` (priority 16) sets the request's **`_locale`** attribute.
116116

@@ -160,7 +160,7 @@ The `HttpKernel` executes the controller with those arguments.
160160
As a reminder, the controller and its argument can be:
161161

162162
- A controller set by the matched route and the request as its argument.
163-
- The default `ibexa_content:viewAction` controller and a `ContentView` as its argument.
163+
- The default `ibexa_content::viewAction` controller and a `ContentView` as its argument.
164164
- A [custom controller](controllers.md) set by the matched view rule and a `View` or the request as its argument (most likely a `ContentView` but there is no restriction).
165165

166166
!!! caution "Permission control"
@@ -209,27 +209,27 @@ The `HttpKernel` retrieves the response attached to the event and continues.
209209

210210
### Examples request attributes timeline
211211

212-
| Event | Service | Request attribute | Example |
213-
|-----------------------------------|--------------------------------------------------------|--------------------------|-------------------------------------------|
214-
| | http_kernel | pathInfo | /en/about |
215-
| kernel.request | ibexa.siteaccess_match_listener | siteaccess | en |
216-
| Ibexa\Core\MVC\Symfony\SiteAccess | Ibexa\Bundle\Core\EventListener\SiteAccessListener | semanticPathinfo | /about |
217-
| kernel.request | router.default | _route | N/A |
218-
| kernel.request | router.default | _controller | N/A |
219-
| kernel.request | Ibexa\Bundle\Core\Routing\UrlAliasRouter | _route | ibexa.url.alias |
220-
| kernel.request | Ibexa\Bundle\Core\Routing\UrlAliasRouter | _controller | <strong>ibexa_content:</strong>viewAction |
221-
| kernel.request | Ibexa\Bundle\Core\Routing\UrlAliasRouter | viewType | full |
222-
| kernel.request | Ibexa\Bundle\Core\Routing\UrlAliasRouter | contentId | 1 |
223-
| kernel.request | Ibexa\Bundle\Core\Routing\UrlAliasRouter | locationId | 42 |
224-
| kernel.request | locale_listener | _locale | en_GB |
225-
| kernel.controller | Ibexa\Core\MVC\Symfony\View\Builder\ContentViewBuilder | view.content | Content |
226-
| kernel.controller | Ibexa\Core\MVC\Symfony\View\Builder\ContentViewBuilder | view.location | Location |
227-
| kernel.controller | Ibexa\Core\MVC\Symfony\View\Configurator\ViewProvider | view.templateIdentifier | @IbexaCore/default/content/full.html.twig |
228-
| kernel.controller | Ibexa\Core\MVC\Symfony\View\Configurator\ViewProvider | view.controllerReference | null |
229-
| kernel.controller | Ibexa\Bundle\Core\EventListener\ViewControllerListener | view | ContentView |
230-
| kernel.controller | Ibexa\Bundle\Core\EventListener\ViewControllerListener | _controller | ibexa_content:viewAction |
231-
| (controller execution) | http_kernel | | ContentView |
232-
| kernel.view | Ibexa\Bundle\Core\EventListener\ViewRendererListener | response | Response |
212+
| Event | Service | Request attribute | Example |
213+
|-----------------------------------|--------------------------------------------------------|--------------------------|--------------------------------------------|
214+
| | http_kernel | pathInfo | /en/about |
215+
| kernel.request | ibexa.siteaccess_match_listener | siteaccess | en |
216+
| Ibexa\Core\MVC\Symfony\SiteAccess | Ibexa\Bundle\Core\EventListener\SiteAccessListener | semanticPathinfo | /about |
217+
| kernel.request | router.default | _route | N/A |
218+
| kernel.request | router.default | _controller | N/A |
219+
| kernel.request | Ibexa\Bundle\Core\Routing\UrlAliasRouter | _route | ibexa.url.alias |
220+
| kernel.request | Ibexa\Bundle\Core\Routing\UrlAliasRouter | _controller | <strong>ibexa_content::</strong>viewAction |
221+
| kernel.request | Ibexa\Bundle\Core\Routing\UrlAliasRouter | viewType | full |
222+
| kernel.request | Ibexa\Bundle\Core\Routing\UrlAliasRouter | contentId | 1 |
223+
| kernel.request | Ibexa\Bundle\Core\Routing\UrlAliasRouter | locationId | 42 |
224+
| kernel.request | locale_listener | _locale | en_GB |
225+
| kernel.controller | Ibexa\Core\MVC\Symfony\View\Builder\ContentViewBuilder | view.content | Content |
226+
| kernel.controller | Ibexa\Core\MVC\Symfony\View\Builder\ContentViewBuilder | view.location | Location |
227+
| kernel.controller | Ibexa\Core\MVC\Symfony\View\Configurator\ViewProvider | view.templateIdentifier | @IbexaCore/default/content/full.html.twig |
228+
| kernel.controller | Ibexa\Core\MVC\Symfony\View\Configurator\ViewProvider | view.controllerReference | null |
229+
| kernel.controller | Ibexa\Bundle\Core\EventListener\ViewControllerListener | view | ContentView |
230+
| kernel.controller | Ibexa\Bundle\Core\EventListener\ViewControllerListener | _controller | ibexa_content::viewAction |
231+
| (controller execution) | http_kernel | | ContentView |
232+
| kernel.view | Ibexa\Bundle\Core\EventListener\ViewRendererListener | response | Response |
233233

234234

235235
## End of HTTP response

0 commit comments

Comments
 (0)