pull/104/head
cagataycivici 2019-10-28 22:57:03 +03:00
parent 0bf443fc8e
commit eb0bb33f8a
1 changed files with 8 additions and 7 deletions

View File

@ -81,13 +81,6 @@ export default {
toggleRowWithCheckbox(event) { toggleRowWithCheckbox(event) {
this.$emit('checkbox-change', event); this.$emit('checkbox-change', event);
}, },
onClick() {
if (this.isEditable() && !this.editing) {
this.editing = true;
this.bindDocumentEditListener();
}
},
isEditable() { isEditable() {
return this.column.$scopedSlots.editor != null; return this.column.$scopedSlots.editor != null;
}, },
@ -115,7 +108,15 @@ export default {
isOutsideClicked(event) { isOutsideClicked(event) {
return !this.$el.contains(event.target) && !this.$el.isSameNode(event.target); return !this.$el.contains(event.target) && !this.$el.isSameNode(event.target);
}, },
onClick() {
if (this.isEditable() && !this.editing) {
this.editing = true;
this.bindDocumentEditListener();
}
},
onKeyDown(event) { onKeyDown(event) {
//tab, enter or escape
if (event.which === 13 || event.which === 9 || event.which === 27) { if (event.which === 13 || event.which === 9 || event.which === 27) {
this.switchCellToViewMode(); this.switchCellToViewMode();
} }