mirror of
https://github.com/shlinkio/shlink.git
synced 2026-03-08 00:03:12 +08:00
Standardized ordering field handling and added validation for short URLs list
This commit is contained in:
@@ -21,6 +21,7 @@ class ShortUrlsParamsInputFilter extends InputFilter
|
||||
public const END_DATE = 'endDate';
|
||||
public const ITEMS_PER_PAGE = 'itemsPerPage';
|
||||
public const TAGS_MODE = 'tagsMode';
|
||||
public const ORDER_BY = 'orderBy';
|
||||
|
||||
public function __construct(array $data)
|
||||
{
|
||||
@@ -46,5 +47,7 @@ class ShortUrlsParamsInputFilter extends InputFilter
|
||||
'strict' => InArray::COMPARE_STRICT,
|
||||
]));
|
||||
$this->add($tagsMode);
|
||||
|
||||
$this->add($this->createOrderByInput(self::ORDER_BY, ShortUrlsParams::ORDERABLE_FIELDS));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user