File tree Expand file tree Collapse file tree 3 files changed +8
-5
lines changed Expand file tree Collapse file tree 3 files changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -59,7 +59,7 @@ public function setEntity(string $entity): void
5959 */
6060 public function perform ($ select ): array
6161 {
62- $ rows = $ this ->tableGateway ->selectWith ($ select );
62+ $ rows = $ this ->tableGateway ->selectWith ($ select )-> toArray () ;
6363 $ rowsToBeShown = [];
6464
6565 foreach ($ rows as $ row ) {
@@ -70,4 +70,4 @@ public function perform($select): array
7070
7171 return $ rowsToBeShown ;
7272 }
73- }
73+ }
Original file line number Diff line number Diff line change @@ -54,10 +54,12 @@ public function extract($object): array
5454
5555 foreach ($ fields as $ field ) {
5656 if (!$ field ->isForeignKey () && !$ field ->isCollection ()){
57- $ array [$ field ->getAlias ()] = $ reflection ->getProperty ($ field ->getProperty ())->getValue ($ object );
57+ $ property = $ reflection ->getProperty ($ field ->getProperty ());
58+ $ property ->setAccessible (true );
59+ $ array [$ field ->getAlias ()] = $ property ->getValue ($ object );
5860 }
5961 }
6062
6163 return $ array ;
6264 }
63- }
65+ }
Original file line number Diff line number Diff line change @@ -62,6 +62,7 @@ public function hydrate(array $data, $object)
6262 $ propertyName = $ property ->getName ();
6363 $ propertyConfig = $ config ->getField ($ propertyName );
6464 $ propertyAlias = $ propertyConfig ->getAlias ();
65+ $ property ->setAccessible (true );
6566
6667 // Populate foreignKey
6768 if ($ propertyConfig ->isForeignKey ()) {
@@ -94,4 +95,4 @@ public function hydrate(array $data, $object)
9495
9596 return $ object ;
9697 }
97- }
98+ }
You can’t perform that action at this time.
0 commit comments