Phase 3: fixed template form editor
This commit is contained in:
@@ -177,7 +177,7 @@ def form_editor(template_id):
|
|||||||
return render_template(
|
return render_template(
|
||||||
'templates/form_editor.html',
|
'templates/form_editor.html',
|
||||||
template=template,
|
template=template,
|
||||||
form_schema_json=json.dumps(form_schema)
|
form_schema=form_schema # pass the list — tojson handles encoding in the template
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -389,7 +389,7 @@
|
|||||||
This avoids using |safe which bypasses Jinja2 auto-escaping and could allow
|
This avoids using |safe which bypasses Jinja2 auto-escaping and could allow
|
||||||
stored XSS if the sanitiser ever lets a malicious value through. #}
|
stored XSS if the sanitiser ever lets a malicious value through. #}
|
||||||
<div id="schema-data"
|
<div id="schema-data"
|
||||||
data-schema="{{ form_schema_json | tojson }}"
|
data-schema="{{ form_schema | tojson }}"
|
||||||
style="display:none;"></div>
|
style="display:none;"></div>
|
||||||
|
|
||||||
<!-- PROPERTIES -->
|
<!-- PROPERTIES -->
|
||||||
|
|||||||
Reference in New Issue
Block a user