diff --git a/course/views.py b/course/views.py index 4169e8e..73466e0 100644 --- a/course/views.py +++ b/course/views.py @@ -472,6 +472,7 @@ def course_drop(request): if request.method == "POST": student = get_object_or_404(Student, student__pk=request.user.id) course_ids = request.POST.getlist("course_ids") + print("course_ids", course_ids) for course_id in course_ids: course = get_object_or_404(Course, pk=course_id) TakenCourse.objects.filter(student=student, course=course).delete() diff --git a/templates/course/course_registration.html b/templates/course/course_registration.html index fed678e..3afbec0 100644 --- a/templates/course/course_registration.html +++ b/templates/course/course_registration.html @@ -182,31 +182,18 @@
{% trans 'Check the university calender' %} - {% trans 'Print Registerd Courses' %} - -
-

{% trans 'Course Drop' %} -

-
{{ student.level }}
-
-

+

{% trans 'Course Drop' %}

+

{{ student.level }}

{% csrf_token %}
-
- -
@@ -225,7 +212,7 @@
{% trans 'Check the university calender' %}
@@ -270,6 +257,10 @@
{% trans 'Check the university calender' %} + + {% trans 'Print Registerd Courses' %} + + {% endif %} {% endif %} {% endif %}
- + {{ course.code }} {{ course.title }}