private void SendEmail_ScheduleMeeting(MeetingModel m, string recipientAddress, string firstName, string lastName)
        {
            //Using a StringBuilder is much more memory efficient than repeated concatenation.
            StringBuilder body    = new StringBuilder();
            string        subject = "New meeting scheduled";

            body.AppendLine("<h1>You have a new meeting</h1>");
            body.AppendLine("<p>Secheduled with ");
            body.AppendLine(firstName);
            body.AppendLine(" ");
            body.AppendLine(lastName);
            body.AppendLine(", on ");
            body.AppendLine(m.MeetingDate.DayOfWeek.ToString());
            body.AppendLine(" (");
            body.AppendLine(m.MeetingDate.ToShortDateString());
            body.AppendLine(") at ");
            body.AppendLine(m.MeetingTime.ToString().Substring(0, 5));
            body.AppendLine(" lasting ");
            body.AppendLine(m.MeetingLength.ToString());
            body.AppendLine(" minutes.</p>");
            body.AppendLine("<br />");
            body.AppendLine("<p>Excited to see you there!</p>");
            body.AppendLine("<p>~SecureLine</p>");

            EmailLogic.SendEmail(recipientAddress, subject, body.ToString());
        }
        private void SendEmail_AddStudent(StudentModel s)
        {
            StringBuilder body    = new StringBuilder();
            string        subject = "Welcome to SecureLine!";

            body.AppendLine("<h2>Your account has been created.</h2>");
            body.AppendLine("<p>Hi ");
            body.AppendLine(s.StudentFirstName);
            body.AppendLine(", ");
            body.AppendLine("your login details for SecureLine are listed below.</p>");
            body.AppendLine("Username: "******"<br />");
            body.AppendLine("Password: "******"<br />");

            body.AppendLine("<p>SecureLine can be used to book meetings with the Hills Road Well-Being Department, view upcoming meetings or to simply discuss your worries with the well-being staff.</p>");
            body.AppendLine("You can update your password from within the SecureLine application.");
            body.AppendLine("<br />");
            body.AppendLine("Remember to keep your information private.");
            body.AppendLine("<p>~SecureLine</p>");

            EmailLogic.SendEmail(s.StudentEmail, subject, body.ToString());
        }
        private void SendEmail_CancelMeeting(string recipientAddress, string firstName, string lastName, MeetingModel m)
        {
            //StringBuilder is used as it is much more
            //memory efficient than concatenation
            StringBuilder body    = new StringBuilder();
            string        subject = "Upcoming meeting cancelled";

            //HTML tags used to format the e-mail
            body.AppendLine("<h1>Meeting cancelled</h1>");
            body.AppendLine("<p>Your meeting scheduled with ");
            body.AppendLine(firstName);
            body.AppendLine(" ");
            body.AppendLine(lastName);
            body.AppendLine(", on ");
            body.AppendLine(m.MeetingDate.DayOfWeek.ToString());
            body.AppendLine(" (");
            body.AppendLine(m.MeetingDate.ToShortDateString());
            body.AppendLine(") at ");
            body.AppendLine(m.MeetingTime.ToString().Substring(0, 5));
            body.AppendLine(" lasting ");
            body.AppendLine(m.MeetingLength.ToString());
            body.AppendLine(" minutes has been <strong>cancelled</strong>.</p>");
            body.AppendLine("<br />");
            body.AppendLine("<p>Apologies for the inconvenience!</p>");
            body.AppendLine("<p>~SecureLine</p>");

            EmailLogic.SendEmail(recipientAddress, subject, body.ToString());
        }
        private void SendEmail(string recipientAddress, string name, string userName, string password)
        {
            StringBuilder body    = new StringBuilder();
            string        subject = "SecureLine Password Reminder";

            body.AppendLine("<h2>You recently requested a password reminder for your SecureLine account.</h2>");
            body.AppendLine("<p>Hi ");
            body.AppendLine(name);
            body.AppendLine(", ");
            body.AppendLine("your login details for SecureLine are listed below.</p>");
            body.AppendLine("Username: "******"<br />");
            body.AppendLine("Password: "******"<br />");

            body.AppendLine("<p>Remember to keep your information private.</p>");
            body.AppendLine("<p>~SecureLine</p>");

            EmailLogic.SendEmail(recipientAddress, subject, body.ToString());
        }
        private void SendEmail_AddStaff(StaffModel s)
        {
            StringBuilder body    = new StringBuilder();
            string        subject = "Welcome to SecureLine!";

            body.AppendLine("<h2>Your account has been created.</h2>");
            body.AppendLine("<p>Welcome ");
            body.AppendLine(s.StaffFirstName);
            body.AppendLine(", ");
            body.AppendLine("your login details for SecureLine are listed below.</p>");
            body.AppendLine("Username: "******"<br />");
            body.AppendLine("Password: "******"<br />");

            body.AppendLine("<p>Remember to keep your information private.</p>");
            body.AppendLine("<p>~SecureLine</p>");

            EmailLogic.SendEmail(s.StaffEmail, subject, body.ToString());
        }