private void LoadDisplayName()
    {
        string displayName = string.Empty;
        string organizationName = string.Empty;

        if (Session["SignInAccountId"] != null)
            displayName = new CommonBAL().GetNameBySignInId(Session["SignInId"].ToString(), Convert.ToInt32(Session["SignInAccountTypeId"]), Convert.ToInt32(Session["SignInAccountId"]), Convert.ToInt32(Session["SignInOrganizationId"]));
        else
            displayName = new CommonBAL().GetNameBySignInId(Session["SignInId"].ToString(), 0, 0, Convert.ToInt32(Session["SignInOrganizationId"]));

        if ((AccountType)Convert.ToInt32(Session["SignInAccountTypeId"]) == AccountType.Organization)
        {
            organizationName = new OrganizationBAL().GetOrganizationNameById(Convert.ToInt32(Session["SignInOrganizationId"]));
            lblUser.ToolTip = "Welcome " + organizationName;

            if (organizationName.Length > 50)
                lblUser.Text = "Welcome " + organizationName.Substring(0, 50) + "...";
            else
                lblUser.Text = "Welcome " + organizationName;
            return;
        }
        else
        {
            lblUser.Text = "Welcome " + displayName;
            return;
        }
    }
        public static bool SendSMSToNonIndiaWithCheckingNotification(string mobile, string body, int accountTypeId, string action, int appointmentId, int organizationId)
        {
            try
            {
                string smsUsername       = ConfigurationManager.AppSettings["InternationalSMSUsername"].ToString();
                string smsPassword       = ConfigurationManager.AppSettings["InternationalSMSPassword"].ToString();
                string nonIndiaSmsSwitch = ConfigurationManager.AppSettings["InternationalSMSSwitch"].ToString();

                if (nonIndiaSmsSwitch.ToLower() == "on")
                {
                    bool isSMS = new CommonBAL().SMSSwitch(mobile);

                    if (isSMS)
                    {
                        StringBuilder sbUrl = new StringBuilder();
                        sbUrl.Append("http://www.onverify.com/sms.php");
                        sbUrl.Append("?userid=" + smsUsername);
                        sbUrl.Append("&apipass="******"&number=" + mobile);
                        sbUrl.Append("&from=MedAppt");
                        sbUrl.Append("&msg=" + HttpUtility.UrlEncode(body));

                        System.Net.HttpWebRequest hwr = (System.Net.HttpWebRequest)System.Net.HttpWebRequest.Create(sbUrl.ToString());
                        hwr.AllowWriteStreamBuffering = true;
                        hwr.UserAgent = "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1)";
                        hwr.Referer   = "http://www.google.com/";
                        hwr.Timeout   = 40000;
                        CookieContainer cc = new CookieContainer();
                        hwr.CookieContainer = cc;

                        System.Net.WebResponse wr = hwr.GetResponse();

                        string oldSignInId = "";
                        if (HttpContext.Current.Session["SignInId"] == null)
                        {
                            oldSignInId = string.Empty;
                        }
                        else
                        {
                            oldSignInId = HttpContext.Current.Session["SignInId"].ToString();
                        }
                        new CommonDAL().SaveSMS(oldSignInId, mobile, accountTypeId, body, action, null, null, appointmentId, organizationId);

                        return(true);
                    }
                    else
                    {
                        return(false);
                    }
                }
                else
                {
                    return(false);
                }
            }
            catch
            {
                return(false);
            }
        }
        public static bool SendEmailWithCheckingNotification(string mailTo, string subject, string body, bool isHTML)
        {
            try
            {
                string mailFrom      = ConfigurationManager.AppSettings["EmailFrom"].ToString();
                string mailBcc       = ConfigurationManager.AppSettings["EmailBcc"].ToString();
                string mailUserName  = ConfigurationManager.AppSettings["EmailUsername"].ToString();
                string mailPassword  = ConfigurationManager.AppSettings["EmailPassword"].ToString();
                string mailVia       = ConfigurationManager.AppSettings["EmailVia"].ToString();
                int    mailPort      = Convert.ToInt32(ConfigurationManager.AppSettings["EmailPort"]);
                string emailSwitchOn = ConfigurationManager.AppSettings["EmailSwitchOn"].ToString();

                if (emailSwitchOn.ToLower() == "on")
                {
                    bool isEmail = new CommonBAL().EmailSwitch(mailTo);

                    if (isEmail)
                    {
                        MailMessage mailMsg = new MailMessage();
                        mailMsg.To.Add(new MailAddress(mailTo));
                        mailMsg.From    = new MailAddress(mailFrom);
                        mailMsg.Subject = subject;
                        mailMsg.AlternateViews.Add(AlternateView.CreateAlternateViewFromString(body, null, MediaTypeNames.Text.Html));
                        SmtpClient smtpClient = new SmtpClient(mailVia, mailPort);
                        System.Net.NetworkCredential credentials = new System.Net.NetworkCredential(mailUserName, mailPassword);

                        smtpClient.Credentials = credentials;

                        smtpClient.Send(mailMsg);


                        //MailMessage message = new MailMessage(mailFrom, mailTo, subject, body);
                        //message.BodyEncoding = Encoding.UTF8;
                        //message.IsBodyHtml = isHTML;
                        //message.Priority = MailPriority.Normal;
                        //message.Bcc.Add(mailBcc);

                        //SmtpClient client = new SmtpClient("localhost", 25);
                        //client.Credentials = CredentialCache.DefaultNetworkCredentials;
                        //client.Send(message);

                        return(true);
                    }
                    else
                    {
                        return(false);
                    }
                }
                else
                {
                    return(false);
                }
            }
            catch
            {
                return(false);
            }
        }
        public static bool SendEmailWithCheckingNotification(string mailTo, string subject, string body, bool isHTML)
        {
            try
            {
                string mailFrom = ConfigurationManager.AppSettings["EmailFrom"].ToString();
                string mailBcc = ConfigurationManager.AppSettings["EmailBcc"].ToString();
                string mailUserName = ConfigurationManager.AppSettings["EmailUsername"].ToString();
                string mailPassword = ConfigurationManager.AppSettings["EmailPassword"].ToString();
                string mailVia = ConfigurationManager.AppSettings["EmailVia"].ToString();
                int mailPort = Convert.ToInt32(ConfigurationManager.AppSettings["EmailPort"]);
                string emailSwitchOn = ConfigurationManager.AppSettings["EmailSwitchOn"].ToString();

                if (emailSwitchOn.ToLower() == "on")
                {
                    bool isEmail = new CommonBAL().EmailSwitch(mailTo);

                    if (isEmail)
                    {
                        MailMessage mailMsg = new MailMessage();
                        mailMsg.To.Add(new MailAddress(mailTo));
                        mailMsg.From = new MailAddress(mailFrom);
                        mailMsg.Subject = subject;
                        mailMsg.AlternateViews.Add(AlternateView.CreateAlternateViewFromString(body, null, MediaTypeNames.Text.Html));
                        SmtpClient smtpClient = new SmtpClient(mailVia, mailPort);
                        System.Net.NetworkCredential credentials = new System.Net.NetworkCredential(mailUserName, mailPassword);

                        smtpClient.Credentials = credentials;

                        smtpClient.Send(mailMsg);

                        //MailMessage message = new MailMessage(mailFrom, mailTo, subject, body);
                        //message.BodyEncoding = Encoding.UTF8;
                        //message.IsBodyHtml = isHTML;
                        //message.Priority = MailPriority.Normal;
                        //message.Bcc.Add(mailBcc);

                        //SmtpClient client = new SmtpClient("localhost", 25);
                        //client.Credentials = CredentialCache.DefaultNetworkCredentials;
                        //client.Send(message);

                        return true;
                    }
                    else
                    {
                        return false;
                    }
                }
                else
                {
                    return false;
                }
            }
            catch
            {
                return false;
            }
        }
 protected void Generatepassword()
 {
     foreach (GridDataItem dataItem in rgAdminLogIn.Items)
     {
         if (dataItem.OwnerTableView == rgAdminLogIn.MasterTableView)
         {
             Label lblActivationCode = (Label)dataItem.FindControl("lblActivationCode");
             Label lblActivationCodeDisp = (Label)dataItem.FindControl("lblActivationCodeDisp");
             string newActivationCode;
             if ((lblActivationCode.Text != "Not Applicable") && (lblActivationCode.Text != ""))
             {
                 newActivationCode = new CommonBAL().GenrateNewPassword(lblActivationCode.Text).Substring(0, 4);
                 lblActivationCodeDisp.Text = newActivationCode;
             }
             else
                 lblActivationCodeDisp.Text = "Not Applicable";
         }
     }
 }
        public static bool SendSMSToIndiaWithCheckingNotification(string mobile, string body, int accountTypeId, string action, int appointmentId, int organizationId)
        {
            try
            {
                string smsUsername    = ConfigurationManager.AppSettings["IndiaSMSUsername"].ToString();
                string smsPassword    = ConfigurationManager.AppSettings["IndiaSMSPassword"].ToString();
                string indiaSmsSwitch = ConfigurationManager.AppSettings["IndiaSMSSwitch"].ToString();

                if (indiaSmsSwitch.ToLower() == "on")
                {
                    bool isSMS = new CommonBAL().SMSSwitch(mobile);

                    if (isSMS)
                    {
                        StringBuilder sbUrl = new StringBuilder();
                        //sbUrl.Append("http://75.125.154.74/messageapi.asp");
                        //sbUrl.Append("?username="******"&password="******"&sender=MedAppt");
                        //sbUrl.Append("&mobile=" + mobile);
                        //sbUrl.Append("&message=" + body);

                        sbUrl.Append("http://enterprise.smsgupshup.com/GatewayAPI/rest");
                        sbUrl.Append("?method=sendMessage");
                        sbUrl.Append("&send_to=" + mobile);
                        sbUrl.Append("&msg=" + HttpUtility.UrlEncode(body));
                        sbUrl.Append("&userid=" + smsUsername);
                        sbUrl.Append("&password="******"&v=1.1");
                        sbUrl.Append("&msg_type=TEXT");
                        sbUrl.Append("&auth_scheme=PLAIN");
                        sbUrl.Append("&override_dnd=true");

                        System.Net.HttpWebRequest hwr = (System.Net.HttpWebRequest)System.Net.HttpWebRequest.Create(sbUrl.ToString());
                        hwr.AllowWriteStreamBuffering = true;
                        hwr.UserAgent = "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1)";
                        hwr.Referer   = "http://www.google.com/";
                        hwr.Timeout   = 40000;
                        CookieContainer cc = new CookieContainer();
                        hwr.CookieContainer = cc;

                        System.Net.WebResponse wr = hwr.GetResponse();

                        string responseString = "";
                        using (Stream stream = wr.GetResponseStream())
                        {
                            StreamReader reader = new StreamReader(stream, Encoding.UTF8);
                            responseString = reader.ReadToEnd();
                        }

                        string mobileid   = "";
                        string externalid = "";
                        if (responseString != string.Empty)
                        {
                            string[] successMessages = responseString.Split('|');

                            mobileid   = successMessages[1].Trim();
                            externalid = successMessages[2].Trim();
                        }

                        string oldSignInId = "";
                        if (HttpContext.Current.Session["SignInId"] == null)
                        {
                            oldSignInId = string.Empty;
                        }
                        else
                        {
                            oldSignInId = HttpContext.Current.Session["SignInId"].ToString();
                        }
                        new CommonDAL().SaveSMS(oldSignInId, mobile, accountTypeId, body, action, mobileid, externalid, appointmentId, organizationId);

                        return(true);
                    }
                    else
                    {
                        return(false);
                    }
                }
                else
                {
                    return(false);
                }
            }
            catch
            {
                return(false);
            }
        }
        public static bool SendSMSToNonIndiaWithCheckingNotification(string mobile, string body, int accountTypeId, string action, int appointmentId, int organizationId)
        {
            try
            {
                string smsUsername = ConfigurationManager.AppSettings["InternationalSMSUsername"].ToString();
                string smsPassword = ConfigurationManager.AppSettings["InternationalSMSPassword"].ToString();
                string nonIndiaSmsSwitch = ConfigurationManager.AppSettings["InternationalSMSSwitch"].ToString();

                if (nonIndiaSmsSwitch.ToLower() == "on")
                {
                    bool isSMS = new CommonBAL().SMSSwitch(mobile);

                    if (isSMS)
                    {
                        StringBuilder sbUrl = new StringBuilder();
                        sbUrl.Append("http://www.onverify.com/sms.php");
                        sbUrl.Append("?userid=" + smsUsername);
                        sbUrl.Append("&apipass="******"&number=" + mobile);
                        sbUrl.Append("&from=MedAppt");
                        sbUrl.Append("&msg=" + HttpUtility.UrlEncode(body));

                        System.Net.HttpWebRequest hwr = (System.Net.HttpWebRequest)System.Net.HttpWebRequest.Create(sbUrl.ToString());
                        hwr.AllowWriteStreamBuffering = true;
                        hwr.UserAgent = "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1)";
                        hwr.Referer = "http://www.google.com/";
                        hwr.Timeout = 40000;
                        CookieContainer cc = new CookieContainer();
                        hwr.CookieContainer = cc;

                        System.Net.WebResponse wr = hwr.GetResponse();

                        string oldSignInId = "";
                        if (HttpContext.Current.Session["SignInId"] == null)
                            oldSignInId = string.Empty;
                        else
                            oldSignInId = HttpContext.Current.Session["SignInId"].ToString();
                        new CommonDAL().SaveSMS(oldSignInId, mobile, accountTypeId, body, action, null, null, appointmentId, organizationId);

                        return true;
                    }
                    else
                    {
                        return false;
                    }
                }
                else
                {
                    return false;
                }
            }
            catch
            {
                return false;
            }
        }
        public static bool SendSMSToIndiaWithCheckingNotification(string mobile, string body, int accountTypeId, string action, int appointmentId, int organizationId)
        {
            try
            {
                string smsUsername = ConfigurationManager.AppSettings["IndiaSMSUsername"].ToString();
                string smsPassword = ConfigurationManager.AppSettings["IndiaSMSPassword"].ToString();
                string indiaSmsSwitch = ConfigurationManager.AppSettings["IndiaSMSSwitch"].ToString();

                if (indiaSmsSwitch.ToLower() == "on")
                {
                    bool isSMS = new CommonBAL().SMSSwitch(mobile);

                    if (isSMS)
                    {
                        StringBuilder sbUrl = new StringBuilder();
                        //sbUrl.Append("http://75.125.154.74/messageapi.asp");
                        //sbUrl.Append("?username="******"&password="******"&sender=MedAppt");
                        //sbUrl.Append("&mobile=" + mobile);
                        //sbUrl.Append("&message=" + body);

                        sbUrl.Append("http://enterprise.smsgupshup.com/GatewayAPI/rest");
                        sbUrl.Append("?method=sendMessage");
                        sbUrl.Append("&send_to=" + mobile);
                        sbUrl.Append("&msg=" + HttpUtility.UrlEncode(body));
                        sbUrl.Append("&userid=" + smsUsername);
                        sbUrl.Append("&password="******"&v=1.1");
                        sbUrl.Append("&msg_type=TEXT");
                        sbUrl.Append("&auth_scheme=PLAIN");
                        sbUrl.Append("&override_dnd=true");

                        System.Net.HttpWebRequest hwr = (System.Net.HttpWebRequest)System.Net.HttpWebRequest.Create(sbUrl.ToString());
                        hwr.AllowWriteStreamBuffering = true;
                        hwr.UserAgent = "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1)";
                        hwr.Referer = "http://www.google.com/";
                        hwr.Timeout = 40000;
                        CookieContainer cc = new CookieContainer();
                        hwr.CookieContainer = cc;

                        System.Net.WebResponse wr = hwr.GetResponse();

                        string responseString = "";
                        using (Stream stream = wr.GetResponseStream())
                        {
                            StreamReader reader = new StreamReader(stream, Encoding.UTF8);
                            responseString = reader.ReadToEnd();
                        }

                        string mobileid = "";
                        string externalid = "";
                        if (responseString != string.Empty)
                        {
                            string[] successMessages = responseString.Split('|');

                            mobileid = successMessages[1].Trim();
                            externalid = successMessages[2].Trim();
                        }

                        string oldSignInId = "";
                        if (HttpContext.Current.Session["SignInId"] == null)
                            oldSignInId = string.Empty;
                        else
                            oldSignInId = HttpContext.Current.Session["SignInId"].ToString();
                        new CommonDAL().SaveSMS(oldSignInId, mobile, accountTypeId, body, action, mobileid, externalid, appointmentId, organizationId);

                        return true;
                    }
                    else
                    {
                        return false;
                    }
                }
                else
                {
                    return false;
                }
            }
            catch
            {
                return false;
            }
        }
