manytoonechoicesdelegate¶
- class camelot.view.controls.delegates.manytoonechoicesdelegate.ManyToOneChoicesDelegate(parent=None, editable=True, **kwargs)[source]¶
Display a ManyToOne or a relationship field as a ComboBox, filling the list of choices with the objects of the target class. This delegate will not work on non relationship fields.
The items in the ComboBox are the unicode representation of the related objects. So these classes need an implementation of their __unicode__ method to show up in a human readable way in the ComboBox.