Use the thing with data- now used elsewhere

This commit is contained in:
Alexandre Aubin 2019-10-18 21:04:06 +02:00
parent b7a8edb352
commit 7ac8f61cdb
2 changed files with 2 additions and 2 deletions

View file

@ -140,7 +140,7 @@
"locale": y18n.locale
}, function() {
// Configure behavior for the button to share log on Yunohost (it calls display --share)
$("#share-with-yunopaste").on("click", function() {
$('button[data-action="share"]').on("click", function() {
c.api('GET', '/logs/display?path='+$(this).data('log-id')+'&share', {},
function(data) {
$('div.loader').remove();

View file

@ -10,7 +10,7 @@
</div>
<div class="actions-group">
<button id="share-with-yunopaste" class="btn btn-success" data-log-id="{{#if log.name}}{{ log.name }}{{else}}{{ log.log_path }}{{/if}}">
<button class="btn btn-success" data-action="share" data-log-id="{{#if log.name}}{{ log.name }}{{else}}{{ log.log_path }}{{/if}}">
<span class="fa-cloud-upload"></span> {{t 'logs_share_with_yunopaste'}}
</button>
</div>