Add document comments API endpoints. GitHub issue #249.

Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com>
This commit is contained in:
Roberto Rosario
2017-02-21 02:48:02 -04:00
parent 54372d966d
commit 81c0f90b4f
7 changed files with 307 additions and 0 deletions
+4
View File
@@ -6,6 +6,7 @@ from django.utils.translation import ugettext_lazy as _
from acls import ModelPermission
from common import MayanAppConfig, menu_facet, menu_object, menu_sidebar
from navigation import SourceColumn
from rest_api.classes import APIEndPoint
from .links import (
link_comment_add, link_comment_delete, link_comments_for_document
@@ -20,11 +21,14 @@ class DocumentCommentsApp(MayanAppConfig):
app_namespace = 'comments'
app_url = 'comments'
name = 'document_comments'
test = True
verbose_name = _('Document comments')
def ready(self):
super(DocumentCommentsApp, self).ready()
APIEndPoint(app=self, version_string='1')
Document = apps.get_model(
app_label='documents', model_name='Document'
)