ninegate/src/ninegate-1.0/src/Cadoles/PortalBundle/Resources/views/Pagewidget/viewseparator.html.twig

62 lines
2.2 KiB
Twig

{% set theme = app.session.get('theme') %}
{% if theme is not empty %}
{{ include('@Theme/'~theme~'/function.html.twig') }}
{% endif %}
{% import "@CadolesPortal/Pagewidget/constants.twig" as constants %}
{% set stylewidget = constants.mystylewidget(entity) %}
{% set stylewidgetmenu = constants.mystylewidgetmenu(entity) %}
{% set stylewidgetheader = constants.mystylewidgetheader(entity) %}
{% set stylewidgetbodyframe = constants.mystylewidgetbodyframe(entity) %}
{% set stylewidgetbodyimage = constants.mystylewidgetbodyimage(entity) %}
{% set color = app.session.get('color') %}
{% set colorbodyfont = entity.colorbodyfont %}
{% if colorbodyfont is null %}
{% set colorbodyfont = color['main'] %}
{% endif %}
<div class="widget {%if entity.border %} widget-bordered {%else%} widget-notbordered {%endif%} widget-separator" data-id="{{ entity.id }}" loc="{{ entity.loc }}" style="{{ stylewidget }}" height="{{ entity.height }}px">
{% if canupdate %}
<div class="widgetmenu">
<i class="fa fa-trash fa-fw" onClick="delWidget({{ entity.id }})" style="{{ stylewidgetmenu }}"></i>
<i class="fa fa-file fa-fw" onClick="modWidget({{ entity.id }})" style="{{ stylewidgetmenu }}"></i>
</div>
{% endif %}
<div class="widgetheader" style="{{ stylewidgetbodyimage }}">
{% if seeicon %}
{% if entity.icon %}
<img src="/{{ alias }}/{{ entity.icon.label }}" class="logo"/>
{% else %}
<img src="/{{ alias }}/uploads/icon/icon_pin.png" class="logo"/>
{% endif %}
{% endif %}
{% if seetitle %}
<span class="title">{{ entity.name }}</span>
{% else %}
<style>
div.separator {
width: 100%;
height: 5px;
margin-left: auto;
margin-right: auto;
background-color:#{{colorbodyfont}};
float:left;
position: relative;
top: 20px;
}
</style>
<div class="separator"></div>
{% endif %}
</div>
</div>
<script>
</script>