diff --git a/front/core/components/td-editable/index.js b/front/core/components/td-editable/index.js index a6be8b9b8..780e6160c 100644 --- a/front/core/components/td-editable/index.js +++ b/front/core/components/td-editable/index.js @@ -11,7 +11,8 @@ export default class Controller extends Component { element.tabIndex = 0; element.addEventListener('focus', () => { - if (this.field) return; + if (this.field || this.disabled) return; + $transclude((tClone, tScope) => { this.field = tClone; this.tScope = tScope; @@ -26,7 +27,7 @@ export default class Controller extends Component { }); element.addEventListener('focusout', event => { - this.destroyTimer(); + if (this.field || this.disabled) return; this.lastEvent = event; let target = event.relatedTarget; while (target && target != element) @@ -57,6 +58,9 @@ Controller.$inject = ['$element', '$scope', '$transclude', '$timeout']; ngModule.component('vnTdEditable', { template: require('./index.html'), controller: Controller, + bindings: { + disabled: ' .text { visibility: hidden; }