implementing action email template functionality