mirror of
https://github.com/crocofied/CoreControl.git
synced 2025-12-17 15:36:50 +00:00
Sort Sites & Networks alphabetically
This commit is contained in:
parent
56571ba65a
commit
9851c872ca
@ -15,7 +15,11 @@ export async function GET(request: NextRequest) {
|
|||||||
id: Number(siteId),
|
id: Number(siteId),
|
||||||
},
|
},
|
||||||
include: {
|
include: {
|
||||||
networks: true, // Include all network relationships
|
networks: {
|
||||||
|
orderBy: {
|
||||||
|
name: 'asc',
|
||||||
|
},
|
||||||
|
},
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
@ -30,8 +30,15 @@ export async function GET(request: NextRequest) {
|
|||||||
mode: "insensitive",
|
mode: "insensitive",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
orderBy: {
|
||||||
|
name: 'asc',
|
||||||
|
},
|
||||||
include: {
|
include: {
|
||||||
networks: true,
|
networks: {
|
||||||
|
orderBy: {
|
||||||
|
name: 'asc',
|
||||||
|
},
|
||||||
|
},
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
const total = await prisma.site.count({
|
const total = await prisma.site.count({
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user