@ -151,6 +151,11 @@ REST_FRAMEWORK = {
'PAGE_SIZE': 5,
'DEFAULT_FILTER_BACKENDS': ('django_filters.rest_framework.DjangoFilterBackend',),
'SEARCH_PARAM': 'q',
'DEFAULT_RENDERER_CLASSES': (
'rest_framework.renderers.JSONRenderer',
'rest_framework.renderers.BrowsableAPIRenderer',
'rest_framework_xml.renderers.XMLRenderer'
)
}
# Internationalization
@ -1,4 +1,5 @@
from django.urls import path
from rest_framework.urlpatterns import format_suffix_patterns
from .api import ProjectList, ProjectDetail
from .api import LabelList, LabelDetail
@ -25,3 +26,5 @@ urlpatterns = [
path('projects/<int:project_id>/docs/<int:doc_id>/entities/<int:entity_id>',
EntityDetail.as_view(), name='entity_detail'),
]
urlpatterns = format_suffix_patterns(urlpatterns, allowed=['json', 'xml'])
@ -6,6 +6,7 @@ django-heroku==0.3.1
django-widget-tweaks==1.4.2
djangorestframework==3.8.2
djangorestframework-filters==0.10.2
djangorestframework-xml==1.4.0
Faker==0.8.8
flake8==3.6.0
gunicorn==19.9.0