diff --git a/src/Components/DataPoints/DataPoints.jsx b/src/Components/DataPoints/DataPoints.jsx index 5a1a80b..a9c9499 100644 --- a/src/Components/DataPoints/DataPoints.jsx +++ b/src/Components/DataPoints/DataPoints.jsx @@ -9,7 +9,7 @@ import React, {useEffect, useState} from "react"; import { Accordion, AccordionDetails, AccordionSummary, Button, Chip, Dialog, DialogActions, - DialogContent, IconButton, Paper, Tooltip, Typography, useTheme, + DialogContent, IconButton, Paper, Tooltip, useTheme, } from "@mui/material"; import { Check, @@ -208,7 +208,7 @@ export function DataGrid({records, insideProgramPage, style = {}}) { maxWidth: "9rem", height: '1.6rem' }} - onClick={() => navigate(`/datapoints/program/${rowData.ProgramID}`)} + onClick={() => navigate(`/datapoints/program/${encodeURIComponent(rowData.ProgramID)}`)} /> ) diff --git a/src/Components/Profile/ProfileApplicant/ProfileApplicantPage.jsx b/src/Components/Profile/ProfileApplicant/ProfileApplicantPage.jsx index bf29030..f82f09a 100644 --- a/src/Components/Profile/ProfileApplicant/ProfileApplicantPage.jsx +++ b/src/Components/Profile/ProfileApplicant/ProfileApplicantPage.jsx @@ -736,7 +736,7 @@ function RecordBlock({Records, ApplicantID, editable}) { + to={`/profile/${record.ApplicantID}/${encodeURIComponent(record.ProgramID)}/edit`}> diff --git a/src/Components/ProgramPage/ProgramContent/ProgramContent.jsx b/src/Components/ProgramPage/ProgramContent/ProgramContent.jsx index 56d8bb8..b0d30f8 100644 --- a/src/Components/ProgramPage/ProgramContent/ProgramContent.jsx +++ b/src/Components/ProgramPage/ProgramContent/ProgramContent.jsx @@ -13,7 +13,7 @@ import {DraggableFAB} from "../../common"; import StarButton from "./StarButton" export async function loader({params}) { - const programId = params.programId; + const programId = decodeURIComponent(params.programId); let records = await getRecordByProgram(programId); records = Object.values(records); try { diff --git a/src/Components/ProgramPage/SideBar/SideBar.jsx b/src/Components/ProgramPage/SideBar/SideBar.jsx index 4c99171..2897dc4 100644 --- a/src/Components/ProgramPage/SideBar/SideBar.jsx +++ b/src/Components/ProgramPage/SideBar/SideBar.jsx @@ -160,7 +160,7 @@ export function ProgramButton({program, selectProgram, setSelectProgram}) { selected={program.ProgramID === selectProgram} component={Link} onClick={() => setSelectProgram(program.ProgramID)} - to={`/programs/${program.ProgramID}${window.location.search}`} + to={`/programs/${encodeURIComponent(program.ProgramID)}${window.location.search}`} sx={{ pl: "3rem", "&::before": {