コード例 #1
0
ファイル: AbstractModel.php プロジェクト: sumiyoshi/BokunoZF2
 /**
  * @return bool
  */
 public function isSetPrimaryKey()
 {
     $primaryKey = $this->entity->getPrimaryKeys();
     $_entities = $this->getEntity();
     $bool = true;
     foreach ($primaryKey as $key) {
         if (empty($_entities[$key])) {
             $bool = false;
             break;
         }
     }
     return $bool;
 }
コード例 #2
0
ファイル: AbstractTable.php プロジェクト: sumiyoshi/BokunoZF2
 /**
  * @return array
  */
 public function getPrimaryKeys()
 {
     return $this->entity->getPrimaryKeys();
 }