diff options
Diffstat (limited to 'templates/config/form_display/display.twig')
-rw-r--r-- | templates/config/form_display/display.twig | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/templates/config/form_display/display.twig b/templates/config/form_display/display.twig index d68259584d..9d427e7d1b 100644 --- a/templates/config/form_display/display.twig +++ b/templates/config/form_display/display.twig @@ -26,7 +26,7 @@ <fieldset class="optbox"> <legend>{{ form.descriptions.name }}</legend> - {# This must match with displayErrors() in scripts.js #} + {# This must match with window.Config.displayErrors() in scripts.js #} {% if form.errors is iterable and form.errors|length > 0 %} <dl class="errors"> {% for error in form.errors %} @@ -54,10 +54,10 @@ </form> <script type="text/javascript"> - if (typeof configInlineParams === 'undefined' || !Array.isArray(configInlineParams)) { - configInlineParams = []; + if (typeof window.configInlineParams === 'undefined' || !Array.isArray(window.configInlineParams)) { + window.configInlineParams = []; } - configInlineParams.push(function () { + window.configInlineParams.push(function () { {{ js_array|join(';\n')|raw }}; $.extend(Messages, { @@ -68,11 +68,11 @@ 'error_value_lte': '{{ 'Value must be less than or equal to %s!'|trans|e('js') }}', }); - $.extend(defaultValues, { + $.extend(window.defaultValues, { {{ js_default|join(",\n ")|raw }} }); }); - if (typeof configScriptLoaded !== 'undefined' && configInlineParams) { - loadInlineConfig(); + if (typeof window.configScriptLoaded !== 'undefined' && window.configInlineParams) { + window.Config.loadInlineConfig(); } </script> |