From 5c8dafb38cf6d6b2535f5fd66ae504d28c61fb03 Mon Sep 17 00:00:00 2001 From: Seth Woodworth Date: Mon, 25 Mar 2013 23:58:46 +0000 Subject: [PATCH] set Note.name to filename by default --- karmaworld/apps/ajaxuploader/backends/local.py | 1 + 1 file changed, 1 insertion(+) diff --git a/karmaworld/apps/ajaxuploader/backends/local.py b/karmaworld/apps/ajaxuploader/backends/local.py index ac083d8..5efba15 100644 --- a/karmaworld/apps/ajaxuploader/backends/local.py +++ b/karmaworld/apps/ajaxuploader/backends/local.py @@ -61,6 +61,7 @@ class LocalUploadBackend(AbstractUploadBackend): # Another file copy at FileField's 'upload_to' dir print "creating note" note = Note() + note.name = filename note.note_file = os.path.join(self._dir, filename) note.course_id = request.GET['course_id'] print "saving note" -- 2.25.1