Skip to content

Commit

Permalink
adding docs
Browse files Browse the repository at this point in the history
  • Loading branch information
robertandremitchell committed Dec 6, 2024
1 parent cf29ba1 commit 2dfe948
Showing 1 changed file with 10 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ export const UserQueriesDisplay: React.FC<UserQueriesDisplayProps> = ({
queryId: string;
} | null>(null);

// Delete existing query workflow
const handleDelete = async (queryName: string, queryId: string) => {
const result = await deleteQueryById(queryId);
if (result.success) {
Expand All @@ -61,6 +62,7 @@ export const UserQueriesDisplay: React.FC<UserQueriesDisplayProps> = ({
modalRef.current?.toggleModal();
};

// Copy ID workflow
const handleCopy = (queryName: string, queryId: string) => {
navigator.clipboard
.writeText(queryId)
Expand All @@ -75,13 +77,21 @@ export const UserQueriesDisplay: React.FC<UserQueriesDisplayProps> = ({
});
};

// Create new query workflow
const handleClick = async () => {
setLoading(true);

// Redirect to query updating/editing page
router.push("/queryBuilding/buildFromTemplates");
};

// TODO: Need to create workflow for Edit button
// It will need to direct directly to the buildFromTemplates workflow with a specified ID
// It would then render `query_data` from query_table on that page
// const handleEdit = (queryId: string) => {

// }

return (
<div>
<ToastContainer position="bottom-left" />
Expand Down

0 comments on commit 2dfe948

Please sign in to comment.