pielgrzym / django-imaging

Ajax driven gallery field for django (mostly admin)
16 stars 7 forks source link

django-imaging v 1.0

Ajax driven gallery field for django admin

Screenshot

After 2 years of slumber brought to life again

Requirements

Installation

    pip install django-imaging
urlpatterns = patterns('',
(...)
(r'^imaging/', include('imaging.urls')),
(...)
)

Or include('myappname.imaging.urls')

from imaging.fields import ImagingField

class Somemodel(models.Model):
    photos = ImagingField()
from django.contrib.contenttypes import generic
from imaging.fields import ImagingField
from imaging.models import Image

class Somemodel(models.Model):
   photos = ImagingField()
   photos_set = generic.GenericRelation(Image)
IMAGING_SETTINGS = {
    'image_dir' : 'funny_photos',
}

The images uploaded will be stored inside MEDIA_ROOT/funny_photos.

Limitations

  1. Currently only one ImagingField? per model.
  2. Drag'n'drop doesn't work properly in Opera (jquery.ui.sortable related problem)
  3. No orphaned images management
  4. ManyToMany? relation with an Image not supported
  5. Need to add a GenericRelation? field manually, I can't figoure out how to autoadd it
  6. Exceptions not handled too well