2009-02-23 22:16:26 +00:00
|
|
|
from django.core import urlresolvers
|
2013-02-26 12:19:18 +00:00
|
|
|
from comment_tests.custom_comments.models import CustomComment
|
|
|
|
from comment_tests.custom_comments.forms import CustomCommentForm
|
2009-02-23 22:16:26 +00:00
|
|
|
|
|
|
|
def get_model():
|
2013-02-26 12:19:18 +00:00
|
|
|
return CustomComment
|
2009-02-23 22:16:26 +00:00
|
|
|
|
|
|
|
def get_form():
|
|
|
|
return CustomCommentForm
|
|
|
|
|
|
|
|
def get_form_target():
|
|
|
|
return urlresolvers.reverse(
|
2013-02-26 12:19:18 +00:00
|
|
|
"comment_tests.custom_comments.views.custom_submit_comment"
|
2009-02-23 22:16:26 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
def get_flag_url(c):
|
|
|
|
return urlresolvers.reverse(
|
2013-02-26 12:19:18 +00:00
|
|
|
"comment_tests.custom_comments.views.custom_flag_comment",
|
2009-02-23 22:16:26 +00:00
|
|
|
args=(c.id,)
|
|
|
|
)
|
|
|
|
|
|
|
|
def get_delete_url(c):
|
|
|
|
return urlresolvers.reverse(
|
2013-02-26 12:19:18 +00:00
|
|
|
"comment_tests.custom_comments.views.custom_delete_comment",
|
2009-02-23 22:16:26 +00:00
|
|
|
args=(c.id,)
|
|
|
|
)
|
|
|
|
|
|
|
|
def get_approve_url(c):
|
|
|
|
return urlresolvers.reverse(
|
2013-02-26 12:19:18 +00:00
|
|
|
"comment_tests.custom_comments.views.custom_approve_comment",
|
2009-02-23 22:16:26 +00:00
|
|
|
args=(c.id,)
|
|
|
|
)
|