Fix sort handle on "My page".

git-svn-id: http://svn.redmine.org/redmine/trunk@16389 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang
2017-03-11 13:07:38 +00:00
parent 373b3c283f
commit b91489ce6b
2 changed files with 2 additions and 1 deletions

View File

@@ -26,7 +26,7 @@ module MyHelper
blocks.each do |block| blocks.each do |block|
content = render_block_content(block, user) content = render_block_content(block, user)
if content.present? if content.present?
handle = content_tag('span', '', :class => 'hanlde sort-handle') handle = content_tag('span', '', :class => 'sort-handle')
close = link_to(l(:button_delete), {:action => "remove_block", :block => block}, :method => 'post', :class => "icon-only icon-close") close = link_to(l(:button_delete), {:action => "remove_block", :block => block}, :method => 'post', :class => "icon-only icon-close")
content = content_tag('div', handle + close, :class => 'contextual') + content content = content_tag('div', handle + close, :class => 'contextual') + content

View File

@@ -28,6 +28,7 @@ $(document).ready(function(){
$('#list-top, #list-left, #list-right').sortable({ $('#list-top, #list-left, #list-right').sortable({
connectWith: '.block-receiver', connectWith: '.block-receiver',
tolerance: 'pointer', tolerance: 'pointer',
handle: '.sort-handle',
start: function(event, ui){$(this).parent().addClass('dragging');}, start: function(event, ui){$(this).parent().addClass('dragging');},
stop: function(event, ui){$(this).parent().removeClass('dragging');}, stop: function(event, ui){$(this).parent().removeClass('dragging');},
update: function(event, ui){ update: function(event, ui){