/** * The function returns Product object for current Item. * * @access public * @return object The Product object. */ public function getProduct() { if ($this->cachedProduct === null) { $Product = new Product_Unit(); $this->cachedProduct = $Product->findItem(array('Id = ' . $this->Product)); } return $this->cachedProduct; }
public function getUnit() { $Unit = new Product_Unit(); return $Unit->findItem(array('Id = ' . $this->Unit)); }