Guest User

Untitled

a guest
May 23rd, 2018
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.44 KB | None | 0 0
  1. public function setCollection($collection)
  2. {
  3. $this->_collection = $collection;
  4. $this->_collection->getSelect()->where("type_id = 'simple' AND price > 0");
  5. return $this;
  6. }
  7.  
  8. public function getSize()
  9. {
  10. if (is_null($this->_totalRecords)) {
  11.  
  12. $sql = $this->getSelectCountSql();
  13.  
  14. $this->_totalRecords = $this->getConnection()->fetchOne($sql, $this->_bindParams);
  15.  
  16. }
  17. return intval($this->_totalRecords);
  18. }
Add Comment
Please, Sign In to add comment