gregplaysguitar / django-fileman Goto Github PK
View Code? Open in Web Editor NEWdjango-fileman adds user-uploaded static files to the django admin (i.e. images, media, documents) and integrates with tinymce
License: Other
django-fileman adds user-uploaded static files to the django admin (i.e. images, media, documents) and integrates with tinymce
License: Other
There is an error inside fileman/views.py on django.core.urlresolvers import reverse
How can I make it work on AWS S3?
This is not an issue, but multi-upload feature would be nice.
Hi,
I'm testing your fileman-app and discovered that the delete and rename is not working.
The last step in the process is a POST-action, but in the view.delete the first line is
path = request.GET.get('path')
so the variable path is empty.
A quick fix for delete is:
def delete(request):
if request.method == 'POST':
path = request.POST.get('path')
is_dir = os.path.isdir(get_full_path(path))
if is_dir:
shutil.rmtree(get_full_path(path))
else:
os.remove(get_full_path(path))
msg = '%s was deleted' % path
messages.add_message(request, messages.INFO, msg)
return redirect('admin:fileman_upload_changelist')
path = request.GET.get('path')
is_dir = os.path.isdir(get_full_path(path))
if not is_safe_path(path):
return redirect('admin:fileman_upload_changelist')
if is_dir:
delete_results = render_delete_results(read_dir(path, True))
else:
delete_results = None
return render(request, 'fileman/delete.html', {
'app_label': 'fileman',
'title': 'Delete',
'delete_results': delete_results,
'path': path,
})
An in the template delete.html:
<form action="{{ request.path }}" method="POST">
{% csrf_token %}
<input type="submit" value="Yes, I'm sure" class="delete-button">
<input type="hidden" name="path" value="{{ path }}">
<a class="button cancel-link" onclick="window.history.back(); return false;">
No, take me back</a>
</form>
Except of these it is nice app,
Regards, Helge
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.