Example #1
0
 /**
  * @see	RM_Purchase_Mapper::table()
  **/
 public function table($name)
 {
     return $this->_mapper->table($name);
 }
Example #2
0
 /**
  * Enter description here...
  *
  * @return float
  */
 public function getReceiptTotalVirtual()
 {
     $s = iterFirst(M('Store')->requestQuery(M('Store')->factorySimple(), M('Db')->createQuery($this->_mapper->table('purchase'))->what('SUM(price) AS s')->where('receipt_id = ? AND is_deleted != 1', $this->id())));
     return @$s['s'] ? $s['s'] : 0;
 }