doc/book/en/B1020-define-views.en.txt
changeset 1191 216141cf47a3
parent 318 6cb74102d611
child 1249 905d76e38433
equal deleted inserted replaced
1190:15fc369bc3ca 1191:216141cf47a3
   161 We'll show you now an example of a ``primary`` view and how to customize it.
   161 We'll show you now an example of a ``primary`` view and how to customize it.
   162 
   162 
   163 If you want to change the way a ``BlogEntry`` is displayed, just override 
   163 If you want to change the way a ``BlogEntry`` is displayed, just override 
   164 the method ``cell_call()`` of the view ``primary`` in ``BlogDemo/views.py`` ::
   164 the method ``cell_call()`` of the view ``primary`` in ``BlogDemo/views.py`` ::
   165 
   165 
   166   01. from ginco.web.views import baseviews
   166   01. from cubicweb.web.views import baseviews
   167   02.
   167   02.
   168   03. class BlogEntryPrimaryView(baseviews.PrimaryView):
   168   03. class BlogEntryPrimaryView(baseviews.PrimaryView):
   169   04.
   169   04.
   170   05.     accepts = ('BlogEntry',)
   170   05.     accepts = ('BlogEntry',)
   171   06.
   171   06.