How to loop over form field choices and display associated model instance fields

前端 未结 8 907
广开言路
广开言路 2021-02-02 14:44

I have a ModelForm with a multiple choice field. The choices are populated instances of Hikers belonging to a specific Club.

I want to customize the way my form displays

8条回答
  •  忘了有多久
    2021-02-02 15:31

    related ticket: https://code.djangoproject.com/ticket/9230

    I made a widget that makes such a table: http://skyl.org/log/post/skyl/2011/01/wherein-the-inner-workings-of-the-deathstarwidget-are-revealed/

    I'm here looking for a better solution still though :D

提交回复
热议问题