# academics/urls.py
from django.urls import path
from . import views

app_name = 'academics'

urlpatterns = [
    # Existing URLs
    path('classes/', views.ClassListView.as_view(), name='class_list'),
    path('classes/<int:pk>/', views.ClassDetailView.as_view(), name='class_detail'),
    path('classes/<int:pk>/students/', views.ClassStudentsView.as_view(), name='class_students'),
    
    # NEW: Teacher Assignment URLs
    path('classes/<int:class_id>/assign-teacher/', views.assign_teacher, name='assign_teacher'),
    path('classes/<int:class_id>/teachers/', views.get_teachers_for_class, name='get_teachers'),
    path('assignments/<int:assignment_id>/remove/', views.remove_teacher_assignment, name='remove_assignment'),
    path('classes/<int:class_id>/bulk-assign/', views.bulk_assign_teachers, name='bulk_assign'),
    
    # Subjects
    path('subjects/', views.SubjectListView.as_view(), name='subject_list'),
    path('subjects/add/', views.SubjectCreateView.as_view(), name='subject_add'),
    path('subjects/<int:pk>/', views.SubjectDetailView.as_view(), name='subject_detail'),
]