cuba-platform / reports

CUBA Reports Addon
https://www.cuba-platform.com/
Apache License 2.0
9 stars 4 forks source link

Ability to predefine a list of values for report parameters #179

Open AnnPivovarova opened 5 years ago

AnnPivovarova commented 5 years ago

Environment

Description of the enhancement

For some reports it is necessary to restrict the possible values of input parameters to a certain predefined list. Now we can process the values only after they are already set by user, but in many cases it will be more clear for a user to choose the values from already predefined options (e.g. as a dropdown) right at the beginning.

Ideally, it would be nice to have an ability to return such list of options in a script set for each parameter and that is performed before report parameters window is shown. For now, in our experience, in most cases such lists are needed for String parameters, but in general depending on the parameter type this may be a list of simple types: string, integer, date or even a list of entities.