/// <summary>
 /// Sends the order received notification to merchant.
 /// </summary>
 /// <param name="order">The order.</param>
 public void SendOrderReceivedNotificationToMerchant(Order order)
 {
     Notification notification = new Notification((int)SystemNotifications.OrderReceivedToMerchant);
       string notificationBody = HttpUtility.HtmlDecode(notification.NotificationBody);
       if (!string.IsNullOrEmpty(notificationBody)) {
     notificationBody = ReplaceConstantsInNotification(order, notificationBody, notification);
     Email email = new Email();
     email.Send(notification.FromEmail, notification.ToList, notification.Subject, notificationBody, true);
       }
 }
        /// <summary>
        /// Handles the Click event of the btnSend control.
        /// </summary>
        /// <param name="sender">The source of the event.</param>
        /// <param name="e">The <see cref="System.EventArgs"/> instance containing the event data.</param>
        protected void btnSend_Click(object sender, EventArgs e)
        {
            MailSettings mail = MessagingCache.GetMailSettings(); //TODO: Cache?
              MailMessage mailMessage = new MailMessage();
              mailMessage.From = new MailAddress(txtEmail.Text.Trim(), txtName.Text.Trim());
              mailMessage.To.Add(new MailAddress(mail.Contact));
              mailMessage.Subject = txtSubject.Text.Trim();
              mailMessage.Body = txtMessage.Text.Trim();
              mailMessage.IsBodyHtml = false;

              Email email = new Email();
              email.Send(mailMessage);
              lblSent.Visible = true;
        }
 /// <summary>
 /// Sends the specified mail message.
 /// </summary>
 /// <param name="mailMessage">The mail message.</param>
 public void Send(MailMessage mailMessage)
 {
     Email email = new Email();
       email.Send(mailMessage);
 }
        /// <summary>
        /// Sends the notification to customer.
        /// </summary>
        /// <param name="order">The order.</param>
        /// <param name="systemNotification">The system notification.</param>
        private void SendNotificationToCustomer(Order order, SystemNotifications systemNotification)
        {
            Notification notification = new Notification((int)systemNotification);

              string notificationBody = HttpUtility.HtmlDecode(notification.NotificationBody);
              if (!string.IsNullOrEmpty(notificationBody)) {
            //run the tag replacements
            notificationBody = ReplaceConstantsInNotification(order, notificationBody, notification);
            Email email = new Email();
            email.Send(notification.FromEmail, order.BillingAddress.Email, notification.CcList, notification.Subject, notificationBody, true);
              }
        }