From 06a0ed7818104f15e3a9a78e25206657aaa59d57 Mon Sep 17 00:00:00 2001 From: Krishnan Shankar Date: Fri, 7 Jun 2024 03:26:24 -0400 Subject: [PATCH] Add drag-and-drop image upload support to create_view --- tin/apps/assignments/views.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/tin/apps/assignments/views.py b/tin/apps/assignments/views.py index 617ced5d..3ebd446d 100644 --- a/tin/apps/assignments/views.py +++ b/tin/apps/assignments/views.py @@ -209,8 +209,9 @@ def create_view(request, course_id): { "assignment_form": assignment_form, "course": course, - "action": "add", "nav_item": "Create assignment", + "action": "add", + "imgbb_api_key": settings.IMGBB_API_KEY, }, ) @@ -239,9 +240,9 @@ def edit_view(request, assignment_id): "course": assignment.course, "folder": assignment.folder, "assignment": assignment, - "imgbb_api_key": settings.IMGBB_API_KEY, - "action": "edit", "nav_item": "Edit", + "action": "edit", + "imgbb_api_key": settings.IMGBB_API_KEY, }, )