Added sending email with template from database with optional caching support

Added functionality of ``post_office`` to send email with templates. Templates are stored in the database and can be further optimized by the optional basic caching support