mirror of
https://github.com/opelly27/WinStudentGoalTracker.git
synced 2026-05-20 02:57:36 +00:00
Changed grad date to next iep date
This commit is contained in:
@@ -28,7 +28,7 @@ BEGIN
|
||||
('e5f6a7b8-0002-4000-a000-000000000001', 'd4e5f6a7-0002-4000-a000-000000000001', 'b2c3d4e5-0001-4000-a000-000000000001', 'c3d4e5f6-0004-4000-a000-000000000001', 1, 'active', UTC_TIMESTAMP()),
|
||||
('e5f6a7b8-0003-4000-a000-000000000001', 'd4e5f6a7-0003-4000-a000-000000000001', 'b2c3d4e5-0001-4000-a000-000000000001', 'c3d4e5f6-0005-4000-a000-000000000001', 1, 'active', UTC_TIMESTAMP());
|
||||
-- 6. STUDENTS
|
||||
INSERT INTO student (id_student, id_program, identifier, program_year, enrollment_date, expected_grad, created_at) VALUES
|
||||
INSERT INTO student (id_student, id_program, identifier, program_year, enrollment_date, next_iep_date, created_at) VALUES
|
||||
('f6a7b8c9-0001-4000-a000-000000000001', 'b2c3d4e5-0001-4000-a000-000000000001', 'STU-001', 1, '2025-09-01', '2029-06-15', UTC_TIMESTAMP()),
|
||||
('f6a7b8c9-0002-4000-a000-000000000001', 'b2c3d4e5-0001-4000-a000-000000000001', 'STU-002', 1, '2025-09-01', '2029-06-15', UTC_TIMESTAMP()),
|
||||
('f6a7b8c9-0003-4000-a000-000000000001', 'b2c3d4e5-0001-4000-a000-000000000001', 'STU-003', 2, '2024-09-01', '2028-06-15', UTC_TIMESTAMP()),
|
||||
|
||||
@@ -4,7 +4,7 @@ BEGIN
|
||||
SELECT
|
||||
studentId,
|
||||
identifier,
|
||||
expectedGradDate,
|
||||
nextIepDate,
|
||||
lastEntryDate,
|
||||
goalCount,
|
||||
progressEventCount
|
||||
|
||||
@@ -4,7 +4,7 @@ BEGIN
|
||||
SELECT
|
||||
studentId,
|
||||
identifier,
|
||||
expectedGradDate,
|
||||
nextIepDate,
|
||||
lastEntryDate,
|
||||
goalCount,
|
||||
progressEventCount
|
||||
|
||||
@@ -8,7 +8,7 @@ BEGIN
|
||||
SELECT
|
||||
vc.studentId,
|
||||
vc.identifier,
|
||||
vc.expectedGradDate,
|
||||
vc.nextIepDate,
|
||||
vc.lastEntryDate,
|
||||
vc.goalCount,
|
||||
vc.progressEventCount
|
||||
|
||||
@@ -6,7 +6,7 @@ CREATE DEFINER=`root`@`%` PROCEDURE `sp_Student_Insert`(
|
||||
IN p_identifier VARCHAR(50),
|
||||
IN p_program_year INT,
|
||||
IN p_enrollment_date DATE,
|
||||
IN p_expected_grad DATE
|
||||
IN p_next_iep_date DATE
|
||||
)
|
||||
BEGIN
|
||||
INSERT INTO student
|
||||
@@ -16,7 +16,7 @@ BEGIN
|
||||
identifier,
|
||||
program_year,
|
||||
enrollment_date,
|
||||
expected_grad,
|
||||
next_iep_date,
|
||||
created_at
|
||||
)
|
||||
VALUES
|
||||
@@ -26,7 +26,7 @@ BEGIN
|
||||
p_identifier,
|
||||
p_program_year,
|
||||
p_enrollment_date,
|
||||
p_expected_grad,
|
||||
p_next_iep_date,
|
||||
UTC_TIMESTAMP()
|
||||
);
|
||||
INSERT INTO user_student (id_user_student, id_user, id_student, is_primary)
|
||||
@@ -37,7 +37,7 @@ BEGIN
|
||||
identifier,
|
||||
program_year,
|
||||
enrollment_date,
|
||||
expected_grad,
|
||||
next_iep_date,
|
||||
created_at
|
||||
FROM student
|
||||
WHERE id_student = p_id_student
|
||||
|
||||
@@ -4,7 +4,7 @@ CREATE DEFINER=`root`@`%` PROCEDURE `sp_Student_Update`(
|
||||
IN p_identifier VARCHAR(50),
|
||||
IN p_program_year INT,
|
||||
IN p_enrollment_date DATE,
|
||||
IN p_expected_grad DATE
|
||||
IN p_next_iep_date DATE
|
||||
)
|
||||
BEGIN
|
||||
UPDATE student
|
||||
@@ -12,7 +12,7 @@ BEGIN
|
||||
identifier = COALESCE(p_identifier, identifier),
|
||||
program_year = COALESCE(p_program_year, program_year),
|
||||
enrollment_date = COALESCE(p_enrollment_date, enrollment_date),
|
||||
expected_grad = COALESCE(p_expected_grad, expected_grad)
|
||||
next_iep_date = COALESCE(p_next_iep_date, next_iep_date)
|
||||
WHERE id_student = p_id_student;
|
||||
SELECT ROW_COUNT() AS rows_affected;
|
||||
END;;
|
||||
|
||||
@@ -4,7 +4,7 @@ CREATE TABLE `student` (
|
||||
`identifier` varchar(50) DEFAULT NULL,
|
||||
`program_year` int DEFAULT NULL,
|
||||
`enrollment_date` date DEFAULT NULL,
|
||||
`expected_grad` date DEFAULT NULL,
|
||||
`next_iep_date` date DEFAULT NULL,
|
||||
`created_at` timestamp NULL DEFAULT NULL,
|
||||
PRIMARY KEY (`id_student`),
|
||||
KEY `student_ibfk_1` (`id_program`),
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`%` SQL SECURITY DEFINER VIEW `winstudentgoaltracker`.`v_student_card` AS
|
||||
select `s`.`id_student` AS `studentId`,`s`.`identifier` AS `identifier`,`s`.`expected_grad` AS `expectedGradDate`,max(`pe`.`created_at`) AS `lastEntryDate`,count(distinct `g`.`id_goal`) AS `goalCount`,count(distinct `pe`.`id_progress_event`) AS `progressEventCount`
|
||||
select `s`.`id_student` AS `studentId`,`s`.`identifier` AS `identifier`,`s`.`next_iep_date` AS `nextIepDate`,max(`pe`.`created_at`) AS `lastEntryDate`,count(distinct `g`.`id_goal`) AS `goalCount`,count(distinct `pe`.`id_progress_event`) AS `progressEventCount`
|
||||
from ((`winstudentgoaltracker`.`student` `s`
|
||||
left
|
||||
join `winstudentgoaltracker`.`goal` `g` on((`g`.`id_student` = `s`.`id_student`)))
|
||||
left
|
||||
join `winstudentgoaltracker`.`progress_event` `pe` on((`pe`.`id_goal` = `g`.`id_goal`))) group by `s`.`id_student`,`s`.`identifier`,`s`.`expected_grad`;
|
||||
join `winstudentgoaltracker`.`progress_event` `pe` on((`pe`.`id_goal` = `g`.`id_goal`))) group by `s`.`id_student`,`s`.`identifier`,`s`.`next_iep_date`;
|
||||
|
||||
Reference in New Issue
Block a user