Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit a5e3484

Browse files
committed
update gridstack.js
1 parent b9129fb commit a5e3484

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

gridstack.js

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -645,6 +645,16 @@
645645
return this;
646646
};
647647

648+
GridStack.prototype.disable = function () {
649+
this.movable(this.container.find('.' + this.opts.item_class), false);
650+
this.resizable(this.container.find('.' + this.opts.item_class), false);
651+
};
652+
653+
GridStack.prototype.enable = function () {
654+
this.movable(this.container.find('.' + this.opts.item_class), true);
655+
this.resizable(this.container.find('.' + this.opts.item_class), true);
656+
};
657+
648658
GridStack.prototype.locked = function (el, val) {
649659
el = $(el);
650660
el.each(function (index, el) {

0 commit comments

Comments
 (0)