[Fixed]-Django multi-select widget. Add arbitrary select components

1👍

If the amount of drop-downs is finite and determinable by the time you develop the software (e.g. selecting country->city->street) I would suggest to:

  1. add all the extra dropdowns (without data yet) to your form, make sure they are hidden
  2. use jqueryui to un-hide and populate the dropdowns as needed using ajax

Don’t forget to disable/hide the whole form by default and only show it if JS is enabled in browser.

Also, you will of course need another view, with which only ajax speaks.

Here for you to catch the idea how the stuff should work. Sorry don’t know if they have anything more similar. But: user selects something -> jquery requests data for the next dropdown -> jquery displays next populated dropdown.

👤Art

Leave a comment