mirror of
https://github.com/open-webui/open-webui.git
synced 2026-07-18 10:48:00 -05:00
refac
This commit is contained in:
@@ -48,9 +48,7 @@
|
|||||||
$: if (query !== undefined) {
|
$: if (query !== undefined) {
|
||||||
clearTimeout(searchDebounceTimer);
|
clearTimeout(searchDebounceTimer);
|
||||||
searchDebounceTimer = setTimeout(() => {
|
searchDebounceTimer = setTimeout(() => {
|
||||||
if (loaded) {
|
init();
|
||||||
init();
|
|
||||||
}
|
|
||||||
}, 300);
|
}, 300);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -58,7 +56,7 @@
|
|||||||
clearTimeout(searchDebounceTimer);
|
clearTimeout(searchDebounceTimer);
|
||||||
});
|
});
|
||||||
|
|
||||||
$: if (loaded && viewOption !== undefined) {
|
$: if (viewOption !== undefined) {
|
||||||
init();
|
init();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -77,6 +75,8 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
const init = async () => {
|
const init = async () => {
|
||||||
|
if (!loaded) return;
|
||||||
|
|
||||||
reset();
|
reset();
|
||||||
await getItemsPage();
|
await getItemsPage();
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -85,6 +85,8 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
const getModelList = async () => {
|
const getModelList = async () => {
|
||||||
|
if (!loaded) return;
|
||||||
|
|
||||||
try {
|
try {
|
||||||
const res = await getWorkspaceModels(
|
const res = await getWorkspaceModels(
|
||||||
localStorage.token,
|
localStorage.token,
|
||||||
|
|||||||
Reference in New Issue
Block a user