From 65750f412c735b39123a66fc9fb5f2b69ca43ec6 Mon Sep 17 00:00:00 2001 From: Fredrik Jonsson <frjo@xdeb.org> Date: Thu, 13 Sep 2018 10:27:19 +0200 Subject: [PATCH] Allow existing files on imported submissions to get correct url so they can be downloaded. --- opentech/apply/funds/models/mixins.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/opentech/apply/funds/models/mixins.py b/opentech/apply/funds/models/mixins.py index b686253f6..91779f3d1 100644 --- a/opentech/apply/funds/models/mixins.py +++ b/opentech/apply/funds/models/mixins.py @@ -38,6 +38,9 @@ class AccessFormData: @classmethod def stream_file(cls, file): + if 'path' in file: + file['filename'] = file['name'] + file['name'] = file['path'] if isinstance(file, StreamFieldFile): return file if isinstance(file, File): -- GitLab