From a1db12b416ae374e401434460ee88f18f75ac98e Mon Sep 17 00:00:00 2001 From: John Hsu Date: Sun, 26 Jan 2025 21:27:30 -0800 Subject: [PATCH] FIX permission denied in canvas grade sync page On a fresh install, even superadmins will get permission denied on the Canvas grade sync page because the controller action is not in the permissions list. I've fixed the ipeer.sql and ipeer_samples_data.sql so they contain the additional permission lines. --- app/config/sql/ipeer.sql | 8 ++++++-- app/config/sql/ipeer_samples_data.sql | 8 ++++++-- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/app/config/sql/ipeer.sql b/app/config/sql/ipeer.sql index 936a3a72..c830eece 100644 --- a/app/config/sql/ipeer.sql +++ b/app/config/sql/ipeer.sql @@ -369,7 +369,10 @@ INSERT INTO acos (id, parent_id, model, foreign_key, alias, lft, rght) VALUES (331,300,NULL,NULL,'viewusername',660,661), (332,300,NULL,NULL,'submitstudenteval',662,663), (333,84,NULL,NULL,'export',193,194), -(334,84,NULL,NULL,'import',195,196); +(334,84,NULL,NULL,'import',195,196), +(335,16,NULL,NULL,'syncCanvasEnrollment',NULL,NULL), +(336,112,NULL,NULL,'syncCanvas',NULL,NULL), +(337,64,NULL,NULL,'exportCanvas',NULL,NULL); -- -------------------------------------------------------- @@ -552,7 +555,8 @@ INSERT INTO aros_acos (id, aro_id, aco_id, _create, _read, _update, _delete) VAL (118,5,300,'-1','-1','-1','-1'), (119,5,327,'1','1','1','1'), (120,5,328,'-1','-1','-1','-1'), -(121,5,329,'-1','-1','-1','-1'); +(121,5,329,'-1','-1','-1','-1'), +(122,2,309,'-1','-1','-1','-1'); -- -------------------------------------------------------- diff --git a/app/config/sql/ipeer_samples_data.sql b/app/config/sql/ipeer_samples_data.sql index dcc098ab..b996080f 100644 --- a/app/config/sql/ipeer_samples_data.sql +++ b/app/config/sql/ipeer_samples_data.sql @@ -369,7 +369,10 @@ INSERT INTO acos (id, parent_id, model, foreign_key, alias, lft, rght) VALUES (331,300,NULL,NULL,'viewusername',660,661), (332,300,NULL,NULL,'submitstudenteval',662,663), (333,84,NULL,NULL,'export',193,194), -(334,84,NULL,NULL,'import',195,196); +(334,84,NULL,NULL,'import',195,196), +(335,16,NULL,NULL,'syncCanvasEnrollment',NULL,NULL), +(336,112,NULL,NULL,'syncCanvas',NULL,NULL), +(337,64,NULL,NULL,'exportCanvas',NULL,NULL); -- -------------------------------------------------------- @@ -552,7 +555,8 @@ INSERT INTO aros_acos (id, aro_id, aco_id, _create, _read, _update, _delete) VAL (118,5,300,'-1','-1','-1','-1'), (119,5,327,'1','1','1','1'), (120,5,328,'-1','-1','-1','-1'), -(121,5,329,'-1','-1','-1','-1'); +(121,5,329,'-1','-1','-1','-1'), +(122,2,309,'-1','-1','-1','-1'); -- --------------------------------------------------------