hi!
i have a model and I'm using it as inline in admin site. here is the
code:
models.py
class PhotoItem(models.Model):
order = models.IntegerField(blank = True, null = True)
itemset = models.ForeignKey('PhotoSet', related_name='photoset')
item = models.ForeignKey('Photo', related_name='photoitem')
admin.py
class PhotoItemInline(admin.StackedInline):
model = PhotoItem
ordering = ['order']
raw_id_fields = ['item']
extra = 5
i want to use value (item.image) from PhotoItem object (witch is a
string that represents s path to image) in "templates/admin/includes/
fieldset.html" template. the problem is that i dont know how to refer
to that attribute (item.image) when I'm in html.
since i'm designer i'll show you what i need, this is the picture of
field that i need to create in inlines (this is done in filebrowser
app):
http://vedran.webfactional.com/kontenjner/fb.png
i've try to put this on many places:
<p>item.image</p>
but it's not working.
could someone please help me with this one?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django 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/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---