Skip to content
Snippets Groups Projects
Commit dde77732 authored by Thorge Petersen's avatar Thorge Petersen
Browse files

Fixed key generation for organization extras

parent 6a095863
No related branches found
No related tags found
1 merge request!50Upgraded to CKAN 2.10
...@@ -47,8 +47,8 @@ ...@@ -47,8 +47,8 @@
{{ form.input_address('gnd','GND URI', value=extras.gnd, index=6, placeholder='https://d-nb.info/gnd/1136109587', type='text', attrs={}) }} {{ form.input_address('gnd','GND URI', value=extras.gnd, index=6, placeholder='https://d-nb.info/gnd/1136109587', type='text', attrs={}) }}
<!-- {% for extra in data.extras %}
{% set custom_extras = ['person','street','location','telephone','mail','web','gnd'] %} {% set custom_extras = ['person','street','location','telephone','mail','web','gnd'] %}
{% for extra in data.extras %}
{% if extra.key not in custom_extras %} {% if extra.key not in custom_extras %}
{% set prefix = 'extras__%d__' % (loop.index0 + (custom_extras|count)) %} {% set prefix = 'extras__%d__' % (loop.index0 + (custom_extras|count)) %}
{{ form.custom( {{ form.custom(
...@@ -76,7 +76,7 @@ ...@@ -76,7 +76,7 @@
values=(extra.key, extra.value, extra.deleted), values=(extra.key, extra.value, extra.deleted),
error=errors[prefix ~ 'key'] or errors[prefix ~ 'value'] error=errors[prefix ~ 'key'] or errors[prefix ~ 'value']
) }} ) }}
{% endfor %} --> {% endfor %}
</div> </div>
{% endblock %} {% endblock %}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment