tickets module: api_v2, admin views and tests
This commit is contained in:
parent
434dfe807e
commit
cbc27b143f
8 changed files with 365 additions and 16 deletions
|
@ -197,14 +197,21 @@ DATA_UPLOAD_MAX_MEMORY_SIZE = 1024 * 1024 * 128 # 128 MB
|
|||
|
||||
DEFAULT_AUTO_FIELD = 'django.db.models.BigAutoField'
|
||||
|
||||
CHANNEL_LAYERS = {
|
||||
'default': {
|
||||
'BACKEND': 'channels_redis.core.RedisChannelLayer',
|
||||
'CONFIG': {
|
||||
'hosts': [('localhost', 6379)],
|
||||
},
|
||||
if 'test' in sys.argv:
|
||||
CHANNEL_LAYERS = {
|
||||
'default': {
|
||||
'BACKEND': 'channels.layers.InMemoryChannelLayer'
|
||||
}
|
||||
}
|
||||
else:
|
||||
CHANNEL_LAYERS = {
|
||||
'default': {
|
||||
'BACKEND': 'channels_redis.core.RedisChannelLayer',
|
||||
'CONFIG': {
|
||||
'hosts': [('localhost', 6379)],
|
||||
},
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
TEST_RUNNER = 'core.test_runner.FastTestRunner'
|
||||
|
|
|
@ -27,6 +27,8 @@ urlpatterns = [
|
|||
path('api/2/', include('inventory.api_v2')),
|
||||
path('api/2/', include('files.api_v2')),
|
||||
path('media/2/', include('files.media_v2')),
|
||||
path('api/2/', include('tickets.api_v2')),
|
||||
path('api/2/', include('notify_sessions.api_v2')),
|
||||
path('api/2/', include('authentication.api_v2')),
|
||||
path('api/', get_info),
|
||||
]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue