mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2025-10-10 05:46:47 +08:00
Merge pull request #1776 from okriuchykhin/ok_SCI_3477
Fix protocol metadata editing in repository [SCI-3477]
This commit is contained in:
commit
df59c54bd4
2 changed files with 4 additions and 4 deletions
|
@ -179,7 +179,7 @@ class ProtocolsController < ApplicationController
|
||||||
partial: 'protocols/header/authors_label.html.erb'
|
partial: 'protocols/header/authors_label.html.erb'
|
||||||
),
|
),
|
||||||
description_label: render_to_string(
|
description_label: render_to_string(
|
||||||
partial: 'protocols/header/description_label.html.erb'
|
partial: 'protocols/header/description_label.html.erb', locals: { edit_mode: true }
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
<% if can_manage_protocol_in_repository?(@protocol) && edit_mode %>
|
<% if can_manage_protocol_in_repository?(@protocol) && edit_mode %>
|
||||||
<%= render partial: "my_modules/protocols/protocol_description_form", locals:
|
<%= render partial: "my_modules/protocols/protocol_description_form.html.erb", locals:
|
||||||
{
|
{
|
||||||
protocol: @protocol,
|
protocol: @protocol,
|
||||||
update_url: description_protocol_path(@protocol, format: :json)
|
update_url: description_protocol_path(@protocol, format: :json)
|
||||||
}
|
}
|
||||||
%>
|
%>
|
||||||
<% elsif @protocol.description.present? %>
|
<% elsif @protocol.description.present? %>
|
||||||
<%= custom_auto_link(@protocol.tinymce_render(:description),
|
<%= custom_auto_link(@protocol.tinymce_render(:description),
|
||||||
|
@ -12,4 +12,4 @@
|
||||||
team: current_team) %>
|
team: current_team) %>
|
||||||
<% else %>
|
<% else %>
|
||||||
<span style="font-size: 16px"><%= t('my_modules.protocols.protocol_status_bar.no_description') %></span>
|
<span style="font-size: 16px"><%= t('my_modules.protocols.protocol_status_bar.no_description') %></span>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
Loading…
Add table
Reference in a new issue