feat: Gestion des profils ADMIN/ECOLE (création des enseignants)

This commit is contained in:
N3WT DE COMPET
2025-03-22 17:20:49 +01:00
parent c9350a796b
commit e0bfd3e115
9 changed files with 249 additions and 134 deletions

View File

@ -116,7 +116,7 @@ class TeacherDetailView(APIView):
return JsonResponse(teacher_serializer.errors, safe=False)
def delete(self, request, id):
return delete_object(Teacher, id, related_field='profile')
return delete_object(Teacher, id, related_field='profile_role')
@method_decorator(csrf_protect, name='dispatch')
@method_decorator(ensure_csrf_cookie, name='dispatch')