Portal: Added CSS classes to <body> tag regarding the current page / brick so we can apply CSS style more precisely.

SVN:trunk[4565]
This commit is contained in:
Guillaume Lajarige
2017-03-03 13:09:08 +00:00
parent 60165d5216
commit 69d0ceaf5b
6 changed files with 13 additions and 3 deletions

View File

@@ -2,6 +2,8 @@
{# Browse brick base layout #}
{% extends 'itop-portal-base/portal/src/views/bricks/layout.html.twig' %}
{% block pPageBodyClass %}{{ parent() }} page_browse_brick page_browse_brick_as_{{ sBrowseMode }}{% endblock %}
{% block pMainHeaderTitle %}
{{ oBrick.GetTitle()|dict_s }}
{% endblock %}

View File

@@ -11,6 +11,8 @@
{% endif %}
{% endblock %}
{% block pPageBodyClass %}{{ parent() }} page_brick_of_id_{{ oBrick.GetId() }}{% endblock %}
{% block pMainHeader %}
<div class="col-xs-12">
<div id="main-header-title">

View File

@@ -2,6 +2,8 @@
{# Manage brick base layout #}
{% extends 'itop-portal-base/portal/src/views/bricks/layout.html.twig' %}
{% block pPageBodyClass %}{{ parent() }} page_manage_brick{% endblock %}
{% block pMainHeaderTitle %}
{{ oBrick.GetTitle()|dict_s }}
{% endblock %}

View File

@@ -2,6 +2,8 @@
{# Object brick base layout #}
{% extends 'itop-portal-base/portal/src/views/bricks/layout.html.twig' %}
{% block pPageBodyClass %}{{ parent() }} page_object_brick page_object_brick_as_{{ sMode }}{% endblock %}
{% block pMainHeader %}
<div class="col-xs-12" id="main-header-title">
{% if form.title is defined %}

View File

@@ -1,11 +1,13 @@
{# itop-portal-base/portal/src/views/bricks/browse/layout.html.twig #}
{# Browse brick base layout #}
{# itop-portal-base/portal/src/views/bricks/user-profile/layout.html.twig #}
{# User profile brick base layout #}
{% extends 'itop-portal-base/portal/src/views/bricks/layout.html.twig' %}
{% set oContactForm = forms.contact %}
{% set oPreferencesForm = forms.preferences %}
{% set oPasswordForm = forms.password %}
{% block pPageBodyClass %}{{ parent() }} page_user-profile_brick{% endblock %}
{% block pMainHeaderTitle %}
{{ oBrick.GetTitle()|dict_s }}
{% endblock %}

View File

@@ -2,7 +2,7 @@
{# Home layout #}
{% extends app['combodo.portal.instance.conf'].properties.templates.layout %}
{% block pPageBodyClass %}home{% endblock %}
{% block pPageBodyClass %}page_home{% endblock %}
{# Showing only bricks that are not visible on the main content as well as a welcome message #}
{#{% block pNavigationSideMenu %}