mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2025-03-10 14:46:42 +08:00
Merge pull request #859 from Zanz2/p_succ_msg_SCI-1694
Protocols.io import success flash messagge [SCI-1694]
This commit is contained in:
commit
60da9d136c
4 changed files with 12 additions and 8 deletions
|
@ -28,10 +28,6 @@
|
|||
<strong><%= t('protocols.protocols_io_import.preview.guideln') %></strong>
|
||||
<%= sanitize_input(json_object['guidelines'].html_safe) %><br>
|
||||
<% end %>
|
||||
<% if json_object['link'].present? %>
|
||||
<strong><%= t('protocols.protocols_io_import.preview.p_link') %></strong>
|
||||
<%= sanitize_input(json_object['link'].html_safe) %><br>
|
||||
<% end %>
|
||||
<% if json_object['manuscript_citation'].present? %>
|
||||
<strong><%= t('protocols.protocols_io_import.preview.manu_cit') %></strong>
|
||||
<%= sanitize_input(json_object['manuscript_citation'].html_safe) %><br>
|
||||
|
@ -58,6 +54,10 @@
|
|||
<%= sanitize_input(tag['tag_name'])+' , ' %><br>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<% if json_object['link'].present? %>
|
||||
<strong><%= t('protocols.protocols_io_import.preview.p_link') %></strong>
|
||||
<%= sanitize_input(json_object['link'].html_safe) %><br>
|
||||
<% end %>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
@ -1,7 +1,8 @@
|
|||
|
||||
<% if @protocolsio_too_big %>
|
||||
alert('<%= I18n.t('my_modules.protocols.load_from_file_size_error',
|
||||
size: Constants::FILE_MAX_SIZE_MB ) %>');
|
||||
$('#modal-import-json-protocol').modal('hide');
|
||||
HelperModule.flashAlertMsg(' <%= t('my_modules.protocols.load_from_file_size_error',
|
||||
size: Constants::FILE_MAX_SIZE_MB ) %>','danger');
|
||||
<% else %>
|
||||
$('#modal-import-json-protocol').modal('hide');
|
||||
<% if remotipart_submitted? %> <%# a workaround to a bug with remotipart, that caused alot of headache, courtesy of github.com/dhampik %>
|
||||
|
|
|
@ -1,8 +1,10 @@
|
|||
<% if @protocolsio_general_error %>
|
||||
alert('<%= I18n.t('my_modules.protocols.load_from_file_protocol_general_error',
|
||||
$('#modal-import-json-protocol-preview').modal('hide');
|
||||
alert(' <%= t('my_modules.protocols.load_from_file_protocol_general_error',
|
||||
max: Constants::NAME_MAX_LENGTH, min: Constants::NAME_MIN_LENGTH) %>');
|
||||
<% else %>
|
||||
$('#modal-import-json-protocol-preview').modal('hide');
|
||||
$('#protocols_io_form').trigger("reset");
|
||||
protocolsDatatable.ajax.reload();
|
||||
HelperModule.flashAlertMsg(' <%= t('protocols.index.import_results.message_ok_pio')%>', 'success');
|
||||
<% end %>
|
||||
|
|
|
@ -1385,7 +1385,7 @@ en:
|
|||
b_s_p: "Before starting protocol information:"
|
||||
warn: "Protocol warning:"
|
||||
guideln: "Guidelines:"
|
||||
p_link: "Supplied link:"
|
||||
p_link: "Link:"
|
||||
s_nobr_link: "Link:"
|
||||
s_link: "Link:"
|
||||
s_desc: "Description:"
|
||||
|
@ -1555,6 +1555,7 @@ en:
|
|||
title: "Import results"
|
||||
message_failed: "Failed to import %{nr} protocol/s."
|
||||
message_ok: "Successfully imported %{nr} protocol/s."
|
||||
message_ok_pio: "Successfully imported protocol from protocols.io file."
|
||||
row_success: "Imported"
|
||||
row_renamed: "Imported & renamed"
|
||||
row_failed: "Failed"
|
||||
|
|
Loading…
Reference in a new issue