Skip to content

Commit 4e00713

Browse files
committed
Merge branch 'django1.7' of github.com:sshwsfc/django-xadmin into django1.7
2 parents 91e2907 + 9440e16 commit 4e00713

File tree

52 files changed

+88
-72
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

52 files changed

+88
-72
lines changed

demo_app/app/adminx.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ class MaintainInline(object):
4343

4444

4545
class IDCAdmin(object):
46-
list_display = ('name', 'description', 'create_time','host__name')
46+
list_display = ('name', 'description', 'create_time')
4747
list_display_links = ('name',)
4848
wizard_form_list = [
4949
('First\'s Form', ('name', 'description')),

demo_app/app/tests.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
from django.test import TestCase
2+
3+
# Create your tests here.

demo_app/data.db

-332 KB
Binary file not shown.

demo_app/demo/urls.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,11 @@
22

33
# Uncomment the next two lines to enable the admin:
44
import xadmin
5-
xadmin.autodiscover()
65

76
# from xadmin.plugins import xversion
87
# xversion.register_models()
98

109
from django.contrib import admin
11-
admin.autodiscover()
1210

1311
urlpatterns = patterns('',
1412
url(r'^admin/', include(admin.site.urls)),

requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
django>=1.5
1+
django>=1.7
22
django-crispy-forms>=1.4.0

xadmin/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,3 +65,5 @@ def autodiscover():
6565
# attempting to import it, otherwise we want it to bubble up.
6666
if module_has_submodule(mod, 'adminx'):
6767
raise
68+
69+
default_app_config = 'xadmin.apps.XAdminConfig'

xadmin/apps.py

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
from django.apps import AppConfig
2+
from django.core import checks
3+
from django.utils.translation import ugettext_lazy as _
4+
5+
6+
class XAdminConfig(AppConfig):
7+
"""Simple AppConfig which does not do automatic discovery."""
8+
9+
name = 'xadmin'
10+
verbose_name = _("Administration")
11+
12+
def ready(self):
13+
self.module.autodiscover()

xadmin/filters.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -333,7 +333,7 @@ def __init__(self, field, request, params, model, model_admin, field_path):
333333
self.lookup_title = other_model._meta.verbose_name
334334
self.title = self.lookup_title
335335
self.search_url = model_admin.get_admin_url('%s_%s_changelist' % (
336-
other_model._meta.app_label, other_model._meta.module_name))
336+
other_model._meta.app_label, other_model._meta.model_name))
337337
self.label = self.label_for_value(other_model, rel_name, self.lookup_exact_val) if self.lookup_exact_val else ""
338338
self.choices = '?'
339339
if field.rel.limit_choices_to:
-2 Bytes
Binary file not shown.

xadmin/locale/de_DE/LC_MESSAGES/django.po

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -742,8 +742,8 @@ msgstr "Klicken Sie hier, um alle Objekte über alle Seiten hinweg auszuwählen.
742742

743743
#: templates/xadmin/blocks/model_list.results_bottom.actions.html:19
744744
#, python-format
745-
msgid "Select all %(total_count)s %(module_name)s"
746-
msgstr "Alles auswählen %(total_count)s %(module_name)s"
745+
msgid "Select all %(total_count)s %(model_name)s"
746+
msgstr "Alles auswählen %(total_count)s %(model_name)s"
747747

748748
#: templates/xadmin/blocks/model_list.results_bottom.actions.html:20
749749
msgid "Clear selection"

xadmin/locale/en/LC_MESSAGES/django.po

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -738,7 +738,7 @@ msgstr ""
738738

739739
#: templates/xadmin/blocks/model_list.results_bottom.actions.html:19
740740
#, python-format
741-
msgid "Select all %(total_count)s %(module_name)s"
741+
msgid "Select all %(total_count)s %(model_name)s"
742742
msgstr ""
743743

744744
#: templates/xadmin/blocks/model_list.results_bottom.actions.html:20
-2 Bytes
Binary file not shown.

xadmin/locale/es_MX/LC_MESSAGES/django.po

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -754,8 +754,8 @@ msgstr "Haz clic aquí para seleccionar los objetos a través de todas las pági
754754

755755
#: templates/xadmin/blocks/model_list.results_bottom.actions.html:19
756756
#, python-format
757-
msgid "Select all %(total_count)s %(module_name)s"
758-
msgstr "Seleccionar todo %(total_count)s %(module_name)s"
757+
msgid "Select all %(total_count)s %(model_name)s"
758+
msgstr "Seleccionar todo %(total_count)s %(model_name)s"
759759

