thelia loop with currency - TODO : best price whin in AND max args

This commit is contained in:
Etienne Roudeix
2013-09-10 18:58:21 +02:00
parent affc6805c5
commit 6187dbae22
5 changed files with 167 additions and 73 deletions

View File

@@ -80,4 +80,18 @@ class Currency extends BaseCurrency {
{
$this->dispatchEvent(TheliaEvents::AFTER_DELETECURRENCY, new CurrencyEvent($this));
}
/**
* Get the [rate] column value.
*
* @return double
*/
public function getRate()
{
if(false === filter_var($this->rate, FILTER_VALIDATE_FLOAT)) {
throw new PropelException('Currency::rate is not float value');
}
return $this->rate;
}
}