Skip to content

Commit

Permalink
+ Collection::getIds
Browse files Browse the repository at this point in the history
  • Loading branch information
hiqsol committed Jul 30, 2015
1 parent eb75e05 commit e054b8c
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions Collection.php
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,15 @@ public function getModel () {
return $this->model;
}

public function getIds()
{
$ids = [];
foreach ($this->models as $model) {
$ids[] = $model->id;
}
return $ids;
}

/**
* Sets the scenario of the default model
*
Expand Down

0 comments on commit e054b8c

Please sign in to comment.