760760
#: templates/xadmin/blocks/model_list.results_bottom.actions.html:20
761761
msgid "Clear selection"
-2 Bytes
Binary file not shown.

xadmin/locale/eu/LC_MESSAGES/django.po

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -740,8 +740,8 @@ msgstr "Klikatu hemen orrialde guztiko objetuak aukeratzeko"
740740

741741
#: templates/xadmin/blocks/model_list.results_bottom.actions.html:19
742742
#, python-format
743-
msgid "Select all %(total_count)s %(module_name)s"
744-
msgstr "Aukeratu %(total_count)s %(module_name)sak"
743+
msgid "Select all %(total_count)s %(model_name)s"
744+
msgstr "Aukeratu %(total_count)s %(model_name)sak"
745745

746746
#: templates/xadmin/blocks/model_list.results_bottom.actions.html:20
747747
msgid "Clear selection"

xadmin/locale/id_ID/LC_MESSAGES/django.po

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -730,7 +730,7 @@ msgstr ""
730730

731731
#: templates/xadmin/blocks/model_list.results_bottom.actions.html:19
732732
#, python-format
733-
msgid "Select all %(total_count)s %(module_name)s"
733+
msgid "Select all %(total_count)s %(model_name)s"
734734
msgstr ""
735735

736736
#: templates/xadmin/blocks/model_list.results_bottom.actions.html:20

xadmin/locale/ja/LC_MESSAGES/django.po

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -730,7 +730,7 @@ msgstr ""
730730

731731
#: templates/xadmin/blocks/model_list.results_bottom.actions.html:19
732732
#, python-format
733-
msgid "Select all %(total_count)s %(module_name)s"
733+
msgid "Select all %(total_count)s %(model_name)s"
734734
msgstr ""
735735

736736
#: templates/xadmin/blocks/model_list.results_bottom.actions.html:20

xadmin/locale/lt/LC_MESSAGES/django.po

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -742,7 +742,7 @@ msgstr ""
742742

743743
#: templates/xadmin/blocks/model_list.results_bottom.actions.html:19
744744
#, python-format
745-
msgid "Select all %(total_count)s %(module_name)s"
745+
msgid "Select all %(total_count)s %(model_name)s"
746746
msgstr ""
747747

748748
#: templates/xadmin/blocks/model_list.results_bottom.actions.html:20

xadmin/locale/nl_NL/LC_MESSAGES/django.po

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -736,7 +736,7 @@ msgstr ""
736736

737737
#: templates/xadmin/blocks/model_list.results_bottom.actions.html:19
738738
#, python-format
739-
msgid "Select all %(total_count)s %(module_name)s"
739+
msgid "Select all %(total_count)s %(model_name)s"
740740
msgstr ""
741741

742742
#: templates/xadmin/blocks/model_list.results_bottom.actions.html:20
-2 Bytes
Binary file not shown.

xadmin/locale/pl/LC_MESSAGES/django.po

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -792,8 +792,8 @@ msgstr "Kliknij tutaj, aby wybrać wszystkie obiekty na wszystkich stronach"
792792

793793
#: templates/xadmin/blocks/model_list.results_bottom.actions.html:19
794794
#, python-format
795-
msgid "Select all %(total_count)s %(module_name)s"
796-
msgstr "Wybierz wszystkie %(total_count)s %(module_name)s"
795+
msgid "Select all %(total_count)s %(model_name)s"
796+
msgstr "Wybierz wszystkie %(total_count)s %(model_name)s"
797797

798798
#: templates/xadmin/blocks/model_list.results_bottom.actions.html:20
799799
msgid "Clear selection"
-2 Bytes
Binary file not shown.

xadmin/locale/pt_BR/LC_MESSAGES/django.po

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -743,8 +743,8 @@ msgstr "Clique aqui para selecionar os objetos através de todas as páginas"
743743

744744
#: templates/xadmin/blocks/model_list.results_bottom.actions.html:19
745745
#, python-format
746-
msgid "Select all %(total_count)s %(module_name)s"
747-
msgstr "Selecionar todos %(total_count)s %(module_name)s"
746+
msgid "Select all %(total_count)s %(model_name)s"
747+
msgstr "Selecionar todos %(total_count)s %(model_name)s"
748748

749749
#: templates/xadmin/blocks/model_list.results_bottom.actions.html:20
750750
msgid "Clear selection"

