views:

11

answers:

1

The title says it all or almost... I have a slug field that I would like to be auto-populated from a value in a manytomany. It kind of works as it displays in realtime the ID of the selection in the manytomany field. The model of the manytomany field has its own def unicode(self) to return a string value with its name but this doesnt appear in the slug.

Thanks

A: 

Django's populate javascript always just uses the value attribute of the coresponding HTML field, which is always the id, it it is a select, no matter how you change your python code! You will need to make a custom js to achieve what you are trying to do!

lazerscience