I know there is a 'main_image' property on the product model.
How can I get a product thumbnail in the product admin?
I have created a local app called admin_extras
my admin.py file looks like this:
from django.contrib import admin
from django.db import models
from product.models import Product
from satchmo_utils.thumbnail.field import ImageWithThumbnailField
from satchmo_utils.thumbnail.widgets import AdminImageWithThumbnailWidget
from product.admin import ProductOptions
admin.site.unregister(Product)
class CustomProductAdmin(ProductOptions):
formfield_overrides = {
ImageWithThumbnailField : {'widget' : AdminImageWithThumbnailWidget},
}
list_display = ('name', 'unit_price', 'items_in_stock',
'active','featured','main_image')
list_display_links = ('name',)
admin.site.register(Product, CustomProductAdmin)
....
How can I do this?
--
You received this message because you are subscribed to the Google Groups
"Satchmo users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/satchmo-users?hl=en.