mirror of
https://github.com/TandoorRecipes/recipes.git
synced 2025-12-31 20:00:38 -05:00
generic views
This commit is contained in:
@@ -20,7 +20,7 @@ class RecipeTable(tables.Table):
|
||||
|
||||
|
||||
class CategoryTable(tables.Table):
|
||||
id = tables.LinkColumn('edit_recipe', args=[A('id')])
|
||||
id = tables.LinkColumn('edit_category', args=[A('id')])
|
||||
|
||||
class Meta:
|
||||
model = Category
|
||||
@@ -29,9 +29,18 @@ class CategoryTable(tables.Table):
|
||||
|
||||
|
||||
class KeywordTable(tables.Table):
|
||||
id = tables.LinkColumn('edit_recipe', args=[A('id')])
|
||||
id = tables.LinkColumn('edit_keyword', args=[A('id')])
|
||||
|
||||
class Meta:
|
||||
model = Keyword
|
||||
template_name = 'generic/table_template.html'
|
||||
fields = ('id', 'name')
|
||||
|
||||
|
||||
class MonitoredPathTable(tables.Table):
|
||||
edit = tables.TemplateColumn("<a href='#' >Löschen</a>")
|
||||
|
||||
class Meta:
|
||||
model = Keyword
|
||||
template_name = 'generic/table_template.html'
|
||||
fields = ('path', 'last_checked')
|
||||
|
||||
Reference in New Issue
Block a user