-
Notifications
You must be signed in to change notification settings - Fork 29
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
IBX-1543: Replaced deprecated twig functions (#29)
* IBX-1543: Replaced ez_content_name function * IBX-1543: Added deprecation for ez_render function * IBX-1543: Added deprecation for ez_render_*_query function * IBX-1543: Replaced & deprecate ez_render_field function * IBX-1543: Replaced ez_field_value function * IBX-1543: Replaced ez_field function * IBX-1543: Depreceted ez_field_name function * IBX-1543: Depreceted ez_field_description function * IBX-1543: Replaced ez_field_is_empty function * IBX-1543: Replaced image related twig funtions * IBX-1543: Replaced URL twig functions * IBX-1543: Replaced rest of core extensions and filters function * IBX-1543: Dropped removed `getName` function implementation * IBX-1543: Replaced global `ezplatform` variable * IBX-1543: Fixed code style * IBX-1543: Added deprecation messeges to unit tests
- Loading branch information
Showing
46 changed files
with
1,118 additions
and
116 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
src/bundle/Core/Resources/views/default/content/asset_image.html.twig
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 3 additions & 3 deletions
6
src/bundle/Core/Resources/views/default/content/embed.html.twig
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,11 @@ | ||
{% set content_name=ez_content_name(content) %} | ||
{% set content_name=ibexa_content_name(content) %} | ||
|
||
{% if objectParameters.doNotGenerateEmbedUrl is defined and objectParameters.doNotGenerateEmbedUrl %} | ||
<h3>{{ content.name }}</h3> | ||
{% else %} | ||
{% if location is defined %} | ||
<h3><a href="{{ ez_path(location) }}">{{ content_name }}</a></h3> | ||
<h3><a href="{{ ibexa_path(location) }}">{{ content_name }}</a></h3> | ||
{% else %} | ||
<h3><a href="{{ ez_path(content) }}">{{ content_name }}</a></h3> | ||
<h3><a href="{{ ibexa_path(content) }}">{{ content_name }}</a></h3> | ||
{% endif %} | ||
{% endif %} |
4 changes: 2 additions & 2 deletions
4
src/bundle/Core/Resources/views/default/content/embed_image.html.twig
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 3 additions & 3 deletions
6
src/bundle/Core/Resources/views/default/content/embed_inline.html.twig
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,15 @@ | ||
{% | ||
set data_attributes_str = (data_attributes is defined) | ||
? ' ' ~ data_attributes|ez_data_attributes_serialize | ||
? ' ' ~ data_attributes|ibexa_data_attributes_serialize | ||
: '' | ||
%} | ||
|
||
{% if objectParameters.doNotGenerateEmbedUrl is defined and objectParameters.doNotGenerateEmbedUrl %} | ||
<span {% if class is defined %} class="{{ class }}"{% endif %}{{ data_attributes_str|raw }}>{{ content.name }}</span> | ||
{% else %} | ||
{% if location is defined %} | ||
<a href="{{ ez_path(location) }}"{% if class is defined %} class="{{ class }}"{% endif %}{{ data_attributes_str|raw }}>{{ content.name }}</a> | ||
<a href="{{ ibexa_path(location) }}"{% if class is defined %} class="{{ class }}"{% endif %}{{ data_attributes_str|raw }}>{{ content.name }}</a> | ||
{% else %} | ||
<a href="{{ ez_path(content) }}"{% if class is defined %} class="{{ class }}"{% endif %}{{ data_attributes_str|raw }}>{{ content.name }}</a> | ||
<a href="{{ ibexa_path(content) }}"{% if class is defined %} class="{{ class }}"{% endif %}{{ data_attributes_str|raw }}>{{ content.name }}</a> | ||
{% endif %} | ||
{% endif %} |
4 changes: 2 additions & 2 deletions
4
src/bundle/Core/Resources/views/default/content/full.html.twig
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
{% extends no_layout == true ? view_base_layout : page_layout %} | ||
{% block content %} | ||
<h2>{{ ez_content_name(content) }}</h2> | ||
<h2>{{ ibexa_content_name(content) }}</h2> | ||
{% for field in content.fieldsByLanguage(language|default(null)) %} | ||
<h3>{{ field.fieldDefIdentifier }}</h3> | ||
{{ ez_render_field(content, field.fieldDefIdentifier, {location: location|default(null)}) }} | ||
{{ ibexa_render_field(content, field.fieldDefIdentifier, {location: location|default(null)}) }} | ||
{% endfor %} | ||
{% endblock %} |
4 changes: 2 additions & 2 deletions
4
src/bundle/Core/Resources/views/default/content/line.html.twig
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
{% set content_name=ez_content_name(content) %} | ||
{% set content_name=ibexa_content_name(content) %} | ||
|
||
{% if location is defined %} | ||
<p><a href="{{ ez_path(location) }}">{{ content_name }}</a></p> | ||
<p><a href="{{ ibexa_path(location) }}">{{ content_name }}</a></p> | ||
{% else %} | ||
<p>{{ content_name }}</p> | ||
{% endif %} |
4 changes: 2 additions & 2 deletions
4
src/bundle/Core/Resources/views/default/content/text_linked.html.twig
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
{% set content_name=ez_content_name(content) %} | ||
{% set content_name=ibexa_content_name(content) %} | ||
|
||
{% if location is defined %} | ||
<a href="{{ ez_path(location) }}">{{ content_name }}</a> | ||
<a href="{{ ibexa_path(location) }}">{{ content_name }}</a> | ||
{% else %} | ||
<p>{{ content_name }}</p> | ||
{% endif %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.