moin icon indicating copy to clipboard operation
moin copied to clipboard

scalability issue with ticket dropdown menus in metadata editor

Open ThomasWaldmann opened this issue 12 years ago • 5 comments

Original report by xiaq (Bitbucket: xiaq, GitHub: xiaq).


Migrated from https://bitbucket.org/xiaq/moin-2.0/issue/7/scalability-issue-with-dropdown-menus

Thomas Waldmann created an issue 2012-08-14

"Assigned To", "Superseded By", "Depends On" are handled by dropdown menus.

First is filled with all users to select one from, the other 2 are filled with all(?) other tickets to select one from.

Both likely does not scale if you have many users / tickets, because the menu then gets very large, likely too large to handle.

How can we solve this in a better way?

ThomasWaldmann avatar Feb 10 '13 12:02 ThomasWaldmann

Original comment by RogerHaase (Bitbucket: RogerHaase, GitHub: RogerHaase).


This issue applies to tickets. To see the problem, create multiple tickets and multiple users and envision the size of the dropdown boxes should there be 50 users and 500 tickets.

The solution requires several steps:

  1. Review alternatives, is Chosen the best fit?
  2. If choice is Chosen, there is an outdated Xstatic package: https://pypi.python.org/pypi/XStatic-Chosen/0.13.0.1
  3. Either update the Chosen package, or create Xstatic packaging for the alternative (assuming Xstatic packaging applies)
  4. Modify setup.py to add the xstatic package.
  5. Find a place to load the js or css files
  6. Fix the dropdown boxes.

(If the obsolete version of Chosen works well enough, step 3 may be done last)

ThomasWaldmann avatar Feb 20 '15 15:02 ThomasWaldmann

Original comment by xiaq (Bitbucket: xiaq, GitHub: xiaq).


They are all available under a GPL-compatible license:

  • Chosen: MIT
  • Select2: Apache and GPLv2
  • flexselect: MIT

ThomasWaldmann avatar Apr 23 '13 04:04 ThomasWaldmann

Original comment by xiaq (Bitbucket: xiaq, GitHub: xiaq).


Select2 and flexselect are also viable options.

ThomasWaldmann avatar Apr 23 '13 04:04 ThomasWaldmann

Original comment by xiaq (Bitbucket: xiaq, GitHub: xiaq).


I found this nice jQuery plugin when browsing http://plugins.jquery.com/tag/dropdown/: http://harvesthq.github.io/chosen/.

Seems pretty much what we need.

ThomasWaldmann avatar Apr 23 '13 03:04 ThomasWaldmann

Original comment by xiaq (Bitbucket: xiaq, GitHub: xiaq).


perhaps a combo box [1] with filtering capability? (ie. when you type "foo", only items containing "foo" are included in the dropdown menu)

  1. http://en.wikipedia.org/wiki/Combo_box

ThomasWaldmann avatar Feb 10 '13 12:02 ThomasWaldmann