Skip to content

Commit

Permalink
Add "prefix" to docs
Browse files Browse the repository at this point in the history
  • Loading branch information
lrljoe authored Jul 16, 2024
1 parent 6486d66 commit 10b0bc5
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion docs/filter-types/filters-number-range.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ public function filters(): array
'minRange' => 0,
'maxRange' => 100,
'suffix' => '%',
'prefix' => '$',
])
->filter(function (Builder $builder, array $values) {
$builder->where('users.success_rate', '>=', intval($values['min']))
Expand All @@ -32,4 +33,6 @@ public function filters(): array

The default values should be set in the options() method.

You may also specify a minimum and maximum range in the config() options, and should you wish to use real values instead of a percentage, you can change the "suffix" to a metric of your choosing.
You may also specify a minimum and maximum range in the config() options, and should you wish to use real values instead of a percentage.
You can change the "suffix" to a metric of your choosing.
You can change the "prefix" to an item of your choosing (e.g $/£/€)

0 comments on commit 10b0bc5

Please sign in to comment.