'Save PDF to inventory' uppercase word in the button & double modal [SCI-8496]

This commit is contained in:
Giga Chubinidze 2023-05-23 22:21:34 +04:00
parent bfc4ebe237
commit d43f10bc6a
2 changed files with 10 additions and 8 deletions

View file

@ -317,12 +317,14 @@
let url = row.attr('data-save-to-inventory-path');
$.get(url, function(result) {
let modal = $(result.html);
if ($('#content-reports-index').find('.modal').length === 0) {
$('#content-reports-index').append(modal);
modal.modal('show');
// Remove modal when it gets closed
modal.on('hidden.bs.modal', function() {
$(this).remove();
});
}
});
});
}

View file

@ -59,7 +59,7 @@ module Toolbars
label: I18n.t('projects.reports.index.save_pdf_to_inventory'),
icon: 'fas fa-save',
button_id: 'savePdfToInventoryButton',
type: 'remote-modal'
path: save_pdf_to_inventory_modal_report_path(@report.id)
}
end