Hello,
I have a dictionary which looks like this:
{'d6abe71c-71b1-11ec-9c05-d8c497859e03': 'Biology',
'd6b00ee8-71b1-11ec-88a1-d8c497859e03': 'Chemistry',
'd6b00ee9-71b1-11ec-a182-d8c497859e03': 'Physics',
'd6b00eea-71b1-11ec-a930-d8c497859e03': 'Biology',
'd6b00eeb-71b1-11ec-aed6-d8c497859e03': 'Chemistry',
'd6b00eec-71b1-11ec-ac9e-d8c497859e03': 'Physics'}`
I would like to display it as a Select widget, using the dictionary values as labels (since the keys aren’t particularly human-readable) but returning the UUIDs (keys) as the widgets value (for further querying my data model by UUID).
From what I understood from the documentation, the Select widget only takes labels in the form of a {label:value} dictionary in the options, which makes it impossible to use the same label multiple times (as the dictionary keys have to be unique).
Is there any other way to provide non-unique custom labels?