mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-24 02:13:15 +00:00
Fix minor issues
This commit is contained in:
@@ -115,3 +115,21 @@
|
||||
{% include 'common/technical_datas.html.twig' %}
|
||||
{% endif %}
|
||||
{% endmacro %}
|
||||
|
||||
{% macro caption(record, business, technical) %}
|
||||
{# @todo handle business fields #}
|
||||
{% for name, value in record.caption %}
|
||||
<div class="desc {{ loop.index is odd ? 'impair' : 'pair' }}">
|
||||
<b>{{ name }}</b> :
|
||||
{% if value is iterable %}
|
||||
{{ value | join(' ; ') }}
|
||||
{% else %}
|
||||
{{ value }}
|
||||
{% endif %}
|
||||
</div>
|
||||
{% endfor %}
|
||||
{% if technical|default(true) and app['authentication'].user is not none and user_setting('technical_display') == 'group' %}
|
||||
<hr/>
|
||||
{% include 'common/technical_datas.html.twig' %}
|
||||
{% endif %}
|
||||
{% endmacro %}
|
||||
@@ -1,4 +1,4 @@
|
||||
{% include 'prod/results/record.html.twig' with {
|
||||
'record': item,
|
||||
'record': record,
|
||||
'settings': settings
|
||||
} %}
|
||||
|
||||
@@ -4,17 +4,17 @@
|
||||
<div class='list ui-corner-all'>
|
||||
<table style='width:100%;' cellspacing='0' cellpadding='0' border='0'>
|
||||
<tr>
|
||||
<td valign="top" style='width:{{th_size+50}}px'>
|
||||
<td valign="top" style='width:{{ settings.images_size + 50 }}px'>
|
||||
{% include 'prod/results/record.html.twig' with {
|
||||
'record': item,
|
||||
'record': record,
|
||||
'settings': settings
|
||||
} %}
|
||||
</td>
|
||||
<td valign="middle">
|
||||
<div class='desc' style='max-height:{{th_size+70}}px;overflow-y:auto;'>
|
||||
<div class='desc' style='max-height:{{ settings.images_size + 70 }}px;overflow-y:auto;'>
|
||||
<div class="fixeddesc">
|
||||
{% set business = app['acl'].get(app['authentication'].getUser()).has_right_on_base(record.baseId(), 'canmodifrecord') %}
|
||||
{{ macro.format_caption(record, highlight, searchEngine, searchOptions, business, true, true) }}
|
||||
{% set business = granted_on_collection(record.baseId, 'canmodifrecord') %}
|
||||
{{ macro.caption(record, business) }}
|
||||
</div>
|
||||
</div>
|
||||
</td>
|
||||
|
||||
@@ -20,11 +20,10 @@
|
||||
{% set doctype_display = user_setting('doctype_display') %}
|
||||
|
||||
<div class="selectable" style="margin:10px 0; float:left;">
|
||||
{% for item in results.results %}
|
||||
{% for record in results.results %}
|
||||
{% block content_item %}
|
||||
{% include (user_setting('view', 'thumbs') == 'thumbs') ? 'prod/results/grid.html.twig' : 'prod/results/list.html.twig' with {
|
||||
'record': item,
|
||||
'context': context,
|
||||
'record': record,
|
||||
'settings': {
|
||||
'images_size': images_size,
|
||||
'technical_display': technical_display,
|
||||
|
||||
Reference in New Issue
Block a user