Getting label from select in preview

Good afternoon! How it is possible to deduce value from select? At the moment I'm getting the name from an option. How to get a label?
2 Replies
ifox
ifox2y ago
Hi @User142 the value you're saving in database is what you're getting, there's nothing that would let the code infer that you want the label from the form definition. You should probably use a constant/enum that maps your values to labels and use that when rendering that way you can use it from both the form and the rendering code
trompix
trompix2y ago
@ifox Thanks, I understand you now. I will do it through Enumerations