explicitly define fields attribute to fix deprecation warnings

This commit is contained in:
André Böhlke 2015-01-17 22:28:32 +01:00
parent 413abf2b9a
commit e2e16a4c34
3 changed files with 8 additions and 0 deletions

View File

@ -189,6 +189,8 @@ class CustomSlideViewMixin(object):
"""
Mixin for for CustomSlide Views.
"""
fields = ('title', 'text', 'weight', )
required_permission = 'core.can_manage_projector'
template_name = 'core/customslide_update.html'
model = CustomSlide

View File

@ -38,6 +38,8 @@ class MediafileViewMixin(object):
A manager can set the uploader manually, else the request user is set as uploader.
"""
fields = ('mediafile', 'title', 'uploader', 'is_presentable',)
model = Mediafile
success_url_name = 'mediafile_list'
url_name_args = []

View File

@ -792,6 +792,8 @@ class CategoryListView(ListView):
class CategoryCreateView(CreateView):
fields = ("name", "prefix",)
required_permission = 'motion.can_manage_motion'
model = Category
success_url_name = 'motion_category_list'
@ -799,6 +801,8 @@ class CategoryCreateView(CreateView):
class CategoryUpdateView(UpdateView):
fields = ("name", "prefix",)
required_permission = 'motion.can_manage_motion'
model = Category
success_url_name = 'motion_category_list'