mirror of
https://github.com/danswer-ai/danswer.git
synced 2025-07-04 19:50:57 +02:00
Fix failed docs table (#4800)
* Fix initial LLM provider set up * Fix IndexAttemptErrorsModal pagination
This commit is contained in:
@ -403,7 +403,7 @@ def get_docs_sync_status(
|
|||||||
def get_cc_pair_indexing_errors(
|
def get_cc_pair_indexing_errors(
|
||||||
cc_pair_id: int,
|
cc_pair_id: int,
|
||||||
include_resolved: bool = Query(False),
|
include_resolved: bool = Query(False),
|
||||||
page: int = Query(0, ge=0),
|
page_num: int = Query(0, ge=0),
|
||||||
page_size: int = Query(10, ge=1, le=100),
|
page_size: int = Query(10, ge=1, le=100),
|
||||||
_: User = Depends(current_curator_or_admin_user),
|
_: User = Depends(current_curator_or_admin_user),
|
||||||
db_session: Session = Depends(get_session),
|
db_session: Session = Depends(get_session),
|
||||||
@ -413,7 +413,7 @@ def get_cc_pair_indexing_errors(
|
|||||||
Args:
|
Args:
|
||||||
cc_pair_id: ID of the connector-credential pair to get errors for
|
cc_pair_id: ID of the connector-credential pair to get errors for
|
||||||
include_resolved: Whether to include resolved errors in the results
|
include_resolved: Whether to include resolved errors in the results
|
||||||
page: Page number for pagination, starting at 0
|
page_num: Page number for pagination, starting at 0
|
||||||
page_size: Number of errors to return per page
|
page_size: Number of errors to return per page
|
||||||
_: Current user, must be curator or admin
|
_: Current user, must be curator or admin
|
||||||
db_session: Database session
|
db_session: Database session
|
||||||
@ -431,7 +431,7 @@ def get_cc_pair_indexing_errors(
|
|||||||
db_session=db_session,
|
db_session=db_session,
|
||||||
cc_pair_id=cc_pair_id,
|
cc_pair_id=cc_pair_id,
|
||||||
unresolved_only=not include_resolved,
|
unresolved_only=not include_resolved,
|
||||||
page=page,
|
page=page_num,
|
||||||
page_size=page_size,
|
page_size=page_size,
|
||||||
)
|
)
|
||||||
return PaginatedReturn(
|
return PaginatedReturn(
|
||||||
|
@ -114,8 +114,8 @@ export default function IndexAttemptErrorsModal({
|
|||||||
<div className="flex-1 flex justify-center mb-2">
|
<div className="flex-1 flex justify-center mb-2">
|
||||||
<PageSelector
|
<PageSelector
|
||||||
totalPages={totalPages}
|
totalPages={totalPages}
|
||||||
currentPage={currentPage + 1}
|
currentPage={currentPage}
|
||||||
onPageChange={(page) => onPageChange(page - 1)}
|
onPageChange={(page) => onPageChange(page)}
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
|
@ -136,6 +136,7 @@ import {
|
|||||||
import { ChatSearchModal } from "./chat_search/ChatSearchModal";
|
import { ChatSearchModal } from "./chat_search/ChatSearchModal";
|
||||||
import { ErrorBanner } from "./message/Resubmit";
|
import { ErrorBanner } from "./message/Resubmit";
|
||||||
import MinimalMarkdown from "@/components/chat/MinimalMarkdown";
|
import MinimalMarkdown from "@/components/chat/MinimalMarkdown";
|
||||||
|
import { WelcomeModal } from "@/components/initialSetup/welcome/WelcomeModal";
|
||||||
|
|
||||||
const TEMP_USER_MESSAGE_ID = -1;
|
const TEMP_USER_MESSAGE_ID = -1;
|
||||||
const TEMP_ASSISTANT_MESSAGE_ID = -2;
|
const TEMP_ASSISTANT_MESSAGE_ID = -2;
|
||||||
@ -2327,6 +2328,8 @@ export function ChatPage({
|
|||||||
/>
|
/>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
|
{shouldShowWelcomeModal && <WelcomeModal user={user} />}
|
||||||
|
|
||||||
{/* ChatPopup is a custom popup that displays a admin-specified message on initial user visit.
|
{/* ChatPopup is a custom popup that displays a admin-specified message on initial user visit.
|
||||||
Only used in the EE version of the app. */}
|
Only used in the EE version of the app. */}
|
||||||
{popup}
|
{popup}
|
||||||
|
@ -25,7 +25,7 @@ import {
|
|||||||
} from "@/components/ui/tooltip";
|
} from "@/components/ui/tooltip";
|
||||||
import { Hoverable } from "@/components/Hoverable";
|
import { Hoverable } from "@/components/Hoverable";
|
||||||
import { ChatState } from "../types";
|
import { ChatState } from "../types";
|
||||||
import UnconfiguredProviderText from "@/components/chat/UnconfiguredProviderText";
|
import { UnconfiguredLlmProviderText } from "@/components/chat/UnconfiguredLlmProviderText";
|
||||||
import { useAssistants } from "@/components/context/AssistantsContext";
|
import { useAssistants } from "@/components/context/AssistantsContext";
|
||||||
import { CalendarIcon, TagIcon, XIcon, FolderIcon } from "lucide-react";
|
import { CalendarIcon, TagIcon, XIcon, FolderIcon } from "lucide-react";
|
||||||
import { FilterPopup } from "@/components/search/filtering/FilterPopup";
|
import { FilterPopup } from "@/components/search/filtering/FilterPopup";
|
||||||
@ -582,7 +582,9 @@ export function ChatInputBar({
|
|||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
<UnconfiguredProviderText showConfigureAPIKey={showConfigureAPIKey} />
|
<UnconfiguredLlmProviderText
|
||||||
|
showConfigureAPIKey={showConfigureAPIKey}
|
||||||
|
/>
|
||||||
<div className="w-full h-[10px]"></div>
|
<div className="w-full h-[10px]"></div>
|
||||||
<div
|
<div
|
||||||
className="
|
className="
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import { useProviderStatus } from "./ProviderContext";
|
import { useProviderStatus } from "./ProviderContext";
|
||||||
|
|
||||||
export default function CredentialNotConfigured({
|
export function UnconfiguredLlmProviderText({
|
||||||
showConfigureAPIKey,
|
showConfigureAPIKey,
|
||||||
noSources,
|
noSources,
|
||||||
}: {
|
}: {
|
Reference in New Issue
Block a user