mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2025-10-07 20:40:26 +08:00
Merge pull request #2226 from aignatov-bio/ai-sci-4086-fix-team-name-after-update
Fix name update and path to team [SCI-4086]
This commit is contained in:
commit
993424d08e
3 changed files with 5 additions and 3 deletions
|
@ -191,7 +191,9 @@
|
||||||
.on('inlineEditing:fieldUpdated', '.inline-editing-container', function() {
|
.on('inlineEditing:fieldUpdated', '.inline-editing-container', function() {
|
||||||
var newName = $(this).find('.view-mode').html();
|
var newName = $(this).find('.view-mode').html();
|
||||||
$('.breadcrumb-teams .active').html(newName);
|
$('.breadcrumb-teams .active').html(newName);
|
||||||
$('#team-switch .selected-team').html(newName);
|
if ($('.settings-team-name').data('current-team')) {
|
||||||
|
$('#team-switch .selected-team').html(newName);
|
||||||
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -64,7 +64,7 @@ module Users
|
||||||
)
|
)
|
||||||
|
|
||||||
# Redirect to new team page
|
# Redirect to new team page
|
||||||
redirect_to action: :show, id: @new_team.id
|
redirect_to team_path(@new_team)
|
||||||
else
|
else
|
||||||
render :new
|
render :new
|
||||||
end
|
end
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
<%= render partial: "users/settings/teams/breadcrumbs.html.erb" %>
|
<%= render partial: "users/settings/teams/breadcrumbs.html.erb" %>
|
||||||
|
|
||||||
<!-- TITLE -->
|
<!-- TITLE -->
|
||||||
<div id="team-name" class="settings-team-name">
|
<div id="team-name" class="settings-team-name" data-current-team="<%= current_team == @team %>">
|
||||||
<% if can_update_team?(@team) %>
|
<% if can_update_team?(@team) %>
|
||||||
<%= render partial: "shared/inline_editing",
|
<%= render partial: "shared/inline_editing",
|
||||||
locals: {
|
locals: {
|
||||||
|
|
Loading…
Add table
Reference in a new issue