Merge branch 'master' into PHRAS-2721_Edit_form_fix_submit_form

This commit is contained in:
Nicolas Maillat
2019-09-20 10:19:14 +02:00
committed by GitHub
8 changed files with 144 additions and 134 deletions

View File

@@ -31,17 +31,13 @@ var commonModule = (function ($, p4) {
$(this).removeClass('context-menu-item-hover'); $(this).removeClass('context-menu-item-hover');
}); });
// $('#help-trigger').contextMenu('#mainMenu .helpcontextmenu', {openEvt: 'click', dropDown: true, theme: 'vista', dropDown: true,
// showTransition: 'slideDown',
// hideTransition: 'hide',
// shadow: false
// });
$('body').on('click', '.infoDialog', function (event) { $('body').on('click', '.infoDialog', function (event) {
infoDialog($(this)); infoDialog($(this));
}); });
}); });
function showOverlay(n, appendto, callback, zIndex) { function showOverlay(n, appendto, callback, zIndex) {
var div = "OVERLAY"; var div = "OVERLAY";

View File

@@ -88,4 +88,20 @@ $mainMenuLinkBackgroundHoverColor: transparent;
box-shadow: 0 2px 4px 0 rgba(0, 0, 0, 0.39); box-shadow: 0 2px 4px 0 rgba(0, 0, 0, 0.39);
} }
} }
/*Help menu*/
.contextMenu.helpcontextmenu {
display: none;
&.shown {
display: block;
position: absolute;
z-index: 101;
}
}
.help-trigger {
display:inline-block;
cursor:pointer;
padding: 0 4px;
border:none;
margin-left: -12px;
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 682 B

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 802 B

After

Width:  |  Height:  |  Size: 1.7 KiB

View File

@@ -110,7 +110,7 @@ $select-height: 26px;
} }
.input-prepend { .input-prepend {
margin: 0; margin: 0;
.dmin, .dmax { .dmin, .dmax {
border: 0 none; border: 0 none;
height: 16px; height: 16px;
@@ -203,7 +203,7 @@ $select-height: 26px;
height: $select-height; height: $select-height;
} }
.select-styled { .select-styled {
position: absolute; position: absolute;
top: 0; top: 0;
right: 0; right: 0;
bottom: 0; bottom: 0;
@@ -232,9 +232,9 @@ $select-height: 26px;
background-color: darken($select-background, 5); background-color: darken($select-background, 5);
} }
} }
.select-options { .select-options {
display: none; display: none;
position: absolute; position: absolute;
top: 12px; top: 12px;
right: -12px; right: -12px;
@@ -292,7 +292,7 @@ $select-height: 26px;
-webkit-transform: translate(-50%, -50%); -webkit-transform: translate(-50%, -50%);
-ms-transform: translate(-50%, -50%); -ms-transform: translate(-50%, -50%);
transform: translate(-50%, -50%); transform: translate(-50%, -50%);
&:hover { &:hover {
background-color: #2c2c2c; background-color: #2c2c2c;
} }
@@ -355,4 +355,8 @@ $select-height: 26px;
&.ui-widget-content{ &.ui-widget-content{
background-color: #212121; background-color: #212121;
} }
} }
#mainMenu li .context-menu-item-inner a:hover {
color: #000;
}

View File

