Skip to content

Commit

Permalink
retreive updated records only
Browse files Browse the repository at this point in the history
  • Loading branch information
bakkerpeter committed Mar 29, 2016
1 parent 4196315 commit af8bab5
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/models/Stock.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,4 +34,13 @@ class Stock extends Model {
*/
protected $findMethod = 'GET';

/**
* Returns the updated stock items only
* @return Stock[]
*/
public function getUpdates() {
//Change the find action to false to receive the updated records only
$this->findAction = 'bulk/false';
return $this->findAll();
}
}

0 comments on commit af8bab5

Please sign in to comment.