IDEMPIERE-4413:Change Role, disfunction all keyboard shortcuts (#216)

remove keydown handle at client side
This commit is contained in:
hieplq 2020-08-20 13:47:01 +07:00 committed by GitHub
parent 7892c54aa1
commit 23ed373e5d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 14 additions and 3 deletions

View File

@ -45,12 +45,23 @@ zkforge.KeyListener = zk.$extends(zul.Widget, {
var self = this; var self = this;
jq(document).ready(function () { jq(document).ready(function () {
jq(document).keydown(function (evt) { jq(document).keydown(self, self.keyDownHandle);
self.keyDown(evt);
});
}); });
}, },
unbind_: function (skipper, after) {
this.$supers('unbind_', arguments);
var self = this;
jq(document).off("keydown", self.keyDownHandle);
},
keyDownHandle: function(evt){
var self = evt.data;
self.keyDown(evt);
},
keyDown: function(evt) { keyDown: function(evt) {
if (!evt) evt = window.event; if (!evt) evt = window.event;