@@ -25,103 +25,103 @@
<div id="nav_menu_container" class="desktopmenu"> <div id="nav_menu_container" class="desktopmenu">
<div class="arrow-up"></div> <div class="arrow-up"></div>
<ol class="nav_menu"> <ol class="nav_menu">
<li class="menu-bar-item"> <li class="menu-bar-item">
<a target="_blank" href="{{ path('prod') }}"> <a target="_blank" href="{{ path('prod') }}">
<img src="/assets/common/images/icons/menu-prod.png" class="mobilemenu"/> <img src="/assets/common/images/icons/menu-prod.png" class="mobilemenu"/>
<span class="{% if module is defined and module == "prod" %}selected{% endif %}"> <span class="{% if module is defined and module == "prod" %}selected{% endif %}">
{{ 'admin::monitor: production' | trans }} {{ 'admin::monitor: production' | trans }}
</span> </span>
</a> </a>
</li> </li>
{% if app['browser'].isNewGeneration and app['conf'].get(['registry', 'modules', 'thesaurus']) == true and app.getAclForUser(app.getAuthenticatedUser()).has_access_to_module('thesaurus') %} {% if app['browser'].isNewGeneration and app['conf'].get(['registry', 'modules', 'thesaurus']) == true and app.getAclForUser(app.getAuthenticatedUser()).has_access_to_module('thesaurus') %}
<li class="menu-bar-item"> <li class="menu-bar-item">
<a target="_blank" href="{{ path('thesaurus') }}"> <a target="_blank" href="{{ path('thesaurus') }}">
<img src="/assets/common/images/icons/menu-thesaurus.png" class="mobilemenu"/> <img src="/assets/common/images/icons/menu-thesaurus.png" class="mobilemenu"/>
<span class="{% if module is defined and module == "thesaurus" %}selected{% endif %}"> <span class="{% if module is defined and module == "thesaurus" %}selected{% endif %}">
{{ 'admin::monitor: module thesaurus' | trans }} {{ 'admin::monitor: module thesaurus' | trans }}
</span> </span>
</a>
</li>
{% endif %}
{# MODULE #}
{% if app.getAclForUser(app.getAuthenticatedUser()).has_access_to_module('admin') %}
<li class="menu-bar-item">
<a target="_blank" href="{{ path('admin') }}">
<img src="/assets/common/images/icons/menu-admin.png" class="mobilemenu"/>
<span class="{% if module is defined and module == "admin" %}selected{% endif %}">
{{ 'admin::monitor: module admin' | trans }}
</span>
</a>
</li>
{% endif %}
{# MODULE #}
{% if app.getAclForUser(app.getAuthenticatedUser()).has_access_to_module('report') %}
<li class="menu-bar-item">
<a target="_blank" href="{{ path('report_dashboard') }}">
<img src="/assets/common/images/icons/menu-report.png" class="mobilemenu"/>
<span class="{% if module is defined and module == "report" %}selected{% endif %}">
{{ 'admin::monitor: module report' | trans }}
</span>
</a>
</li>
{% endif %}
{# MODULE #}
<li class="menu-bar-item">
<a id="validation_link" target="_blank" href="{{ path('lightbox') }}">
<img src="/assets/common/images/icons/menu-lightbox.png" class="mobilemenu"/>
<span>
{{ 'admin::monitor: module validation' | trans }}
</span>
</a> </a>
</li> </li>
{% endif %}
{# MODULE #}
{% if module is defined and module == "prod" %}
{% if app.getAclForUser(app.getAuthenticatedUser()).has_access_to_module('upload') %}
<li class="menu-bar-item">
{% set link = path('upload_html5_form') %}
{% if not app['browser'].supportFileAPI() %} {# MODULE #}
{% set link = path('upload_flash_form') %} {% if app.getAclForUser(app.getAuthenticatedUser()).has_access_to_module('admin') %}
{% endif %} <li class="menu-bar-item">
<a target="_blank" href="{{ path('admin') }}">
<img src="/assets/common/images/icons/menu-admin.png" class="mobilemenu"/>
<span class="{% if module is defined and module == "admin" %}selected{% endif %}">
{{ 'admin::monitor: module admin' | trans }}
</span>
</a>
</li>
{% endif %}
<a href="{{ link }}" class="uploader-open-action" {# MODULE #}
title="{{ 'Upload' | trans }}"> {% if app.getAclForUser(app.getAuthenticatedUser()).has_access_to_module('report') %}
<img src="/assets/common/images/icons/menu-upload.png" class="mobilemenu"/> <li class="menu-bar-item">
<span> <a target="_blank" href="{{ path('report_dashboard') }}">
<img src="/assets/common/images/icons/menu-report.png" class="mobilemenu"/>
<span class="{% if module is defined and module == "report" %}selected{% endif %}">
{{ 'admin::monitor: module report' | trans }}
</span>
</a>
</li>
{% endif %}
{# MODULE #}
<li class="menu-bar-item">
<a id="validation_link" target="_blank" href="{{ path('lightbox') }}">
<img src="/assets/common/images/icons/menu-lightbox.png" class="mobilemenu"/>
<span>
{{ 'admin::monitor: module validation' | trans }}
</span>
</a>
</li>
{# MODULE #}
{% if module is defined and module == "prod" %}
{% if app.getAclForUser(app.getAuthenticatedUser()).has_access_to_module('upload') %}
<li class="menu-bar-item">
{% set link = path('upload_html5_form') %}
{% if not app['browser'].supportFileAPI() %}
{% set link = path('upload_flash_form') %}
{% endif %}
<a href="{{ link }}" class="uploader-open-action"
title="{{ 'Upload' | trans }}">
<img src="/assets/common/images/icons/menu-upload.png" class="mobilemenu"/>
<span>
{{ 'admin::monitor: module upload' | trans }} {{ 'admin::monitor: module upload' | trans }}
</span> </span>
</a>
</li>
{% endif %}
{% endif %}
{# MODULE #}
{% if module == "prod" %}
<li class="menu-bar-item">
<a href="#" class="state-navigation" data-state="publication">
<img src="/assets/common/images/icons/menu-publication.png" class="mobilemenu"/>
<span>
{{ 'Publications' | trans }}
</span>
</a> </a>
</li> </li>
{% endif %} {% endif %}
{% endif %}
{% if module is defined and module == "prod" and app.getAclForUser(app.getAuthenticatedUser()).has_right(constant('\\ACL::ORDER_MASTER')) %} {# MODULE #}
<li class="menu-bar-item"> {% if module == "prod" %}
<a href="#" class="order-open-action" title="{{ 'Orders manager' | trans }}"> <li class="menu-bar-item">
<a href="#" class="state-navigation" data-state="publication">
<img src="/assets/common/images/icons/menu-publication.png" class="mobilemenu"/>
<span>
{{ 'Publications' | trans }}
</span>
</a>
</li>
{% endif %}
{% if module is defined and module == "prod" and app.getAclForUser(app.getAuthenticatedUser()).has_right(constant('\\ACL::ORDER_MASTER')) %}
<li class="menu-bar-item">
<a href="#" class="order-open-action" title="{{ 'Orders manager' | trans }}">
<span> <span>
{{ 'Commandes' | trans }} {{ 'Commandes' | trans }}
</span> </span>
</a> </a>
</li> </li>
{% endif %} {% endif %}
</ol> </ol>
</div> </div>
@@ -235,11 +235,10 @@
<a target="_blank" href="https://docs.phraseanet.com/4.0/"> <a target="_blank" href="https://docs.phraseanet.com/4.0/">
<span> <span>
{{ 'phraseanet:: aide' | trans }} {{ 'phraseanet:: aide' | trans }}
<span style="display:inline-block;cursor:pointer;padding:0;border:none;padding-right:4px;padding-left:4px;"
id="help-trigger"> <i class="fa fa-caret-down" aria-hidden="true"></i></span>
</span> </span>
</a> </a>
<table cellspacing="0" cellpadding="0" style="display:none;" class="contextMenu helpcontextmenu"> <span id="help-trigger" class="help-trigger"> <i class="fa fa-caret-down" aria-hidden="true"></i></span>
<table cellspacing="0" cellpadding="0" class="contextMenu helpcontextmenu context-menu-theme-vistamenu-bar">
<tbody> <tbody>
<tr> <tr>
<td> <td>
@@ -301,6 +300,10 @@
<script type="text/javascript"> <script type="text/javascript">
$(document).ready(function () { $(document).ready(function () {
$('body').on('click', '#help-trigger', function (event) {
$('#mainMenu .helpcontextmenu').toggleClass('shown');
console.log('mety');
});
// var key = 'help'; // var key = 'help';
var configurationSettingLinks = {{ configuration|json_encode|raw }}; var configurationSettingLinks = {{ configuration|json_encode|raw }};
//seperate array based on location of link //seperate array based on location of link

View File

@@ -102,4 +102,22 @@
transform: translate(-50%, -50%); transform: translate(-50%, -50%);
} }
</style> </style>
<script>
//load the next result page
jQuery(document).ready(function(){
jQuery('.next_res').click(function(){
jQuery('.results').append('<img class="result_loader" src="/assets/common/images/icons/loading.svg">');
jQuery('.results').load($(this).attr('href'));
return false;
});
});
//load the prev result page
jQuery(document).ready(function(){
jQuery('.prev_res').click(function(){
jQuery('.results').append('<img class="result_loader" src="/assets/common/images/icons/loading.svg">');
jQuery('.results').load($(this).attr('href'));
return false;
});
});
</script>

View File

@@ -14,35 +14,30 @@
<div class="PNB datas"> <div class="PNB datas">
<div class="PNB" style="right:10px"> <div class="PNB" style="right:10px">
{% for Basket in Baskets %} {% for Basket in Baskets %}
<div class="result {% if loop.index is odd %}odd{% endif %}"> <div class="result {{ Basket.getArchived ? '' : 'unarchived' }}">
<a href="{{ path('basket_delete', {basket: Basket.getId()}) }}" class="delete-basket close" title="{% trans %}Delete basket{% endtrans %}" style="color:#fff;padding:2px">×</a> <a href="{{ path('basket_delete', {basket: Basket.getId()}) }}" class="delete-basket close icon-baseline-close-24px" title="{% trans %}Delete basket{% endtrans %}" style="color:#fff;padding:2px">&nbsp;</a>
<div class="PNB10 rightBrowserInner"> <div class="PNB10 rightBrowserInner">
<table> <div class="item-table">
<tr>
<td class="thumbnail"> <div class="thumbnail">
{% set BasketElement = Basket.getElements().first() %} {% set BasketElement = Basket.getElements().first() %}
{% if BasketElement %} {% if BasketElement %}
{{thumbnail.format(BasketElement.getRecord(app).get_thumbnail(), 150, 106, '', true, false)}} {{thumbnail.format(BasketElement.getRecord(app).get_thumbnail(), 150, 106, '', true, false)}}
{% endif %} {% endif %}
</td> </div>
<td class="" width="12" style="font-size: 0">&nbsp;</td> <div class="content">
<td class="content">
<h1 class="title"> <h1 class="title">
<img class="loader" src="/assets/prod/images/Basket/Browser/loader.gif" /> <img class="loader" src="/assets/prod/images/Basket/Browser/loader.gif" />
{% if Basket.getValidation() is empty or Basket.getValidation().isInitiator(app.getAuthenticatedUser()) %} {% if Basket.getValidation() is empty or Basket.getValidation().isInitiator(app.getAuthenticatedUser()) %}
<a href="{{ path('prod_baskets_basket_archive', { 'basket' : Basket.getId(), 'archive' : 1 }) }}" class="archiver archive_toggler" style="display:{{ Basket.getArchived ? 'none' : '' }};"> <a href="{{ path('prod_baskets_basket_archive', { 'basket' : Basket.getId(), 'archive' : 1 }) }}" class="archiver archive_toggler" style="display:{{ Basket.getArchived ? 'none' : '' }};">
<span> &nbsp;
<img src="/assets/prod/images/Basket/Browser/archive.png"/>
</span>
</a> </a>
<a href="{{ path('prod_baskets_basket_archive', { 'basket' : Basket.getId(), 'archive' : 0 }) }}" class="unarchiver archive_toggler" style="display:{{ Basket.getArchived ? '' : 'none' }};"> <a href="{{ path('prod_baskets_basket_archive', { 'basket' : Basket.getId(), 'archive' : 0 }) }}" class="unarchiver archive_toggler" style="display:{{ Basket.getArchived ? '' : 'none' }};">
<span> &nbsp;
<img src="/assets/prod/images/Basket/Browser/archived.png"/>
</span>
</a> </a>
{% endif %} {% endif %}
<a class="basket_link" href="{{ path('prod_workzone_basket', { basket : Basket.getId() }) }}"> <a class="basket_link" href="{{ path('prod_workzone_basket', { basket : Basket.getId() }) }}">
{{ Basket.getName() }} <span>{{ Basket.getName() }}</span>
<br><span class="basketCount"> <br><span class="basketCount">
{{ Basket.getElements().count() }} {{ ' records' }} {{ Basket.getElements().count() }} {{ ' records' }}
</span></a> </span></a>
@@ -74,12 +69,11 @@
</p> </p>
{% endif %} {% endif %}
</td> </div>
<td> <td>
</td> </td>
</tr> </div>
</table>
</div> </div>
</div> </div>
{% endfor %} {% endfor %}
@@ -99,37 +93,16 @@
</td> </td>
<td class="paginator"> <td class="paginator">
{% if Page - 1 > 0 %} {% if Page - 1 > 0 %}
<a href="{{ path('prod_workzone_search', { 'Query' : Query, 'Year' : Year, 'Type' : Type, 'Page' : (Page - 1) }) }}" class="result prev_res"> <a href="{{ path('prod_workzone_search', { 'Query' : Query, 'Year' : Year, 'Type' : Type, 'Page' : (Page - 1) }) }}" class="result prev_res icon-round-chevron_left-24px">&nbsp;</a>
<
</a>
{% endif %} {% endif %}
<span> <span>
Page {{ Page }} / {{ MaxPage }} Page {{ Page }} / {{ MaxPage }}
</span> </span>
{% if Page + 1 <= MaxPage %} {% if Page + 1 <= MaxPage %}
<a href="{{ path('prod_workzone_search', { 'Query' : Query, 'Year' : Year, 'Type' : Type, 'Page' : (Page + 1) }) }}" class="result next_res"> <a href="{{ path('prod_workzone_search', { 'Query' : Query, 'Year' : Year, 'Type' : Type, 'Page' : (Page + 1) }) }}" class="result next_res icon-round-chevron_right-24px">&nbsp;</a>
>
</a>
{% endif %} {% endif %}
</td> </td>
</tr> </tr>
</table> </table>
</div> </div>
<script>
//load the next result page
jQuery(document).ready(function(){
jQuery('.next_res').click(function(){
jQuery('.results').append('<img class="result_loader" src="/assets/common/images/icons/loading.svg">');
jQuery('.results').load($(this).attr('href'));
return false;
});
});
//load the prev result page
jQuery(document).ready(function(){
jQuery('.prev_res').click(function(){
jQuery('.results').append('<img class="result_loader" src="/assets/common/images/icons/loading.svg">');
jQuery('.results').load($(this).attr('href'));
return false;
});
});
</script>