From 2682e9784f743167580697e2f44f1970953d099c Mon Sep 17 00:00:00 2001 From: daviddasilva Date: Mon, 21 Aug 2023 21:00:37 -0400 Subject: [PATCH 1/2] Disabled next-auth & added databases tab --- app/app/databases/page.js | 9 +++++++++ app/app/layout.js | 8 ++++---- lib/sidebar.js | 29 ++++++++++++++++++----------- 3 files changed, 31 insertions(+), 15 deletions(-) create mode 100644 app/app/databases/page.js diff --git a/app/app/databases/page.js b/app/app/databases/page.js new file mode 100644 index 0000000..9d4efe6 --- /dev/null +++ b/app/app/databases/page.js @@ -0,0 +1,9 @@ + +export const metadata = { + title: "Databases", + description: "Manage your databases", +}; + +export default function DatabasesPage() { + return
Databases page
; +} diff --git a/app/app/layout.js b/app/app/layout.js index dd87636..e7099b5 100644 --- a/app/app/layout.js +++ b/app/app/layout.js @@ -9,11 +9,11 @@ export const metadata = { }; export default async function AppLayout({ children }) { - const session = await getServerSession(authOptions); + // const session = await getServerSession(authOptions); - if (!session) { - redirect("/"); - } + // if (!session) { + // redirect("/"); + // } return {children}; } diff --git a/lib/sidebar.js b/lib/sidebar.js index fa7379f..79f6de3 100644 --- a/lib/sidebar.js +++ b/lib/sidebar.js @@ -27,13 +27,13 @@ export const useSidebar = () => { icon: TbHome, placement: PLACEMENT.top, }, - { - id: "datasources", - label: "Datasources", - href: "/app/datasources", - icon: TbDatabase, - placement: PLACEMENT.top, - }, + // { + // id: "datasources", + // label: "Datasources", + // href: "/app/datasources", + // icon: TbDatabase, + // placement: PLACEMENT.top, + // }, { id: "prompt_templates", label: "Prompt templates", @@ -41,11 +41,18 @@ export const useSidebar = () => { icon: TbPrompt, placement: PLACEMENT.top, }, + // { + // id: "chatbots", + // label: "Chatbots", + // href: "/app/chatbots", + // icon: TbMessage, + // placement: PLACEMENT.top, + // }, { - id: "chatbots", - label: "Chatbots", - href: "/app/chatbots", - icon: TbMessage, + id: "databases", + label: "Databases", + href: "/app/databases", + icon: TbDatabase, placement: PLACEMENT.top, }, { From 4c9e8c7c7195fad15c57627a3d7641ea7dd3b885 Mon Sep 17 00:00:00 2001 From: daviddasilva Date: Mon, 21 Aug 2023 21:12:30 -0400 Subject: [PATCH 2/2] commented out unused imports --- app/app/layout.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/app/layout.js b/app/app/layout.js index e7099b5..fb9ba7a 100644 --- a/app/app/layout.js +++ b/app/app/layout.js @@ -1,6 +1,6 @@ -import { getServerSession } from "next-auth/next"; -import { redirect } from "next/navigation"; -import { authOptions } from "pages/api/auth/[...nextauth]"; +// import { getServerSession } from "next-auth/next"; +// import { redirect } from "next/navigation"; +// import { authOptions } from "pages/api/auth/[...nextauth]"; import AppContainer from "./container"; export const metadata = {