I also think it's better to do the calculation in the view. But anyway, this is not of much importance.