[FIX] #921 Fixed issue when discard a modal with draggable element

pull/3042/head
Quentin THEURET 2018-05-15 20:42:14 +02:00 committed by jguerriat
parent 93453902a8
commit 782c50e228
2 changed files with 6 additions and 4 deletions

View File

@ -15,7 +15,7 @@
"Odoo Community Association (OCA)", "Odoo Community Association (OCA)",
'website': "http://acsone.eu", 'website': "http://acsone.eu",
'category': 'web', 'category': 'web',
'version': '11.0.1.0.1', 'version': '11.0.1.0.2',
'license': 'AGPL-3', 'license': 'AGPL-3',
'depends': [ 'depends': [
'web', 'web',

View File

@ -37,10 +37,12 @@ Dialog.include({
}, },
close: function() { close: function() {
if (this.$modal) {
var draggable = this.$modal.draggable("instance"); var draggable = this.$modal.draggable("instance");
if (draggable) { if (draggable) {
this.$modal.draggable("destroy"); this.$modal.draggable("destroy");
} }
}
return this._super.apply(this, arguments); return this._super.apply(this, arguments);
}, },