xadmin/locale/ru_RU/LC_MESSAGES/django.po

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -744,7 +744,7 @@ msgstr ""
744744

745745
#: templates/xadmin/blocks/model_list.results_bottom.actions.html:19
746746
#, python-format
747-
msgid "Select all %(total_count)s %(module_name)s"
747+
msgid "Select all %(total_count)s %(model_name)s"
748748
msgstr ""
749749

750750
#: templates/xadmin/blocks/model_list.results_bottom.actions.html:20
-2 Bytes
Binary file not shown.

xadmin/locale/zh_CN/LC_MESSAGES/django.po

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -735,8 +735,8 @@ msgstr "点击此处选择所有页面中包含的对象。"
735735

736736
#: templates/xadmin/blocks/model_list.results_bottom.actions.html:19
737737
#, python-format
738-
msgid "Select all %(total_count)s %(module_name)s"
739-
msgstr "选中所有的 %(total_count)s 个 %(module_name)s"
738+
msgid "Select all %(total_count)s %(model_name)s"
739+
msgstr "选中所有的 %(total_count)s 个 %(model_name)s"
740740

741741
#: templates/xadmin/blocks/model_list.results_bottom.actions.html:20
742742
msgid "Clear selection"

xadmin/models.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ def default(self, o):
7575
elif isinstance(o, decimal.Decimal):
7676
return str(o)
7777
elif isinstance(o, ModelBase):
78-
return '%s.%s' % (o._meta.app_label, o._meta.module_name)
78+
return '%s.%s' % (o._meta.app_label, o._meta.model_name)
7979
else:
8080
try:
8181
return super(JSONEncoder, self).default(o)

xadmin/plugins/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
PLUGINS = ('actions', 'filters', 'bookmark', 'export', 'layout', 'refresh', 'sortable', 'details',
33
'editable', 'relate', 'chart', 'ajax', 'relfield', 'inline', 'topnav', 'portal', 'quickform',
44
'wizard', 'images', 'auth', 'multiselect', 'themes', 'aggregation', 'mobile', 'passwords',
5-
'sitemenu', 'language', 'comments','quickfilter')
5+
'sitemenu', 'language', 'quickfilter')
66

77

88
def register_builtin_plugins(site):

xadmin/plugins/bookmark.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ def get_context(self, context):
4444
filter(lambda i: bool(i[1] and (i[0] in (COL_LIST_VAR, ORDER_VAR, SEARCH_VAR) or i[0].startswith(FILTER_PREFIX)
4545
or i[0].startswith(RELATE_PREFIX))), self.request.GET.items()))])
4646

