diff --git a/.circleci/config.yml b/.circleci/config.yml
index ce2f8c9a5c..3ebc93224a 100644
--- a/.circleci/config.yml
+++ b/.circleci/config.yml
@@ -123,8 +123,8 @@ workflows:
dockerfile: Dockerfile
extra-build-args: "--target phraseanet-fpm"
region: AWS_DEFAULT_REGION
- repo: "${AWS_RESOURCE_NAME_PREFIX}/phraseanet"
- tag: "alpha-0.1"
+ repo: "phraseanet-fpm"
+ tag: "${CIRCLE_BRANCH}"
- aws-ecr/build_and_push_image:
account-url: AWS_ACCOUNT_URL
aws-access-key-id: AWS_ACCESS_KEY_ID
@@ -134,8 +134,8 @@ workflows:
dockerfile: Dockerfile
extra-build-args: "--target phraseanet-nginx"
region: AWS_DEFAULT_REGION
- repo: "${AWS_RESOURCE_NAME_PREFIX}/phraseanet-nginx"
- tag: "alpha-0.1"
+ repo: "phraseanet-nginx"
+ tag: "${CIRCLE_BRANCH}"
- aws-ecr/build_and_push_image:
account-url: AWS_ACCOUNT_URL
aws-access-key-id: AWS_ACCESS_KEY_ID
@@ -145,5 +145,5 @@ workflows:
dockerfile: Dockerfile
extra-build-args: "--target phraseanet-worker"
region: AWS_DEFAULT_REGION
- repo: "${AWS_RESOURCE_NAME_PREFIX}/phraseanet"
- tag: "alpha-0.1"
+ repo: "phraseanet-worker"
+ tag: "${CIRCLE_BRANCH}"
diff --git a/README.md b/README.md
index 751efed810..0105de60fa 100644
--- a/README.md
+++ b/README.md
@@ -72,3 +72,7 @@ It will build and tag the following images :
local/phraseanet-worker:
local/phraseanet-fpm:
local/phraseanet-nginx:
+
+# Deploy the application
+
+Once the images are built, you can deploy the entire phraseanet stack using the repository : https://github.com/alchemy-fr/phraseanet-docker and follow the instruction inside its `README.md` file.
diff --git a/grammar/query.pp b/grammar/query.pp
index b55c8f9aba..03df29b061 100644
--- a/grammar/query.pp
+++ b/grammar/query.pp
@@ -128,7 +128,7 @@ key:
| quoted_string()
group:
- ::space::? ::parenthese_:: primary() ::_parenthese:: ::space::?
+ ::space::? ::parenthese_:: ::space::? primary() ::space::? ::_parenthese:: ::space::?
// Thesaurus terms
diff --git a/lib/Alchemy/Phrasea/Controller/Prod/QueryController.php b/lib/Alchemy/Phrasea/Controller/Prod/QueryController.php
index a6706424aa..d327e860c5 100644
--- a/lib/Alchemy/Phrasea/Controller/Prod/QueryController.php
+++ b/lib/Alchemy/Phrasea/Controller/Prod/QueryController.php
@@ -341,10 +341,20 @@ class QueryController extends Controller
if ($result->getTotal() === 0) {
$template = 'prod/results/help.html.twig';
- } else {
+ }
+ else {
$template = 'prod/results/records.html.twig';
}
- $json['results'] = $this->render($template, ['results'=> $result]);
+
+ /** @var \Closure $filter */
+ $filter = $this->app['plugin.filter_by_authorization'];
+
+ $plugins = [
+ 'workzone' => $filter('workzone'),
+ 'actionbar' => $filter('actionbar'),
+ ];
+
+ $json['results'] = $this->render($template, ['results'=> $result, 'plugins'=>$plugins]);
// add technical fields
diff --git a/lib/classes/databox.php b/lib/classes/databox.php
index c961f1e58c..3377695e39 100644
--- a/lib/classes/databox.php
+++ b/lib/classes/databox.php
@@ -463,8 +463,8 @@ class databox extends base implements ThumbnailedElement
->set_type($type)
->set_tbranch(isset($field['tbranch']) ? (string) $field['tbranch'] : '')
->set_generate_cterms((isset($field['generate_cterms']) && (string) $field['generate_cterms'] == 1))
- ->set_gui_editable((isset($field['gui_editable']) && (string) $field['gui_editable'] == 1))
- ->set_gui_visible((isset($field['gui_editable']) && (string) $field['gui_visible'] == 1))
+ ->set_gui_editable((!isset($field['gui_editable']) || (isset($field['gui_editable']) && (string) $field['gui_editable'] == 1)))
+ ->set_gui_visible((!isset($field['gui_visible']) || (isset($field['gui_visible']) && (string) $field['gui_visible'] == 1)))
->set_thumbtitle(isset($field['thumbtitle']) ? (string) $field['thumbtitle'] : (isset($field['thumbTitle']) ? $field['thumbTitle'] : '0'))
->set_report(isset($field['report']) ? (string) $field['report'] : '1')
->save();
diff --git a/lib/conf.d/data_templates/DublinCore.xml b/lib/conf.d/data_templates/DublinCore.xml
index 31e874a13d..eae43d5461 100644
--- a/lib/conf.d/data_templates/DublinCore.xml
+++ b/lib/conf.d/data_templates/DublinCore.xml
@@ -79,7 +79,7 @@
748
video
yes
- libfaac
+ libmp3lame
libx264
screen
1000
diff --git a/lib/conf.d/data_templates/en-simple.xml b/lib/conf.d/data_templates/en-simple.xml
index 5c5b10910d..44b0afa69f 100644
--- a/lib/conf.d/data_templates/en-simple.xml
+++ b/lib/conf.d/data_templates/en-simple.xml
@@ -79,7 +79,7 @@
748
video
yes
- libfaac
+ libmp3lame
libx264
screen
1000
diff --git a/lib/conf.d/data_templates/fr-simple.xml b/lib/conf.d/data_templates/fr-simple.xml
index 49ab36b98d..cc0a2b582c 100644
--- a/lib/conf.d/data_templates/fr-simple.xml
+++ b/lib/conf.d/data_templates/fr-simple.xml
@@ -79,7 +79,7 @@
748
video
yes
- libfaac
+ libmp3lame
libx264
screen
1000
diff --git a/package.json b/package.json
index 4b89b778ce..fc730f3db4 100644
--- a/package.json
+++ b/package.json
@@ -65,7 +65,7 @@
"normalize-css": "^2.1.0",
"npm": "^6.0.0",
"npm-modernizr": "^2.8.3",
- "phraseanet-production-client": "0.34.77-d",
+ "phraseanet-production-client": "0.34.80-d",
"requirejs": "^2.3.5",
"tinymce": "^4.0.28",
"underscore": "^1.8.3",
diff --git a/resources/locales/messages.de.xlf b/resources/locales/messages.de.xlf
index e33805ddeb..f6f73c85c8 100644
--- a/resources/locales/messages.de.xlf
+++ b/resources/locales/messages.de.xlf
@@ -1,6 +1,6 @@
-
+
The source node in most cases contains the sample message as written by the developer. If it looks like a dot-delimitted string such as "form.label.firstname", then the developer has not provided a default message.
@@ -9940,6 +9940,21 @@
Änderungen wurden hergestellt
admin/databox/databox.html.twig
+
+ generate_cterms
+ generate_cterms
+ admin/fields/templates.html.twig
+
+
+ gui_editable
+ gui_editable
+ admin/fields/templates.html.twig
+
+
+ gui_visible
+ gui_visible
+ admin/fields/templates.html.twig
+
help::help-section-bullet: check-spelling
Vergewissern Sie sich, dass kein Schreibfehler oder Tippfehler vorliegt
@@ -10082,9 +10097,15 @@
Die Dienstleistung wird in einige Minuten wieder verfügbar sein.
actions/Bridge/deactivated.html.twig
+
+ lightbox::list
+ lightbox::list
+ mobile/lightbox/validate.html.twig
+
lightbox::recaptitulatif
Übersicht
+ mobile/lightbox/validate.html.twig
web/lightbox/agreement_box.html.twig
web/lightbox/validate.html.twig
@@ -13131,7 +13152,7 @@
validation:: note
Kommentare
- mobile/lightbox/sc_note.html.twig
+ mobile/lightbox/sc_note.html.twig
validation:: votre note
@@ -13141,8 +13162,8 @@
validation::envoyer mon rapport
Meinen Bericht senden
- mobile/lightbox/validate.html.twig
- mobile/lightbox/validate.html.twig
+ mobile/lightbox/validate.html.twig
+ mobile/lightbox/validate.html.twig
web/lightbox/basket_options.html.twig
web/lightbox/basket_options.html.twig
diff --git a/resources/locales/messages.en.xlf b/resources/locales/messages.en.xlf
index 4392499d5e..2bdfd5b0cd 100644
--- a/resources/locales/messages.en.xlf
+++ b/resources/locales/messages.en.xlf
@@ -1,6 +1,6 @@
-
+
The source node in most cases contains the sample message as written by the developer. If it looks like a dot-delimitted string such as "form.label.firstname", then the developer has not provided a default message.
@@ -9940,6 +9940,21 @@
Modifications done
admin/databox/databox.html.twig
+
+ generate_cterms
+ generate_cterms
+ admin/fields/templates.html.twig
+
+
+ gui_editable
+ gui_editable
+ admin/fields/templates.html.twig
+
+
+ gui_visible
+ gui_visible
+ admin/fields/templates.html.twig
+
help::help-section-bullet: check-spelling
Check that there are no misspellings or typing errors.
@@ -10083,9 +10098,15 @@ See documentation for more examples https://docs.phraseanet.com
Service will be available again in a few minutes
actions/Bridge/deactivated.html.twig
+
+ lightbox::list
+ lightbox::list
+ mobile/lightbox/validate.html.twig
+
lightbox::recaptitulatif
Summary
+ mobile/lightbox/validate.html.twig
web/lightbox/agreement_box.html.twig
web/lightbox/validate.html.twig
@@ -13135,7 +13156,7 @@ It is possible to place several search areas
validation:: note
Comments
- mobile/lightbox/sc_note.html.twig
+ mobile/lightbox/sc_note.html.twig
validation:: votre note
@@ -13145,8 +13166,8 @@ It is possible to place several search areas
validation::envoyer mon rapport
Send my feedback
- mobile/lightbox/validate.html.twig
- mobile/lightbox/validate.html.twig
+ mobile/lightbox/validate.html.twig
+ mobile/lightbox/validate.html.twig
web/lightbox/basket_options.html.twig
web/lightbox/basket_options.html.twig
diff --git a/resources/locales/messages.fr.xlf b/resources/locales/messages.fr.xlf
index 71c3b52cf7..1eb4a7f0ca 100644
--- a/resources/locales/messages.fr.xlf
+++ b/resources/locales/messages.fr.xlf
@@ -1,6 +1,6 @@
-
+
The source node in most cases contains the sample message as written by the developer. If it looks like a dot-delimitted string such as "form.label.firstname", then the developer has not provided a default message.
@@ -9940,6 +9940,21 @@ Si vous recevez cet e-mail sans l'avoir sollicité, merci de l'ignorer ou de le
Modifications effectuées
admin/databox/databox.html.twig
+
+ generate_cterms
+ generate_cterms
+ admin/fields/templates.html.twig
+
+
+ gui_editable
+ gui_editable
+ admin/fields/templates.html.twig
+
+
+ gui_visible
+ gui_visible
+ admin/fields/templates.html.twig
+
help::help-section-bullet: check-spelling
help::help-section-bullet: check-spelling
@@ -10082,9 +10097,15 @@ Si vous recevez cet e-mail sans l'avoir sollicité, merci de l'ignorer ou de le
Le service sera de nouveau disponible dans quelques minutes.
actions/Bridge/deactivated.html.twig
+
+ lightbox::list
+ lightbox::list
+ mobile/lightbox/validate.html.twig
+
lightbox::recaptitulatif
Récapitulatif
+ mobile/lightbox/validate.html.twig
web/lightbox/agreement_box.html.twig
web/lightbox/validate.html.twig
@@ -13131,7 +13152,7 @@ Si vous recevez cet e-mail sans l'avoir sollicité, merci de l'ignorer ou de le
validation:: note
Annotation
- mobile/lightbox/sc_note.html.twig
+ mobile/lightbox/sc_note.html.twig
validation:: votre note
@@ -13141,8 +13162,8 @@ Si vous recevez cet e-mail sans l'avoir sollicité, merci de l'ignorer ou de le
validation::envoyer mon rapport
Envoyer mon rapport
- mobile/lightbox/validate.html.twig
- mobile/lightbox/validate.html.twig
+ mobile/lightbox/validate.html.twig
+ mobile/lightbox/validate.html.twig
web/lightbox/basket_options.html.twig
web/lightbox/basket_options.html.twig
diff --git a/resources/locales/messages.nl.xlf b/resources/locales/messages.nl.xlf
index 6fbc835166..5b9362ba05 100644
--- a/resources/locales/messages.nl.xlf
+++ b/resources/locales/messages.nl.xlf
@@ -1,6 +1,6 @@
-
+
The source node in most cases contains the sample message as written by the developer. If it looks like a dot-delimitted string such as "form.label.firstname", then the developer has not provided a default message.
@@ -9947,6 +9947,21 @@
Bewerking correct uitgevoerd
admin/databox/databox.html.twig
+
+ generate_cterms
+ generate_cterms
+ admin/fields/templates.html.twig
+
+
+ gui_editable
+ gui_editable
+ admin/fields/templates.html.twig
+
+
+ gui_visible
+ gui_visible
+ admin/fields/templates.html.twig
+
help::help-section-bullet: check-spelling
help::help-section-bullet: check-spelling
@@ -10089,9 +10104,15 @@
de service zal binnen enkele minuten opnieuw beschibaar zijn
actions/Bridge/deactivated.html.twig
+
+ lightbox::list
+ lightbox::list
+ mobile/lightbox/validate.html.twig
+
lightbox::recaptitulatif
Beknopt
+ mobile/lightbox/validate.html.twig
web/lightbox/agreement_box.html.twig
web/lightbox/validate.html.twig
@@ -13138,7 +13159,7 @@
validation:: note
Nota
- mobile/lightbox/sc_note.html.twig
+ mobile/lightbox/sc_note.html.twig
validation:: votre note
@@ -13148,8 +13169,8 @@
validation::envoyer mon rapport
stuur mijn rapport
- mobile/lightbox/validate.html.twig
- mobile/lightbox/validate.html.twig
+ mobile/lightbox/validate.html.twig
+ mobile/lightbox/validate.html.twig
web/lightbox/basket_options.html.twig
web/lightbox/basket_options.html.twig
diff --git a/resources/locales/validators.de.xlf b/resources/locales/validators.de.xlf
index 1e99babf4b..777d9db988 100644
--- a/resources/locales/validators.de.xlf
+++ b/resources/locales/validators.de.xlf
@@ -1,6 +1,6 @@
-
+
The source node in most cases contains the sample message as written by the developer. If it looks like a dot-delimitted string such as "form.label.firstname", then the developer has not provided a default message.
diff --git a/resources/locales/validators.en.xlf b/resources/locales/validators.en.xlf
index 753b0bd9e2..ef9ae08f16 100644
--- a/resources/locales/validators.en.xlf
+++ b/resources/locales/validators.en.xlf
@@ -1,6 +1,6 @@
-
+
The source node in most cases contains the sample message as written by the developer. If it looks like a dot-delimitted string such as "form.label.firstname", then the developer has not provided a default message.
diff --git a/resources/locales/validators.nl.xlf b/resources/locales/validators.nl.xlf
index af3a53e211..63998943cb 100644
--- a/resources/locales/validators.nl.xlf
+++ b/resources/locales/validators.nl.xlf
@@ -1,6 +1,6 @@
-
+
-
-
-
- {% if basket.getValidation() and basket.getValidation().getParticipant(app.getAuthenticatedUser()).getCanAgree() %}
-
- {{ 'validation::envoyer mon rapport' | trans }}
-
-
- {% endif %}
-
+
+
+
+
+
+ {% if basket.getValidation() and basket.getValidation().getParticipant(app.getAuthenticatedUser()).getCanAgree() %}
+
+ {{ 'validation::envoyer mon rapport' | trans }}
+
+
+ {% endif %}
+
+
+
{% endblock %}
diff --git a/templates/web/lightbox/basket_content_report.html.twig b/templates/web/lightbox/basket_content_report.html.twig
index 54798fc9b5..224a604eac 100644
--- a/templates/web/lightbox/basket_content_report.html.twig
+++ b/templates/web/lightbox/basket_content_report.html.twig
@@ -4,48 +4,50 @@
{% for basket_element in basket.getElements() %}
{% set record = basket_element.getRecord(app) %}
-
-
-
-
-
-
-
- {{basket_element.getOrd()}}
+
+
+
+
+
+
+ {{basket_element.getOrd()}}
+
+ {{thumbnail.format(record.get_thumbnail(),165, 125, '', true, false)}}
+
- {{thumbnail.format(record.get_thumbnail(),165, 125, '', true, false)}}
+
+ {% for validationDatas in basket_element.getValidationDatas()%}
+
+ {% if validationDatas.getAgreement() == true %}
+ {% set imguser = '
' %}
+ {% set styleuser = '' %}
+ {% elseif validationDatas.getAgreement() is null %}
+ {% set imguser = ' ' %}
+ {% set styleuser = 'margin-left:18px;' %}
+ {% else %}
+ {% set imguser = '
' %}
+ {% set styleuser = '' %}
+ {% endif %}
+
+
+ {% if basket_element.getBasket().getValidation().getParticipant(app.getAuthenticatedUser()).getCanSeeOthers() or validationDatas.getParticipant().getUser() == app.getAuthenticatedUser() %}
+ {{imguser|raw}}
+ {% endif %}
-
-
-
-
- {% for validationDatas in basket_element.getValidationDatas()%}
-
-
- {% if validationDatas.getAgreement() == true %}
- {% set imguser = '
' %}
- {% set styleuser = '' %}
- {% elseif validationDatas.getAgreement() is null %}
- {% set imguser = '' %}
- {% set styleuser = 'margin-left:18px;' %}
- {% else %}
- {% set imguser = '
' %}
- {% set styleuser = '' %}
- {% endif %}
-
{{imguser|raw}} {{validationDatas.getParticipant().getUser().getDisplayName()}}
- {% if validationDatas.getNote() != '' %}
- : {{validationDatas.getNote()|nl2br}}
- {% endif %}
-
-
- {% endfor %}
-
-
-
+
+
{{validationDatas.getParticipant().getUser().getDisplayName()}}
+ {% if validationDatas.getNote() != '' %}
+ {% if basket_element.getBasket().getValidation().getParticipant(app.getAuthenticatedUser()).getCanSeeOthers() or validationDatas.getParticipant().getUser() == app.getAuthenticatedUser() %}
+
{{validationDatas.getNote()|nl2br}}
+ {% endif %}
+ {% endif %}
+
+
+ {% endfor %}
+
-
+
{% endfor %}
diff --git a/templates/web/prod/results/grid.html.twig b/templates/web/prod/results/grid.html.twig
index e797c96481..035cc1f182 100644
--- a/templates/web/prod/results/grid.html.twig
+++ b/templates/web/prod/results/grid.html.twig
@@ -1,4 +1,5 @@
{% include 'prod/results/record.html.twig' with {
'record': record,
- 'settings': settings
+ 'settings': settings,
+ 'plugins': plugins
} %}
diff --git a/templates/web/prod/results/list.html.twig b/templates/web/prod/results/list.html.twig
index ca45b67914..051622bb4d 100644
--- a/templates/web/prod/results/list.html.twig
+++ b/templates/web/prod/results/list.html.twig
@@ -7,7 +7,8 @@
{% include 'prod/results/record.html.twig' with {
'record': record,
- 'settings': settings
+ 'settings': settings,
+ 'plugins': plugins
} %}
diff --git a/templates/web/prod/results/record.html.twig b/templates/web/prod/results/record.html.twig
index f6e2d899c5..61088ea939 100644
--- a/templates/web/prod/results/record.html.twig
+++ b/templates/web/prod/results/record.html.twig
@@ -155,6 +155,29 @@
{% endif %}
{% endif %}
+
+ {# add plugins entries #}
+ {% for plugin in plugins.actionbar|default([]) %}
+ {% set menu = plugin.ActionBar['_context_']|default([]) %}
+ {% for k, action in menu %}
+ {% if plugin.isContextMenuOptionAvailable(k, record) %}
+
+ {% endif %}
+ {% endfor %}
+ {% endfor %}
+
diff --git a/templates/web/prod/results/records.html.twig b/templates/web/prod/results/records.html.twig
index 6b3dedc8cc..d64039a26c 100644
--- a/templates/web/prod/results/records.html.twig
+++ b/templates/web/prod/results/records.html.twig
@@ -31,7 +31,8 @@
'doctype_display': doctype_display,
'handle_dblclick' : true,
'show_context_menu': true
- }
+ },
+ 'plugins': plugins
} %}
{% endblock %}
{% endfor %}
diff --git a/templates/web/prod/toolbar.html.twig b/templates/web/prod/toolbar.html.twig
index 9f169906ea..68edc289c5 100644
--- a/templates/web/prod/toolbar.html.twig
+++ b/templates/web/prod/toolbar.html.twig
@@ -44,270 +44,159 @@
-
-
-
- {{ 'action : exporter' | trans }}
-
-
-
-
-
-
+ {% set menus = {
+ 'export': [
+ {
+ 'class':'TOOL_disktt_btn',
+ 'icon':'/assets/common/images/icons/disktt_history.png',
+ 'label':'action : exporter' | trans },
+ {
+ 'class':'TOOL_print_btn',
+ 'icon':'/assets/common/images/icons/print_history.png',
+ 'label':'action : print' | trans }
+ ],
+ 'edit': [],
+ 'push': [],
+ 'tools': [],
+ 'delete': []
+ } %}
- {% set actions = {} %}
+ {# menu "edit" #}
+ {% set m = [] %}
{% if acl.has_right(constant('\\ACL::CANMODIFRECORD')) %}
- {% set label %}
- {{ 'action : editer' | trans }}
- {% endset %}
- {% set actions = actions|merge( { 'edit' : {'icon': "/assets/common/images/icons/ppen_history.png", 'class':'TOOL_ppen_btn', 'label' : label} }) %}
- {% set label %}
- {{ 'prod::toolbar : video editor' | trans }}
- {% endset %}
- {% set actions = actions|merge( { 'video' : {'icon': "/assets/common/images/icons/icon-video-editor.png", 'class':'TOOL_videoeditor_btn', 'label' : label} }) %}
+ {% set m = m|merge([
+ {
+ 'class':'TOOL_ppen_btn',
+ 'icon':'/assets/common/images/icons/ppen_history.png',
+ 'label':'action : editer' | trans },
+ {
+ 'class':'TOOL_videoeditor_btn',
+ 'icon':'/assets/common/images/icons/icon-video-editor.png',
+ 'label':'prod::toolbar : video editor' | trans }
+ ]) %}
{% endif %}
- {% if acl.has_right(constant('\\ACL::CHGSTATUS')) %}
- {% set label %}
- {{ 'action : status' | trans }}
- {% endset %}
- {% set actions = actions|merge( { 'status' : {'icon': "/assets/common/images/icons/chgstatus_history.png", 'class':'TOOL_chgstatus_btn', 'label' : label} }) %}
+ {% if acl.has_right(constant('\\\ACL::CHGSTATUS')) %}
+ {% set m = m|merge([
+ {
+ 'class':'TOOL_chgstatus_btn',
+ 'icon':'/assets/common/images/icons/chgstatus_history.png',
+ 'label':'action : status' | trans }
+ ]) %}
{% endif %}
{% if acl.has_right(constant('\\ACL::CANDELETERECORD')) and acl.has_right(constant('\\ACL::CANADDRECORD')) %}
- {% set label %}
- {{ 'action : collection' | trans }}
- {% endset %}
- {% set actions = actions|merge( { 'move' : {'icon': "/assets/common/images/icons/chgcoll_history.png", 'class':'TOOL_chgcoll_btn', 'label' : label} }) %}
+ {% set m = m|merge([
+ {
+ 'class':'TOOL_chgcoll_btn',
+ 'icon':'/assets/common/images/icons/chgcoll_history.png',
+ 'label':'action : collection' | trans }
+ ]) %}
+ {% endif %}
+ {% set menus = menus|merge({'edit' : m}) %}
+
+ {# menu "push" #}
+ {% set m = [] %}
+ {% if acl.has_right(constant('\\ACL::CANPUSH')) %}
+ {% set m = m|merge([
+ {
+ 'class':'TOOL_pushdoc_btn',
+ 'icon':'/assets/common/images/icons/push16.png',
+ 'label':'action : push' | trans },
+ {
+ 'class':'TOOL_feedback_btn',
+ 'icon':'/assets/common/images/icons/feedback16.png',
+ 'label':'Feedback' | trans }
+ ]) %}
+ {% endif %}
+ {% if acl.has_right(constant('\\ACL::BAS_CHUPUB')) %}
+ {% set m = m|merge([
+ {
+ 'class':'TOOL_publish_btn',
+ 'icon':'/assets/common/images/icons/rss16.png',
+ 'label':'action : publier' | trans }
+ ]) %}
+ {% endif %}
+ {% set menus = menus|merge({'push' : m}) %}
+
+ {# menu "tools" #}
+ {% if acl.has_right(constant('\\ACL::IMGTOOLS')) %}
+ {% set menus = menus|merge({'tools' : [
+ {
+ 'class':'TOOL_imgtools_btn',
+ 'icon':'/assets/common/images/icons/imgtools_history.png',
+ 'label':'action : outils' | trans }
+ ]}) %}
{% endif %}
- {% set n_actions = actions|length %}
- {% if n_actions > 1 %}
-
-
- {% for action in actions %}
- {% if loop.first %}
-
- {{ action.label }}
-
- {% endif %}
- {% endfor %}
-
-
-
-
- {% elseif n_actions == 1 %}
-
-
- {% for action in actions %}
-
- {{ action.label }}
-
- {% endfor %}
-
-
+ {% set menus = menus|merge({(k) : m}) %}
+ {% endif %}
+ {% endfor %}
+ {% endfor %}
{% endif %}
- {% if acl.has_right(constant('\\ACL::CANPUSH')) and acl.has_right(constant('\\ACL::BAS_CHUPUB')) %}
-
-
-
- {{ 'action : push' | trans }}
-
-
-
-
-
- {% elseif acl.has_right(constant('\\ACL::CANPUSH')) %}
-
-
-
- {{ 'action : push' | trans }}
-
-
-
-
-
- {% elseif acl.has_right(constant('\\ACL::BAS_CHUPUB')) %}
-
-
- {#
#}
- {# {{ 'action : bridge' | trans }}#}
- {# #}
-
-
- {{ 'action : publier' | trans }}
-
-
- {% if plugins.actionbar is not empty %}
+ {# print #}
+ {% for menu_entries in menus %}
+ {% if menu_entries|length > 0 %}
+
+
+ {% set menu_entry = menu_entries[0] %}
+
+ {% set menu_entries = menu_entries|slice(1) %}
+ {% if menu_entries|length > 0 %}
-
- {% endif %}
-
-
- {% elseif plugins.actionbar is not empty %}
-
-
-
- {% endif %}
+
+
+ {% endif %}
+ {% endfor %}
- {% if acl.has_right(constant('\\ACL::IMGTOOLS')) %}
-
-
-
- {{ 'action : outils' | trans }}
-
-
-
- {% endif %}
- {% if acl.has_right(constant('\\ACL::CANDELETERECORD')) %}
-
-
-
- {{ 'action : supprimer' | trans }}
-
-
-
- {% endif %}
{% endblock %}
{% block toolbarJS %}
{% if plugins.actionbar is not empty %}
- {% for plugin in plugins.actionbar %}
-{{ (plugin.JS|default(''))|raw }}
- {% endfor %}
+ {% for pluginId, plugin in plugins.actionbar %}
+ {% if plugin.getActionBarTemplate is defined %}
+ {% set template = plugin.getActionBarTemplate() %}
+ {% if template %}
+ {% include template with {'app': app, 'plugin_id': pluginId, 'plugin': plugin} only %}
+ {% endif %}
+ {% endif %}
+ {% endfor %}
{% endif %}
{% endblock %}
\ No newline at end of file
diff --git a/yarn.lock b/yarn.lock
index 9519748dc9..ebc0ac35a3 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -3815,9 +3815,9 @@ fsevents@^1.0.0, fsevents@^1.1.2, fsevents@^1.2.7:
node-pre-gyp "^0.12.0"
fstream@^1.0.0, fstream@^1.0.2:
- version "1.0.11"
- resolved "https://registry.yarnpkg.com/fstream/-/fstream-1.0.11.tgz#5c1fb1f117477114f0632a0eb4b71b3cb0fd3171"
- integrity sha1-XB+x8RdHcRTwYyoOtLcbPLD9MXE=
+ version "1.0.12"
+ resolved "https://registry.yarnpkg.com/fstream/-/fstream-1.0.12.tgz#4e8ba8ee2d48be4f7d0de505455548eae5932045"
+ integrity sha512-WvJ193OHa0GHPEL+AycEJgxvBEwyfRkN1vhjca23OaPVMCaLCXTd5qAu82AjTcgP1UJmytkOKb63Ypde7raDIg==
dependencies:
graceful-fs "^4.1.2"
inherits "~2.0.0"
@@ -4049,7 +4049,7 @@ glob@^5.0.15:
once "^1.3.0"
path-is-absolute "^1.0.0"
-glob@^7.0.0, glob@^7.0.3, glob@^7.1.1, glob@^7.1.2, glob@^7.1.3, glob@~7.1.1:
+glob@^7.0.0, glob@^7.0.3, glob@^7.1.1, glob@^7.1.2, glob@~7.1.1:
version "7.1.4"
resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.4.tgz#aa608a2f6c577ad357e1ae5a5c26d9a8d1969255"
integrity sha512-hkLPepehmnKk41pUGm3sYxoFs/umurYfYJCerbXEyFIWcAzvpipAgVkBqqT9RBKMGjnq6kMuyYwha6csxbiM1A==
@@ -4061,6 +4061,18 @@ glob@^7.0.0, glob@^7.0.3, glob@^7.1.1, glob@^7.1.2, glob@^7.1.3, glob@~7.1.1:
once "^1.3.0"
path-is-absolute "^1.0.0"
+glob@^7.1.3:
+ version "7.1.6"
+ resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.6.tgz#141f33b81a7c2492e125594307480c46679278a6"
+ integrity sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA==
+ dependencies:
+ fs.realpath "^1.0.0"
+ inflight "^1.0.4"
+ inherits "2"
+ minimatch "^3.0.4"
+ once "^1.3.0"
+ path-is-absolute "^1.0.0"
+
glob@~3.1.21:
version "3.1.21"
resolved "https://registry.yarnpkg.com/glob/-/glob-3.1.21.tgz#d29e0a055dea5138f4d07ed40e8982e83c2066cd"
@@ -4166,10 +4178,10 @@ graceful-fs@^3.0.0:
dependencies:
natives "^1.1.0"
-graceful-fs@^4.1.11, graceful-fs@^4.1.15, graceful-fs@^4.1.2, graceful-fs@^4.1.6, graceful-fs@^4.1.9, graceful-fs@~4.1.4:
- version "4.1.15"
- resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.1.15.tgz#ffb703e1066e8a0eeaa4c8b80ba9253eeefbfb00"
- integrity sha512-6uHUhOPEBgQ24HM+r6b/QwWfZq+yiFcipKFrOFiBEnWdy5sdzYoi+pJeQaPI5qOLRFqWmAXUPQNsielzdLoecA==
+graceful-fs@^4.1.11, graceful-fs@^4.1.15, graceful-fs@^4.1.2, graceful-fs@^4.1.6, graceful-fs@^4.1.9:
+ version "4.2.3"
+ resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.3.tgz#4a12ff1b60376ef09862c2093edd908328be8423"
+ integrity sha512-a30VEBm4PEdx1dRB7MFK7BejejvCvBronbLjht+sHuGYj8PHs7M/5Z+rt5lw551vZ7yfTCj4Vuyy3mSJytDWRQ==
graceful-fs@~1.2.0:
version "1.2.3"
@@ -4181,6 +4193,11 @@ graceful-fs@~2.0.0:
resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-2.0.3.tgz#7cd2cdb228a4a3f36e95efa6cc142de7d1a136d0"
integrity sha1-fNLNsiiko/Nule+mzBQt59GhNtA=
+graceful-fs@~4.1.4:
+ version "4.1.15"
+ resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.1.15.tgz#ffb703e1066e8a0eeaa4c8b80ba9253eeefbfb00"
+ integrity sha512-6uHUhOPEBgQ24HM+r6b/QwWfZq+yiFcipKFrOFiBEnWdy5sdzYoi+pJeQaPI5qOLRFqWmAXUPQNsielzdLoecA==
+
"graceful-readlink@>= 1.0.0":
version "1.0.1"
resolved "https://registry.yarnpkg.com/graceful-readlink/-/graceful-readlink-1.0.1.tgz#4cafad76bc62f02fa039b2f94e9a3dd3a391a725"
@@ -4757,7 +4774,12 @@ inherits@1:
resolved "https://registry.yarnpkg.com/inherits/-/inherits-1.0.2.tgz#ca4309dadee6b54cc0b8d247e8d7c7a0975bdc9b"
integrity sha1-ykMJ2t7mtUzAuNJH6NfHoJdb3Js=
-inherits@2, inherits@2.0.3, inherits@^2.0.1, inherits@^2.0.3, inherits@~2.0.0, inherits@~2.0.1, inherits@~2.0.3:
+inherits@2, inherits@^2.0.1, inherits@^2.0.3, inherits@~2.0.0, inherits@~2.0.1, inherits@~2.0.3:
+ version "2.0.4"
+ resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.4.tgz#0fa2c64f932917c3433a0ded55363aae37416b7c"
+ integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==
+
+inherits@2.0.3:
version "2.0.3"
resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.3.tgz#633c2c83e3da42a502f52466022480f4208261de"
integrity sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=
@@ -6483,9 +6505,9 @@ mitt@^1.1.3:
integrity sha512-mUDCnVNsAi+eD6qA0HkRkwYczbLHJ49z17BGe2PYRhZL4wpZUFZGJHU7/5tmvohoma+Hdn0Vh/oJTiPEmgSruA==
mixin-deep@^1.2.0:
- version "1.3.1"
- resolved "https://registry.yarnpkg.com/mixin-deep/-/mixin-deep-1.3.1.tgz#a49e7268dce1a0d9698e45326c5626df3543d0fe"
- integrity sha512-8ZItLHeEgaqEvd5lYBXfm4EZSFCX29Jb9K+lAHhDKzReKBQKj3R+7NOF6tjqYi9t4oI8VUfaWITJQm86wnXGNQ==
+ version "1.3.2"
+ resolved "https://registry.yarnpkg.com/mixin-deep/-/mixin-deep-1.3.2.tgz#1120b43dc359a785dce65b55b82e257ccf479566"
+ integrity sha512-WRoDn//mXBiJ1H40rqa3vH0toePwSsGb45iInWlTySa+Uu4k3tYUSxa2v1KqAiLtvlrSzaExqS1gtk96A9zvEA==
dependencies:
for-in "^1.0.2"
is-extendable "^1.0.1"
@@ -7555,10 +7577,10 @@ phraseanet-common@^0.4.1:
js-cookie "^2.1.0"
pym.js "^1.3.1"
-phraseanet-production-client@0.34.77-d:
- version "0.34.77-d"
- resolved "https://registry.yarnpkg.com/phraseanet-production-client/-/phraseanet-production-client-0.34.77-d.tgz#5dfb4abf25a37b64b8bdf793cf4033ccff55e5ad"
- integrity sha512-+ak+Nx0zsvrzVgqc6s/sdVznDuGc2hRadxhISLmLPqCOw3CC1F+lCk5wG/TjhfYzFw1AKSszgLKqWj5ab7KPWQ==
+phraseanet-production-client@0.34.80-d:
+ version "0.34.80-d"
+ resolved "https://registry.yarnpkg.com/phraseanet-production-client/-/phraseanet-production-client-0.34.80-d.tgz#1e54bee4306ab11528377cb63c19d8c7491ef0f3"
+ integrity sha512-ilGs7ndDNztwlyeW9MA2TMiMhZC+P1/lNNeIsIuh+KuJH8M3Y3SWBcmsN2lqu5iM1Xg5FbWJ6iXcCSrLWHTqsw==
dependencies:
"@mapbox/mapbox-gl-language" "^0.9.2"
"@turf/turf" "^5.1.6"
@@ -8296,9 +8318,9 @@ right-align@^0.1.1:
align-text "^0.1.1"
rimraf@2, rimraf@^2.2.8, rimraf@^2.5.0, rimraf@^2.5.2, rimraf@^2.5.4, rimraf@^2.6.1, rimraf@^2.6.2, rimraf@^2.6.3:
- version "2.6.3"
- resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.6.3.tgz#b2d104fe0d8fb27cf9e0a1cda8262dd3833c6cab"
- integrity sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA==
+ version "2.7.1"
+ resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.7.1.tgz#35797f13a7fdadc566142c29d4f07ccad483e3ec"
+ integrity sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w==
dependencies:
glob "^7.1.3"