mirror of
https://github.com/sysadminsmedia/homebox.git
synced 2025-12-24 06:28:34 +01:00
Enable Sorting on Search By Created and Updated At (#140)
- Required updating query value to use first.value to set the value of the initial sort - Ordering starts with name but can be changed to createdAt or updatedAt by the user
This commit is contained in:
@@ -32,7 +32,7 @@ export function useRouteQuery(q: string, def: any): WritableComputedRef<any> {
|
||||
case "string":
|
||||
return computed({
|
||||
get: () => {
|
||||
const qv = route.query[q];
|
||||
const qv = first.value;
|
||||
if (Array.isArray(qv)) {
|
||||
return qv[0];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user