I am trying to use Django generic view for CRUD.
I found two resources (1, 2), and bit confused the best and easy approach.
- Added below to myapp/urls.py
urlpatterns = patterns('', url(r'^$', ListView.as_view( model= Product)), )
then it gave an error that,
Exception Type: TemplateDoesNotExist
Exception Value:
myapp/product_list.html
It worked when I created a file product_list.html. But, do I have to manually write the template? I am sure not.
Also, how to decorate it so that only users of a group has access to it.
Thanks.