47-
model_info = (self.opts.app_label, self.opts.module_name)
47+
model_info = (self.opts.app_label, self.opts.model_name)
4848
has_selected = False
4949
menu_title = _(u"Bookmark")
5050
list_base_url = reverse('xadmin:%s_%s_changelist' %
@@ -75,7 +75,7 @@ def check_item(i):
7575
has_selected = True
7676

7777
content_type = ContentType.objects.get_for_model(self.model)
78-
bk_model_info = (Bookmark._meta.app_label, Bookmark._meta.module_name)
78+
bk_model_info = (Bookmark._meta.app_label, Bookmark._meta.model_name)
7979
bookmarks_queryset = Bookmark.objects.filter(
8080
content_type=content_type,
8181
url_name='xadmin:%s_%s_changelist' % model_info
@@ -125,9 +125,9 @@ def block_nav_menu(self, context, nodes):
125125
class BookmarkView(ModelAdminView):
126126

127127
@csrf_protect_m
128-
@transaction.commit_on_success
128+
@transaction.atomic
129129
def post(self, request):
130-
model_info = (self.opts.app_label, self.opts.module_name)
130+
model_info = (self.opts.app_label, self.opts.model_name)
131131
url_name = 'xadmin:%s_%s_changelist' % model_info
132132
bookmark = Bookmark(
133133
content_type=ContentType.objects.get_for_model(self.model),

xadmin/plugins/details.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,12 +39,12 @@ def result_item(self, item, obj, field_name, row):
3939
try:
4040
item_res_uri = reverse(
4141
'%s:%s_%s_detail' % (self.admin_site.app_name,
42-
opts.app_label, opts.module_name),
42+
opts.app_label, opts.model_name),
4343
args=(getattr(rel_obj, opts.pk.attname),))
4444
if item_res_uri:
4545
if has_change_perm:
4646
edit_url = reverse(
47-
'%s:%s_%s_change' % (self.admin_site.app_name, opts.app_label, opts.module_name),
47+
'%s:%s_%s_change' % (self.admin_site.app_name, opts.app_label, opts.model_name),
4848
args=(getattr(rel_obj, opts.pk.attname),))
4949
else:
5050
edit_url = ''

xadmin/plugins/editable.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ def get(self, request, object_id):
129129

130130
@filter_hook
131131
@csrf_protect_m
132-
@transaction.commit_on_success
132+
@transaction.atomic
133133
def post(self, request, object_id):
134134
model_fields = [f.name for f in self.opts.fields]
135135
fields = [f for f in request.POST.keys() if f in model_fields]

xadmin/plugins/inline.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -441,7 +441,7 @@ def _get_detail_formset_instance(self, inline):
441441
replace_field_to_value(formset.helper.layout, inline)
442442
model = inline.model
443443
opts = model._meta
444-
fake_admin_class = type(str('%s%sFakeAdmin' % (opts.app_label, opts.module_name)), (object, ), {'model': model})
444+
fake_admin_class = type(str('%s%sFakeAdmin' % (opts.app_label, opts.model_name)), (object, ), {'model': model})
445445
for form in formset.forms:
446446
instance = form.instance
447447
if instance.pk:

xadmin/plugins/portal.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ def get_layout_objects(layout, clz, objects):
2323
class ModelFormPlugin(BasePortalPlugin):
2424

2525
def _portal_key(self):
26-
return '%s_%s_editform_portal' % (self.opts.app_label, self.opts.module_name)
26+
return '%s_%s_editform_portal' % (self.opts.app_label, self.opts.model_name)
2727

2828
def get_form_helper(self, helper):
2929
cs = []
@@ -64,7 +64,7 @@ def block_form_top(self, context, node):
6464
class ModelDetailPlugin(ModelFormPlugin):
6565

6666
def _portal_key(self):
67-
return '%s_%s_detail_portal' % (self.opts.app_label, self.opts.module_name)
67+
return '%s_%s_detail_portal' % (self.opts.app_label, self.opts.model_name)
6868

6969
def block_after_fieldsets(self, context, node):
7070
# put portal key and submit url to page

xadmin/plugins/relate.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ def related_link(self, instance):
4343
links = []
4444
for r, view_perm, add_perm in self.get_related_list():
4545
label = r.opts.app_label
46-
model_name = r.opts.module_name
46+
model_name = r.opts.model_name
4747
f = r.field
4848
rel_name = f.rel.get_related_field().name
4949

xadmin/plugins/relfield.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ def render(self, name, value, attrs=None):
2525
else:
2626
attrs['class'] = attrs['class'] + ' select-search'
2727
attrs['data-search-url'] = self.admin_view.get_admin_url(
28-
'%s_%s_changelist' % (to_opts.app_label, to_opts.module_name))
28+
'%s_%s_changelist' % (to_opts.app_label, to_opts.model_name))
2929
attrs['data-placeholder'] = _('Search %s') % to_opts.verbose_name
3030
attrs['data-choices'] = '?'
3131
if self.rel.limit_choices_to:

xadmin/plugins/topnav.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ def block_top_navbar(self, context, nodes):
3131
app_label = model._meta.app_label
3232

3333
if self.has_model_perm(model, "view"):
34-
info = (app_label, model._meta.module_name)
34+
info = (app_label, model._meta.model_name)
3535
if getattr(self.admin_site._registry[model], 'search_fields', None):
3636
try:
3737
search_models.append({
@@ -57,7 +57,7 @@ def block_top_navmenu(self, context, nodes):
5757
app_label = model._meta.app_label
5858

5959
if self.has_model_perm(model, "add"):
60-
info = (app_label, model._meta.module_name)
60+
info = (app_label, model._meta.model_name)
6161
try:
6262
add_models.append({
6363
'title': _('Add %s') % capfirst(model._meta.verbose_name),

xadmin/plugins/xversion.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,7 @@ def get_context(self):
221221
context.update({
222222
"opts": opts,
223223
"app_label": opts.app_label,
224-
"module_name": capfirst(opts.verbose_name),
224+
"model_name": capfirst(opts.verbose_name),
225225
"title": _("Recover deleted %(name)s") % {"name": force_unicode(opts.verbose_name_plural)},
226226
"deleted": deleted,
227227
"changelist_url": self.model_admin_url("changelist"),
@@ -262,7 +262,7 @@ def get_context(self):
262262
context.update({
263263
'title': _('Change history: %s') % force_unicode(self.obj),
264264
'action_list': action_list,
265-
'module_name': capfirst(force_unicode(opts.verbose_name_plural)),
265+
'model_name': capfirst(force_unicode(opts.verbose_name_plural)),
266266
'object': self.obj,
267267
'app_label': opts.app_label,
268268
"changelist_url": self.model_admin_url("changelist"),
@@ -580,7 +580,7 @@ def total_form_count_hack(count):
580580
if self.request.method == 'GET' and formset.helper and formset.helper.layout:
581581
helper = formset.helper
582582
helper.filter(basestring).wrap(InlineDiffField)
583-
fake_admin_class = type(str('%s%sFakeAdmin' % (self.opts.app_label, self.opts.module_name)), (object, ), {'model': self.model})
583+
fake_admin_class = type(str('%s%sFakeAdmin' % (self.opts.app_label, self.opts.model_name)), (object, ), {'model': self.model})
584584
for form in formset.forms:
585585
instance = form.instance
586586
if instance.pk:

xadmin/sites.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ def register(self, model_or_iterable, admin_class=object, **options):
107107
# which causes issues later on.
108108
options['__module__'] = __name__
109109

110-
admin_class = type(str("%s%sAdmin" % (model._meta.app_label, model._meta.module_name)), (admin_class,), options or {})
110+
admin_class = type(str("%s%sAdmin" % (model._meta.app_label, model._meta.model_name)), (admin_class,), options or {})
111111
admin_class.model = model
112112
admin_class.order = self.model_admins_order
113113
self.model_admins_order += 1
@@ -309,12 +309,12 @@ def wrapper(*args, **kwargs):
309309
view_urls = [url(
310310
path, wrap(
311311
self.create_model_admin_view(clz, model, admin_class)),
312-
name=name % (model._meta.app_label, model._meta.module_name))
312+
name=name % (model._meta.app_label, model._meta.model_name))
313313
for path, clz, name in self._registry_modelviews]
314314
urlpatterns += patterns('',
315315
url(
316316
r'^%s/%s/' % (
317-
model._meta.app_label, model._meta.module_name),
317+
model._meta.app_label, model._meta.model_name),
318318
include(patterns('', *view_urls)))
319319
)
320320

xadmin/templates/xadmin/auth/user/change_password.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
{% endblock %}
2626

2727
{% block content %}
28-
<form action="{{ form_url }}" class="exform" method="post" id="{{ opts.module_name }}_form">{% csrf_token %}{% block form_top %}{% endblock %}
28+
<form action="{{ form_url }}" class="exform" method="post" id="{{ opts.model_name }}_form">{% csrf_token %}{% block form_top %}{% endblock %}
2929
{% if errors %}
3030
<div class="alert alert-danger">
3131
{% blocktrans count counter=errors|length %}Please correct the error below.{% plural %}Please correct the errors below.{% endblocktrans %}

xadmin/templates/xadmin/blocks/model_list.results_bottom.actions.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
</div>
1717
{% if actions_selection_counter %}
1818
{% if cl.result_count != cl.result_list|length %}
19-
<a class="question btn btn-default" href="javascript:;" style="display: none;" title="{% trans "Click here to select the objects across all pages" %}">{% blocktrans with cl.result_count as total_count %}Select all {{ total_count }} {{ module_name }}{% endblocktrans %}</a>
19+
<a class="question btn btn-default" href="javascript:;" style="display: none;" title="{% trans "Click here to select the objects across all pages" %}">{% blocktrans with cl.result_count as total_count %}Select all {{ total_count }} {{ model_name }}{% endblocktrans %}</a>
2020
<a class="clear btn btn-default" href="javascript:;" style="display: none;">{% trans "Clear selection" %}</a>
2121
{% endif %}
2222
<script type="text/javascript">var _actions_icnt="{{ cl.result_list|length|default:"0" }}";</script>

xadmin/templates/xadmin/views/batch_change_form.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
{% endblock %}
1818

1919
{% block content %}
20-
<form class="exform" {% if has_file_field %}enctype="multipart/form-data" {% endif %}action="" method="post" id="{{ opts.module_name }}_form">{% csrf_token %}
20+
<form class="exform" {% if has_file_field %}enctype="multipart/form-data" {% endif %}action="" method="post" id="{{ opts.model_name }}_form">{% csrf_token %}
2121
{% if errors %}
2222
<div class="alert alert-danger alert-dismissable">
2323
<button type="button" class="close" data-dismiss="alert">&times;</button>

0 commit comments

Comments
 (0)