diff --git a/application/api/user/routes.py b/application/api/user/routes.py
index de5a3c07..4ab0d007 100644
--- a/application/api/user/routes.py
+++ b/application/api/user/routes.py
@@ -37,6 +37,12 @@ def delete_conversation():
return {"status": "ok"}
+@user.route("/api/delete_all_conversations", methods=["POST"])
+def delete_all_conversations():
+ user_id = "local"
+ conversations_collection.delete_many({"user":user_id})
+ return {"status": "ok"}
+
@user.route("/api/get_conversations", methods=["get"])
def get_conversations():
# provides a list of conversations
diff --git a/frontend/package.json b/frontend/package.json
index 6e8d8e60..5c6ef827 100644
--- a/frontend/package.json
+++ b/frontend/package.json
@@ -58,4 +58,5 @@
"vite": "^5.0.13",
"vite-plugin-svgr": "^4.2.0"
}
+
}
diff --git a/frontend/src/Modal/index.tsx b/frontend/src/Modal/index.tsx
index ff3ed075..bc5f0254 100644
--- a/frontend/src/Modal/index.tsx
+++ b/frontend/src/Modal/index.tsx
@@ -8,7 +8,9 @@ interface ModalProps {
modalState: string;
isError: boolean;
errorMessage?: string;
+ textDelete?: boolean;
}
+
const Modal = (props: ModalProps) => {
return (
{
onClick={() => props.handleSubmit()}
className="ml-auto h-10 w-20 rounded-3xl bg-violet-800 text-white transition-all hover:bg-violet-700"
>
- Save
+ {props.textDelete ? 'Delete' : 'Save'}
{props.isCancellable && (