Browse Source

Move crud templates out of comissoes app

pull/6/head
Marcio Mazza 10 years ago
parent
commit
0a289abbd9
  1. 6
      sapl/crud.py
  2. 0
      templates/crud/confirm_delete.html
  3. 0
      templates/crud/detail.html
  4. 0
      templates/crud/form.html
  5. 0
      templates/crud/list.html

6
sapl/crud.py

@ -96,6 +96,12 @@ def build_crud(model, *layout):
def delete_url(self):
return self.get_url_for_this_object('delete')
def get_template_names(self):
names = super(BaseMixin, self).get_template_names()
names.append("crud/%s.html" %
self.template_name_suffix.lstrip('_'))
return names
class CrudListView(BaseMixin, ListView):
title = BaseMixin.verbose_name_plural
paginate_by = 10

0
templates/comissoes/comissao_confirm_delete.html → templates/crud/confirm_delete.html

0
templates/comissoes/comissao_detail.html → templates/crud/detail.html

0
templates/comissoes/comissao_form.html → templates/crud/form.html

0
templates/comissoes/comissao_list.html → templates/crud/list.html

Loading…
Cancel
Save