mirror of
https://github.com/WordPress/WordPress.git
synced 2025-02-17 03:56:07 +00:00
Allow a sortable options hash to be passed in, so you can override the defaults. props koopersmith. see #22696
git-svn-id: http://core.svn.wordpress.org/trunk@23064 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
4676fb1eda
commit
b6982a0804
@ -3186,7 +3186,7 @@
|
||||
if ( ! this.options.sortable || ! $.fn.sortable )
|
||||
return;
|
||||
|
||||
this.$el.sortable({
|
||||
this.$el.sortable( _.extend({
|
||||
// If the `collection` has a `comparator`, disable sorting.
|
||||
disabled: !! collection.comparator,
|
||||
|
||||
@ -3231,7 +3231,7 @@
|
||||
// update the menu order.
|
||||
collection.saveMenuOrder();
|
||||
}
|
||||
});
|
||||
}, this.options.sortable ) );
|
||||
|
||||
// If the `orderby` property is changed on the `collection`,
|
||||
// check to see if we have a `comparator`. If so, disable sorting.
|
||||
|
Loading…
x
Reference in New Issue
Block a user