首页 > 解决方案 > Download file from a django UpdateView template

问题描述

I'm new to django, and I've a little problem. I've a model with a FileField field, using generic views and ModelForm, I can upload a file to the server. In a modify page using an UpdateView I've a link to my document (e.g. http://127.0.0.1:8000/static-storage/file_name),but if I try to download I get an error page not found. Maybe I need to write an url path but I can't understand how to implement. Could someone give me an help ? Thanks.

标签: pythondjango

解决方案


推荐阅读