Parcourir la source

修正列操作getKey

lila il y a 4 ans
Parent
commit
7352225f04
1 fichiers modifiés avec 1 ajouts et 1 suppressions
  1. 1 1
      src/Grid/RowAction.php

+ 1 - 1
src/Grid/RowAction.php

@@ -24,7 +24,7 @@ abstract class RowAction extends GridAction
     public function getKey()
     {
         if ($this->row) {
-            return $this->row->get($this->parent->getKeyName());
+            return $this->row->{$this->parent->getKeyName()};
         }
 
         return parent::getKey();