Thesauri: editing GUI
Opened this issue · 0 comments
etj commented
Modify the editing GUI so that thesauri selection is rendered in the first tab.
We want to display all of the thesauri set as required in the GUI.
The requirement is set in the DB (card_min
, card_max
), but we also have a legacy setting (https://docs.geonode.org/en/2.10/admin/thesaurus/index.html#configure-a-thesaurus-in-geonode)
In the GUI,
card_max=0
--> Disabled, won't be shown in the GUI (card_min
is not even checked in this case)card_max=1
--> Single choicecard_min = 0
--> Single choice, optional --> rendered as a dropdown, with an empty/unselected elementcard_min = 1
--> Single choice, required --> rendered as a dropdown
card_max=-1
--> Multiple choicecard_min = 0
--> [0..N] Multiple choices, optional --> rendered as a typeahead badges(?)card_min = 1
--> [1..N] Multiple choices, required --> rendered as a typeahead badges(?) + apply check for the mandatory warning
If the legacy required
boolean setting is in the configuration, we'll use it as if we'd found:
required
=true
card_min = 1
card_max = -1
required
=false
card_min = 0
card_max = -1
As stated in #11, when a legacy settings is found, we'll use it and notify a warning about the deprecated setting.
GUI should be restructed as follows:
- free keywords moved to the bottom
- list of Thesauri keywords selectors
Also, the validation checks should act according to the mandatory requirements of the displayed thesauri.