Hi MerMer,
Generally, custom tags (and filters) fit wonderfully with Django's DRY
(don't repeat yourself) principle -- once defined, you can reuse them
easily in future applications.
That said, there's often more than one way to skin the cat in Django
and Python. For example, you could have a ge
Many thanks - I did check the docs but didn't see it in the Filter
section.
If I need something similar, which is not covered by a filter (such as
an average of columns) - what's the best way to procede. Should I:-
a) Do the calculation in the view
b) create a custom tag
c) Do something else
See: http://www.djangoproject.com/documentation/templates/#add
Use it like this:
{{ objects.cash|add:objects.cash1 }}
On Oct 9, 9:22 am, "MerMer" <[EMAIL PROTECTED]> wrote:
> Another newbie question!
>
> If I have two tags {{ objects.cash }} and another {{ objects.cash1 }}
> can I add these t
Another newbie question!
If I have two tags {{ objects.cash }} and another {{ objects.cash1 }}
can I add these together in the template?
If not which is the most appropriate way to manage something like this.
MerMer
--~--~-~--~~~---~--~~
You received this mess
4 matches
Mail list logo