From c0cfe3f320775bb3e572da24662a1580266221ca Mon Sep 17 00:00:00 2001 From: Ralf Becker Date: Thu, 12 Jun 2014 14:22:39 +0000 Subject: [PATCH] readonlys was not namespaced in old eTemplate, therefore if we dont find data under current namespace, we look into parent (if there is anything namespaced, we will NOT look for parent!) --- etemplate/js/et2_core_arrayMgr.js | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/etemplate/js/et2_core_arrayMgr.js b/etemplate/js/et2_core_arrayMgr.js index 45c7371d22..5747892ed6 100644 --- a/etemplate/js/et2_core_arrayMgr.js +++ b/etemplate/js/et2_core_arrayMgr.js @@ -406,8 +406,15 @@ var et2_readonlysArrayMgr = et2_arrayMgr.extend( { _id = this.expandName(_id); } - entry = this.getEntry(_id); - + // readonlys was not namespaced in old eTemplate, therefore if we dont find data + // under current namespace, we look into parent + // (if there is anything namespaced, we will NOT look for parent!) + var mgr = this; + while (mgr.parentMgr && jQuery.isEmptyObject(mgr.data)) + { + mgr = mgr.parentMgr; + } + entry = mgr.getEntry(_id); } // Let the array entry override the read only attribute entry