var _this = this;
var el = document.getElementById('rootChildDeparts');
_this.rootDepart.sortableObj = Sortable.create(el);
_this.rootDepart.sortableObj.destroy(); //销毁排序
_this.rootDepart.sortableObj.cancel(); //网上说取消排序是这样,但是我试了试没效果
var _this = this;
var el = document.getElementById('rootChildDeparts');
_this.rootDepart.sortableObj = Sortable.create(el);
_this.rootDepart.sortableObj.destroy(); //销毁排序
_this.rootDepart.sortableObj.cancel(); //网上说取消排序是这样,但是我试了试没效果
this.sortAble = Sortable.create(el)
this.sortAble.option('disabled', true) 这样可以禁止拖拽
10 回答11.7k 阅读
2 回答3.2k 阅读✓ 已解决
4 回答2.2k 阅读✓ 已解决
3 回答1.2k 阅读✓ 已解决
3 回答877 阅读✓ 已解决
3 回答1k 阅读✓ 已解决
2 回答1.2k 阅读✓ 已解决
使用 toArray() 和 sort()