acemaster / django-ckeditor-filemanager

Automatically exported from code.google.com/p/django-ckeditor-filemanager
0 stars 0 forks source link

More stand-alone connector #1

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Hi,
This is not a bug report per se.

I've just implemented Core Five Labs' FileManager, using your Django
connector. I found several issues:
- One issue was with the FileManager itself. It's that you had to change
their main JavaScript file to plug in the URLs for your connector. I wonder
if this issue can be fixed upstream, in Core Five Labs' FileManager.
- In your urls.py for the connector, you reference 'vendor.filemanager...'.
I wonder if there is a more robust way. Like referencing 'filemanager...'
without the 'vendor' part, which means that the 'filemanager' folder has to
be on the python path.
- In the dirlist view, you're using the print statement but apparently
mod_wsgi (which is the preferred deployment solution for Django according
to the docs) doesn't allow this.
- The list of folder names to ignore is hardcoded. Could be an option.
What's more, it could be a list of patterns rather than full names. I've
seen this used by other apps, it's probably not hard to do.
- Quite a few things could be options, and options could be in a
settings.py file for this app, which would try to pull values from
django.conf.settings before using a default. There's a pattern to do that
with Django.
- In filemanager/views.py, you're importing "settings" directly, instead of
using "from django.conf import settings".
- If i'm not mistaken, any user going to the filemanager/index.html public
file can then see files, delete them, and upload new files. Sounds like a
big security breach. My solution for now was to use the @user_passes_test
decorator for the dirlist and handler views, checking that the file manager
was called by a logged in user.

I've tweaked my way through these issues. I don't have time right now but
i'll try to show my changes or contribute patches if you're interested. The
goal would be to offer a stand-alone connector Django application, with
installation instructions.

Original issue reported on code.google.com by fverschelde on 7 Mar 2010 at 10:45

GoogleCodeExporter commented 9 years ago
Thanks for the feedback fverschelde.

As you can see, there's a lot of laziness that went into this. Partly due to the
deadlines I've had (terrible excuse). If you've got patches; I'd be honored to 
patch
this project up with your contribution. 

I know that having a simple connector app is probably the wisest method, as 
everyone
has their own way they setup projects, however I was going for an "out-the-box" 
approach.

I'll make the update as soon as I get a moment.

Original comment by paulvonh...@gmail.com on 9 Mar 2010 at 11:49

GoogleCodeExporter commented 9 years ago
All of fverschelde's comments ring true for me.  I'd very much like to see a 
stand-
alone connector.
Perhaps you're open to some full-on collaboration?
I'm sure this is the habit of others - I tend to fish around for an already 
existing 
"app" before I sit down to build one myself.  After my fishing, this is the 
only 
project that comes close to what I'm looking for.  Would seem a shame not to 
collaborate.

Original comment by onelson@gmail.com on 9 Apr 2010 at 4:02

GoogleCodeExporter commented 9 years ago
Hi there onelson.

Wow am I delayed... This project has been put completely on the back-step. I've 
been so busy, and what a shame really.

I'd love to collaborate on this onelson. I'm planning on moving this project to 
github one of these days too. Then people can fork it, and apply patches.

Do you have a github account?

Original comment by paulvonh...@gmail.com on 20 Apr 2011 at 7:55

GoogleCodeExporter commented 9 years ago
Yup. I'm onelson on both github and bitbucket.

Original comment by onelson@gmail.com on 20 Apr 2011 at 12:48

GoogleCodeExporter commented 9 years ago
Hi, I have just found this project... I released a stand alonedjango connector 
on December 2010... Maybe you can look at it. Or we can work on it together.

Here is the project:
http://pypi.python.org/pypi/django-c5filemanager

You can browse documentation online: 
http://docs.mornie.org/django-c5filemanager/

I'm using mercurial so is simple to share the code.

Kind regards,
Daniele Tricoli

Original comment by erio...@gmail.com on 17 May 2011 at 1:20

GoogleCodeExporter commented 9 years ago
Hi Daniele,

Wow. That is really great.

You should have instructions on how to integrate the filemanager into TinyMCE 
too.

Really Good Work,

Thanks.

Original comment by paulvonh...@gmail.com on 24 Jun 2011 at 11:14