forked from CSI-KJSCE/appointment_to_examiner
filter
This commit is contained in:
@@ -99,15 +99,20 @@ const CourseForm = () => {
|
||||
await updateCourseStatus(course?.courseId || id);
|
||||
console.log("Form submitted successfully:", payload);
|
||||
|
||||
const filteredCourses = JSON.parse(localStorage.getItem("filteredCourses")) || [];
|
||||
|
||||
// Redirect to courses page after successful submission
|
||||
navigate("/courses", {
|
||||
state: {
|
||||
courses: filteredCourses,
|
||||
updatedCourse: {
|
||||
...course,
|
||||
status: "Submitted",
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
|
||||
} catch (error) {
|
||||
console.error("Failed to save appointment:", error);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user