El Tue, 10 Nov 2009 10:31:13 -0800 (PST)
deostroll escribió:
> Is there a recommended way to do this...?
Yeah: write an instance method in your "Stock" class (model) that returns
exactly that and call it from the template.
Remember: there shouldn't be any data processing in the presentation la
Hi,
In my db I hve some fields like 'price' and 'quantity'. In one record
of data I want to display the 'price x quantity'...I tried something
like this:
{{ stock.price * stock.quantity }}
...and got error. Is there a recommended way to do this...?
--deostroll
--~--~-~--~~-
2 matches
Mail list logo