From 6fe2ec6c659c079d7f459a26ba10789af7d20d24 Mon Sep 17 00:00:00 2001 From: nathan Date: Fri, 3 Sep 2021 14:53:51 -0600 Subject: [PATCH] Fix readonly was not hiding buttons in Lion, they already have functionality on readOnly --- api/js/etemplate/Et2Widget/Et2Widget.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/api/js/etemplate/Et2Widget/Et2Widget.ts b/api/js/etemplate/Et2Widget/Et2Widget.ts index 9af8447135..9a2f01d689 100644 --- a/api/js/etemplate/Et2Widget/Et2Widget.ts +++ b/api/js/etemplate/Et2Widget/Et2Widget.ts @@ -77,7 +77,7 @@ const Et2WidgetMixin = (superClass) => * Due to how WebComponents work, this might not change anything inside the component. */ class: {type: String, reflect: true}, - + /** * Defines whether this widget is visible. * Not to be confused with an input widget's HTML attribute 'disabled'.", @@ -918,7 +918,7 @@ export function loadWebComponent(_nodeName : string, _template_node, parent : Et var mgr = widget.getArrayMgr("content"); // Set read-only. Doesn't really matter if it's a ro widget, but otherwise it needs set - widget.readonly = parent.getArrayMgr("readonlys") ? + widget.readOnly = parent.getArrayMgr("readonlys") ? (parent.getArrayMgr("readonlys")).isReadOnly( _template_node.getAttribute("id"), _template_node.getAttribute("readonly"), typeof parent.readonly !== "undefined" ? parent.readonly : false) : false;