12
I’m using Django 1.4 with path (L10N) enabled, which causes the numeric values in the template to be formatted: 1.234,56. The problem is that every time I put one ID in the template, for example:
data-id="{{ form.instance.id }}"
It is rendered as:
data-id="1.234"
Obviously if that ID goes to a request ajax, the ID is not found at the base because it is not a value int valid. I I can avoid this behavior using |safe or |unlocalize, but in some places, for example in admin, i do not have this access (would be necessary to change Django), for example:
<a href="{% url opts|admin_urlname:'changelist' %}{{ original.pk }}">{{ original|truncatewords:"18" }}</a>
It is possible to make Django not find Ids in a generalized way?
You can use custom templates for the admin without editing Django’s admin APP.
– Iberê