mirror of
https://github.com/appwrite/console.git
synced 2026-11-18 20:47:21 +00:00
add: teamId filter to org domains.
This commit is contained in:
1 parent
ab4a73bbcd
commit
177cdcdaad
1 file changed
+5
-1
@@ -4,14 +4,17 @@ import { getLimit, getPage, getQuery, getSearch, pageToOffset } from '$lib/helpe
|
||||
import { Dependencies, PAGE_LIMIT } from '$lib/constants';
|
||||
import { queries, queryParamToMap } from '$lib/components/filters';
|
||||
|
||||
export const load = async ({ depends, url, route }) => {
|
||||
export const load = async ({ depends, url, route, parent }) => {
|
||||
depends(Dependencies.DOMAINS);
|
||||
|
||||
const page = getPage(url);
|
||||
const limit = getLimit(url, route, PAGE_LIMIT);
|
||||
const offset = pageToOffset(page, limit);
|
||||
const query = getQuery(url);
|
||||
const search = getSearch(url);
|
||||
|
||||
const { organization } = await parent();
|
||||
|
||||
const parsedQueries = queryParamToMap(query || '[]');
|
||||
queries.set(parsedQueries);
|
||||
|
||||
@@ -24,6 +27,7 @@ export const load = async ({ depends, url, route }) => {
|
||||
Query.limit(limit),
|
||||
Query.offset(offset),
|
||||
Query.orderDesc(''),
|
||||
Query.equal('teamId', [organization.$id]),
|
||||
...parsedQueries.values()
|
||||
])
|
||||
};
|
||||
|
||||
Reference in new issue
Block a user