Project

General

Profile

Actions

Patch #24062

closed

Allow only vertical reorderingin sortable lists

Added by Vincent Robert over 7 years ago. Updated over 7 years ago.

Status:
Closed
Priority:
Normal
Category:
UI
Target version:
Start date:
Due date:
% Done:

0%

Estimated time:

Description

Here is a patch which allows only vertical reordering for positioned items:

From: Vincent Robert <vincent.robert@nanego.com>
Date: Thu, 13 Oct 2016 12:04:01 +0200
Subject: Vertical reordering only

---
 public/javascripts/application.js | 1 +
 1 file changed, 1 insertion(+)

diff --git a/public/javascripts/application.js b/public/javascripts/application.js
index 087d3de..b303702 100644
--- a/public/javascripts/application.js
+++ b/public/javascripts/application.js
@@ -597,6 +597,7 @@ function beforeShowDatePicker(input, inst) {
     }, options );

     return this.sortable($.extend({
+      axis: 'y',
       handle: ".sort-handle",
       helper: function(event, ui){
         ui.children('td').each(function(){
--

Thank you for considering this tiny contribution ;)


Files

patch.diff (727 Bytes) patch.diff Vincent Robert, 2016-10-13 12:12

Related issues

Related to Redmine - Feature #12909: Drag'n'drop order configuration for statuses, trackers, roles...ClosedJean-Philippe Lang

Actions
Actions

Also available in: Atom PDF