diff --git a/modules/api/php/endpoints/candidate/visit/image/qc.class.inc b/modules/api/php/endpoints/candidate/visit/image/qc.class.inc index 2072779b2b6..0bcd2e939a9 100644 --- a/modules/api/php/endpoints/candidate/visit/image/qc.class.inc +++ b/modules/api/php/endpoints/candidate/visit/image/qc.class.inc @@ -165,7 +165,7 @@ class Qc extends Endpoint implements \LORIS\Middleware\ETagCalculator ); } - $inputqcstatus = $data['QCStatus'] ?? null; + $inputqcstatus = $data['QC'] ?? null; $inputselected = $data['Selected'] ?? null; // TODO :: This is (and was) not checking or handling Caveats diff --git a/modules/mri_violations/php/mri_violations.class.inc b/modules/mri_violations/php/mri_violations.class.inc index 71a8797fe66..9daeefcdcc7 100644 --- a/modules/mri_violations/php/mri_violations.class.inc +++ b/modules/mri_violations/php/mri_violations.class.inc @@ -144,7 +144,11 @@ class Mri_Violations extends \DataFrameworkMenu ); default: return (new Provisioner()) - ->filter(new UserCenterMatchOrNull()) + ->filter( + new UserCenterMatchOrNullOrAnyPermission( + $this->allSitePermissionNames(), + ) + ) ->filter(new UserProjectMatchOrNull()); } } diff --git a/raisinbread/test/api/LorisApiImagesTest.php b/raisinbread/test/api/LorisApiImagesTest.php index af068ac177a..576954b4043 100644 --- a/raisinbread/test/api/LorisApiImagesTest.php +++ b/raisinbread/test/api/LorisApiImagesTest.php @@ -137,7 +137,7 @@ public function testGetCandidatesCandidVisitImagesFilename(): void ), true ); - $this->assertEquals(null, $imagesArray); + $this->assertEquals(null, $imagesArray); } /** @@ -286,7 +286,7 @@ public function testPutCandidatesCandidVisitImagesFilenameQc(): void 'Visit' => $visit, 'File' => $filename ], - "QC" => 'pass', + "QC" => 'Pass', "Selected" => false, 'Caveats' => [ '0' => [ @@ -335,7 +335,7 @@ public function testGetCandidatesCandidVisitImagesFilenameFormatBbrowser(): void "candidates/$this->candidTest/$this->visitTest/images/" . "$this->imagefileTest/format/brainbrowser" ); - } + } $this->assertEquals(200, $response->getStatusCode()); // Verify the endpoint has a body $body = $response->getBody(); @@ -401,7 +401,7 @@ public function testGetCandidatesCandidVisitImagesFilenameFormatBbrowser(): void $this->assertArrayHasKey('zspace', $imagesArray); $this->assertArrayHasKey('space_length', $imagesArray['zspace']); $this->assertArrayHasKey('start', $imagesArray['zspace']); - $this->assertArrayHasKey('step', $imagesArray['zspace']); + $this->assertArrayHasKey('step', $imagesArray['zspace']); } /** diff --git a/raisinbread/test/api/LorisApiImages_v0_0_3_Test.php b/raisinbread/test/api/LorisApiImages_v0_0_3_Test.php index c6b65abde60..079a3e7be55 100644 --- a/raisinbread/test/api/LorisApiImages_v0_0_3_Test.php +++ b/raisinbread/test/api/LorisApiImages_v0_0_3_Test.php @@ -136,7 +136,7 @@ public function testGetCandidatesCandidVisitImagesFilename(): void ), true ); - $this->assertEquals(null, $imagesArray); + $this->assertEquals(null, $imagesArray); } /** @@ -285,7 +285,7 @@ public function testPutCandidatesCandidVisitImagesFilenameQc(): void 'Visit' => $visit, 'File' => $filename ], - "QC" => 'pass', + "QC" => 'Pass', "Selected" => false, 'Caveats' => [ '0' => [ @@ -334,7 +334,7 @@ public function testGetCandidatesCandidVisitImagesFilenameFormatBbrowser(): void "candidates/$this->candidTest/$this->visitTest/images/" . "$this->imagefileTest/format/brainbrowser" ); - } + } $this->assertEquals(200, $response->getStatusCode()); // Verify the endpoint has a body $body = $response->getBody(); @@ -400,7 +400,7 @@ public function testGetCandidatesCandidVisitImagesFilenameFormatBbrowser(): void $this->assertArrayHasKey('zspace', $imagesArray); $this->assertArrayHasKey('space_length', $imagesArray['zspace']); $this->assertArrayHasKey('start', $imagesArray['zspace']); - $this->assertArrayHasKey('step', $imagesArray['zspace']); + $this->assertArrayHasKey('step', $imagesArray['zspace']); } /**