Update template.py

Added some useful custom filters
Merge pull request #160 from asm0dey/master

Update template.py