Open etj opened 3 years ago
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)
card_min
card_max
In the GUI,
card_max=0
card_max=1
card_min = 0
card_min = 1
card_max=-1
If the legacy required boolean setting is in the configuration, we'll use it as if we'd found:
required
true
card_max = -1
false
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:
Also, the validation checks should act according to the mandatory requirements of the displayed thesauri.
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 dropdowncard_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 warningIf 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:
Also, the validation checks should act according to the mandatory requirements of the displayed thesauri.