From 437c7c498ad6d167187c5a4394716bea844fdb86 Mon Sep 17 00:00:00 2001 From: Aleksandar Jovanov Date: Sat, 1 Jul 2017 16:15:30 +0200 Subject: [PATCH] [#3661] Fix issue upon creating new org/group through UI form --- ckan/templates/macros/form.html | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ckan/templates/macros/form.html b/ckan/templates/macros/form.html index 934e1c9ba93..f434a43c1a0 100644 --- a/ckan/templates/macros/form.html +++ b/ckan/templates/macros/form.html @@ -118,7 +118,7 @@ {% macro markdown(name, id='', label='', value='', placeholder='', error="", classes=[], attrs={}, is_required=false) %} {% set classes = (classes|list) %} {% do classes.append('control-full') %} - {% set markdown_tooltip = "

__Bold text__ or _italic text_

# title
## secondary title
### etc

* list
* of
* items

http://auto.link.ed/

Full markdown syntax

Please note: HTML tags are stripped out for security reasons

" %} + {% set markdown_tooltip = "

__Bold text__ or _italic text_

# title
## secondary title
### etc

* list
* of
* items

http://auto.link.ed/

Full markdown syntax

Please note: HTML tags are stripped out for security reasons

" %} {%- set extra_html = caller() if caller -%} {% call input_block(id or name, label or name, error, classes, control_classes=["editor"], extra_html=extra_html, is_required=is_required) %} @@ -406,14 +406,14 @@ #} {% macro image_upload(data, errors, field_url='image_url', field_upload='image_upload', field_clear='clear_upload', is_url=false, is_upload=false, is_upload_enabled=false, placeholder=false, - url_label='', upload_label='') %} + url_label='', upload_label='', field_name='image_url') %} {% set placeholder = placeholder if placeholder else _('http://example.com/my-image.jpg') %} {% set url_label = url_label or _('Image URL') %} {% set upload_label = upload_label or _('Image') %} {% if is_upload_enabled %}
+ data-module-field_url="{{ field_url }}" data-module-field_upload="{{ field_upload }}" data-module-field_clear="{{ field_clear }}" data-module-upload_label="{{ upload_label }}" data-module-field_name="{{ field_name }}"> {% endif %} {{ input(field_url, label=url_label, id='field-image-url', placeholder=placeholder, value=data.get(field_url), error=errors.get(field_url), classes=['control-full']) }}