Skip to main content
Version: 0.2.x

NumberRangeParameterOption

The class for parameter options of number range parameters. Note that only one option can appear at a time, but different options may appear based on authenticated user or parent parameter selections. See ParameterOption page for more details on the common constructor arguments.

Can be found in the classpath squirrels.parameter_options.NumberRangeParameterOption or squirrels.NumberRangeParameterOption.

Constructor Arguments​

Creates a NumberRangeParameterOption object.

Required Arguments:

  • min_value: A string, int, or Decimal (from decimal package). This is the minimum selectable value for both the lower and upper selected values of the number range parameter
  • max_value: A string, int, or Decimal (from decimal package). This is the maximum selectable value for both the lower and upper selected values of the number range parameter
    • Must be greater than "min_value"

Optional Keyword Arguments:

  • increment: A string, int, or Decimal (from decimal package). This is the increment of selectable values. Default is 1
    • Must fit evenly between "min_value" and "max_value"
  • default_lower_value: A string, int, Decimal (from decimal package), or None. This is the default selected lower value. When None, the "min_value" is used. Default is None
    • Must be selectable based on "min_value", "max_value", and "increment"
  • default_upper_value: A string, int, Decimal (from decimal package), or None. This is the default selected upper value. When None, the "max_value" is used. Default is None
    • Must be selectable based on "min_value", "max_value", and "increment"
    • Must be greater than "default_lower_value"
  • user_groups (see ParameterOption)
  • parent_options_ids (see ParameterOption)