Is there any way I can set a formatter on models that will convert negative numbers to positive numbers for all numeric fields in the model? I started out by trying to make a propel formatter but I'm not sure what code should go in format and formatOne. I have the following code.
class NegativeFormatter extends PropelFormatter
{
public function format(PropelPDO $stmt)
{
parent::format($stmt);
}
public function formatOne(PropelPDO $stmt)
{
parent::formatOne($stmt);
}
public function isObjectFormatter()
{
return true;
}
}
I ended up just doing it manually for now when doing the calculations.