Convert the document create view to a CBV.

This commit is contained in:
Roberto Rosario
2015-08-23 21:37:37 -04:00
parent 8cd14a2ae1
commit dd301d8e98
2 changed files with 36 additions and 40 deletions

View File

@@ -2,7 +2,7 @@ from __future__ import unicode_literals
from django.conf.urls import patterns, url
from .views import DocumentCommentListView
from .views import CommentCreateView, DocumentCommentListView
urlpatterns = patterns(
'document_comments.views',
@@ -15,7 +15,7 @@ urlpatterns = patterns(
name='comment_multiple_delete'
),
url(
r'^(?P<document_id>\d+)/comment/add/$', 'comment_add',
r'^(?P<pk>\d+)/comment/add/$', CommentCreateView.as_view(),
name='comment_add'
),
url(