39 lines
904 B
Python
39 lines
904 B
Python
# backend/communications/urls.py
|
|
|
|
from django.urls import path
|
|
from django.views.generic import TemplateView
|
|
|
|
from . import views
|
|
|
|
app_name = "communications"
|
|
|
|
urlpatterns = [
|
|
# UI Views
|
|
path("chats/", views.ChatListView.as_view(), name="chat_list"),
|
|
path(
|
|
"chats/<int:pk>/",
|
|
views.ChatDetailView.as_view(),
|
|
name="chat_detail"
|
|
),
|
|
path(
|
|
"test/websocket-events/",
|
|
TemplateView.as_view(template_name="test_websocket_events.html"),
|
|
name="test_websocket_events"
|
|
),
|
|
path(
|
|
"chats/start/<int:employee_pk>/",
|
|
views.start_private_chat,
|
|
name="start_private_chat"
|
|
),
|
|
path(
|
|
"chats/<int:pk>/mark-read/",
|
|
views.chat_mark_read,
|
|
name="chat_mark_read"
|
|
),
|
|
path(
|
|
"start/private/<int:employee_pk>/",
|
|
views.start_private_chat,
|
|
name="start_private_chat"
|
|
),
|
|
]
|