예제 #9
0
    protected void LoadMenu()
    {
        if (Session["SignInId"] != null)
        {
            if ((AccountType)Convert.ToInt32(Session["SignInAccountTypeId"]) == AccountType.Patient)
            {
                phMenu.Controls.Add(new LiteralControl("<a href=\"patient.aspx\"><img src=\"/imagesnew/homeIcon.png\" alt=\"Doctor Search\"/><span class=\"Yellow\">Search</span></a>"));
                //phMenu.Controls.Add(new LiteralControl("<a class =\"dock-item\" href=\"ReferAFriend.aspx\"><img src=\"/imagesnew/ReferFriend.png\" alt=\"Refer a Friend\"/><span>Refer a Friend</span></a>"));
                phMenu.Controls.Add(new LiteralControl("<a href=\"MyAppointment.aspx\"><img src=\"/imagesnew/listMyAppointment.png\" alt=\"MyAppointment Setup\"/><span class=\"Yellow\">My Appointments</span></a>"));
                phMenu.Controls.Add(new LiteralControl("<a class=\"Divider\" href=\"ListMember.aspx\"><img src=\"/imagesnew/ListMembers.png\" alt=\"Member Setup\"/><span class=\"Yellow\">Member<br/> Setup</span></a>"));

                phMenu.Controls.Add(new LiteralControl("<a href=\"EditPatient.aspx\"><img src=\"/imagesnew/EditProfile.png\" alt=\"Edit Profile\"/><span>Edit <br/>Profile</span></a>"));
                phMenu.Controls.Add(new LiteralControl("<a class=\"Divider\" href=\"AccountSetting.aspx\"><img src=\"/imagesnew/account-setting.png\" alt=\"Account Setting\"/><span>Notification Settings</span></a>"));

                if (Convert.ToBoolean(Session["SignInMultipleAccounts"]))
                    phMenu.Controls.Add(new LiteralControl("<a href=\"Profile.aspx\" ><img src=\"/imagesnew/SwitchAccounts.png\" alt=\"Profiles\"/><span class=\"Green\">Profiles</span></a>"));
                else
                    phMenu.Controls.Add(new LiteralControl("<a class=\"inline\" href=\"#\"><img src=\"/imagesnew/SwitchAccounts.png\" alt=\"Profile\"/><span class=\"Green\">Profiles</span></a>"));
            }
            else if ((AccountType)Convert.ToInt32(Session["SignInAccountTypeId"]) == AccountType.Organization)
            {
                int _organizationId = (int)Session["SignInOrganizationId"];

                phMenu.Controls.Add(new LiteralControl("<a href=\"HospitalSetup.aspx\"><img src=\"/imagesnew/hospitalSetup.png\" alt=\"Hospital Setup\"/><span>Hospital Setup</span></a>"));
                phMenu.Controls.Add(new LiteralControl("<a href=\"ListDoctor.aspx\"><img src=\"/imagesnew/ListDoctor.png\" alt=\"Doctor Setup\"/><span>Doctor<br/> Setup</span></a>"));
                phMenu.Controls.Add(new LiteralControl("<a class=\"Divider\" href=\"ListService.aspx\"><img src=\"/imagesnew/ListService.png\" alt=\"Service Setup\"/><span>Service<br/> Setup</span></a></li>"));
                phMenu.Controls.Add(new LiteralControl("<a href=\"HospitalDirectAppointment.aspx?id=" + _organizationId + "\"><img src=\"/imagesnew/DirectAppointment.png\" alt=\"Direct Appointment\"/><span>Direct Appointment</span></a>"));
                phMenu.Controls.Add(new LiteralControl("<a href=\"PatientSearch.aspx\"><img src=\"/imagesnew/AppointHistory.png\" alt=\"Patient Search\"/><span>Appointment History</span></a>"));
                //phMenu.Controls.Add(new LiteralControl("<a class=\"Divider\" href=\"HospitalAppointmentHistory.aspx\"><img src=\"/imagesnew/AppointHistory.png\" alt=\"Appointment History\"/><span>Appointment History</span></a>"));

                phMenu.Controls.Add(new LiteralControl("<a href=\"EditOrganization.aspx\"><img src=\"/imagesnew/EditProfile.png\" alt=\"Edit Profile\"/><span class=\"Yellow\">Edit <br/>Profile</span></a>"));
                phMenu.Controls.Add(new LiteralControl("<a href=\"Branding.aspx\"><img src=\"/imagesnew/branding.png\" alt=\"Branding\"/><span class=\"Yellow\">Branding</span></a>"));
                phMenu.Controls.Add(new LiteralControl("<a class=\"Divider\" href=\"Landing.aspx\"><img src=\"/imagesnew/Set-Landing-Page.png\" alt=\"Wesite Setup\"/><span class=\"Yellow\">Website <br/>Setup</span></a></li>"));

                phMenu.Controls.Add(new LiteralControl("<a href=\"AccountSetting.aspx\"><img src=\"/imagesnew/account-setting.png\" alt=\"Notification Settings\"/><span class=\"Green\">Notification Settings</span></a>"));
                phMenu.Controls.Add(new LiteralControl("<a href=\"Search.aspx\"><img src=\"/imagesnew/SearchDoctor.png\" alt=\"Search Medical Service\"/><span>Check your Listing</span></a>"));
                if (Convert.ToBoolean(Session["SignInMultipleAccounts"]))
                    phMenu.Controls.Add(new LiteralControl("<a href=\"Profile.aspx\"><img src=\"/imagesnew/SwitchAccounts.png\" alt=\"Profiles\"/><span class=\"Green\">Profiles</span></a>"));
                else
                    phMenu.Controls.Add(new LiteralControl("<a href=\"Profile.aspx\"><img src=\"/imagesnew/SwitchAccounts.png\" alt=\"Profiles\"/><span class=\"Green\">Profiles</span></a>"));
            }
            else if ((AccountType)Convert.ToInt32(Session["SignInAccountTypeId"]) == AccountType.Doctor)
            {
                int organizationId = (int)Session["SignInOrganizationId"];

                _doctorId = new CommonBAL().GetDoctorServiceIdBySignInId(0, Session["SignInId"].ToString(), organizationId);

                //phMenu.Controls.Add(new LiteralControl("<a href=\"PatientSearch.aspx\"><img src=\"/imagesnew/patientSearch.png\" alt=\"Patient Search\"/><span>Patient Search</span></a>"));

                //if (Session["SignInIdTemp"] == null)
                phMenu.Controls.Add(new LiteralControl("<a href=\"ListScheduleDoctor.aspx?id=" + _doctorId + "\"><img src=\"/imagesnew/List-Schedule.png\" alt=\"Schedule Setup\"/><span class=\"Yellow\">Schedule Setup</span></a>"));

                phMenu.Controls.Add(new LiteralControl("<a class=\"Divider blockCalenderSetup\" href=\"ListBlockCalendar.aspx?id=" + _doctorId + "&type=0\"\"><img src=\"/imagesnew/List-Block-Calendar.png\" alt=\"Block Calendar Setup\"/><span class=\"Yellow\" style=\" font-size:11px;\">Block Calendar Setup</span></a>"));

                if (Session["SignInIdTemp"] == null)
                    phMenu.Controls.Add(new LiteralControl("<a href=\"DirectAppointment.aspx?id=" + _doctorId + "&type=0\"><img src=\"/imagesnew/DirectAppointment.png\" alt=\"Direct Appointment\"/><span>Direct Appointment</span></a>"));

                phMenu.Controls.Add(new LiteralControl("<a class=\"Divider\" href=\"PatientSearch.aspx\"><img src=\"/imagesnew/AppointHistory.png\" alt=\"Appointment History\"/><span>Appointment History</span></a>"));

                if (Session["SignInIdTemp"] == null)
                    phMenu.Controls.Add(new LiteralControl("<a href=\"EditDoctor.aspx\"><img src=\"/imagesnew/EditProfile.png\" alt=\"Edit Profile\"/><span>Edit <br/>Profile</span></a>"));
                else
                    phMenu.Controls.Add(new LiteralControl("<a href=\"EditDoctor.aspx\"><img src=\"/imagesnew/EditProfile.png\" alt=\"View Profile\"/><span>View <br/>Profile</span></a>"));

                if (Session["SignInIdTemp"] == null) //checking Admin doctor
                {
                    phMenu.Controls.Add(new LiteralControl("<a class=\"Divider\" href=\"Landing.aspx\"><img src=\"/imagesnew/Set-Landing-Page.png\" alt=\"Website Setup\"/><span>Website <br/>Setup</span></a></li>"));

                    phMenu.Controls.Add(new LiteralControl("<a href=\"Search.aspx\"><img src=\"/imagesnew/SearchDoctor.png\" alt=\"Search Medical Service\"/><span class=\"Green\">Check your Listing</span></a>"));
                    phMenu.Controls.Add(new LiteralControl("<a href=\"DoctorDiagnosis.aspx\"><img src=\"/imagesnew/Set-Diagnosis.png\" alt=\"Diagnosis Setup\"/><span class=\"Green\">Diagnosis Setup</span></a>"));
                    phMenu.Controls.Add(new LiteralControl("<a href=\"AccountSetting.aspx\"><img src=\"/imagesnew/account-setting.png\" alt=\"Notification Settings\"/><span class=\"Green\">Notification Settings</span></a>"));
                }

                if (Convert.ToBoolean(Session["SignInMultipleAccounts"]))
                    phMenu.Controls.Add(new LiteralControl("<a href=\"Profile.aspx\"><img src=\"/imagesnew/SwitchAccounts.png\" alt=\"Profiles\"/><span class=\"Green\">Profiles</span></a>"));
                else
                    phMenu.Controls.Add(new LiteralControl("<a href=\"Profile.aspx\"><img src=\"/imagesnew/SwitchAccounts.png\" alt=\"Profile\"/><span class=\"Green\">Profiles</span></a>"));
            }
            else if ((AccountType)Convert.ToInt32(Session["SignInAccountTypeId"]) == AccountType.Service)
            {
                int organizationId = (int)Session["SignInOrganizationId"];

                _serviceId = Convert.ToInt32(Session["SignInAccountId"]);

                //if (Session["SignInIdTemp"] == null)
                phMenu.Controls.Add(new LiteralControl("<a href=\"ListScheduleService.aspx?id=" + _serviceId + "\"><img src=\"/imagesnew/List-Schedule.png\" alt=\"Schedule Setup\"/><span class=\"Yellow\">Schedule Setup</span></a>"));

                phMenu.Controls.Add(new LiteralControl("<a class=\"Divider\" href=\"ListBlockCalendar.aspx?id=" + _serviceId + "&type=1\"\"><img src=\"/imagesnew/List-Block-Calendar.png\" alt=\"Block Calendar Setup\"/><span class=\"Yellow\"  style=\" font-size:11px;\">Block Calendar Setup</span></a>"));

                if (Session["SignInIdTemp"] == null)
                    phMenu.Controls.Add(new LiteralControl("<a href=\"DirectAppointment.aspx?id=" + _serviceId + "&type=1\"><img src=\"/imagesnew/DirectAppointment.png\" alt=\"Direct Appointment\"/><span>Direct Appointment</span></a></li>"));

                //phMenu.Controls.Add(new LiteralControl("<a class=\"Divider\" href=\"AppointmentHistory.aspx\"><img src=\"/imagesnew/AppointHistory.png\" alt=\"Appointment History\"/><span>Appointment History</span></a>"));
                phMenu.Controls.Add(new LiteralControl("<a class=\"Divider\" href=\"PatientSearch.aspx\"><img src=\"/imagesnew/AppointHistory.png\" alt=\"Appointment History\"/><span>Appointment History</span></a>"));

                if (Session["SignInIdTemp"] == null)
                    phMenu.Controls.Add(new LiteralControl("<a href=\"EditService.aspx\"><img src=\"/imagesnew/EditProfile.png\" alt=\"Edit Profile\"/><span class=\"Green\">Edit <br/>Profile</span></a>"));
                else
                    phMenu.Controls.Add(new LiteralControl("<a href=\"EditService.aspx\"><img src=\"/imagesnew/EditProfile.png\" alt=\"View Profile\"/><span class=\"Green\">View <br/>Profile</span></a>"));

                if (Session["SignInIdTemp"] == null)
                {
                    phMenu.Controls.Add(new LiteralControl("<a href=\"AccountSetting.aspx\"><img src=\"/imagesnew/account-setting.png\" alt=\"Notification Settings\"/><span class=\"Green\">Notification Settings</span></a>"));
                    phMenu.Controls.Add(new LiteralControl("<a href=\"Search.aspx\"><img src=\"/imagesnew/SearchDoctor.png\" alt=\"Search Medical Service\"/><span class=\"Green\">Check your Listing</span></a>"));
                }

                if (Convert.ToBoolean(Session["SignInMultipleAccounts"]))
                    phMenu.Controls.Add(new LiteralControl("<a href=\"Profile.aspx\"><img src=\"/imagesnew/SwitchAccounts.png\" alt=\"Profiles\"/><span class=\"Green\">Profiles</span></a>"));
                else
                    phMenu.Controls.Add(new LiteralControl("<a href=\"Profile.aspx\"><img src=\"/imagesnew/SwitchAccounts.png\" alt=\"Profiles\"/><span class=\"Green\">Profiles</span></a>"));
            }
        }
    }