Пример #1
0
    private void ShowAssignedLinks(string userroleid)
    {
        OptionMenuDataAccess access = new OptionMenuDataAccess();

        try
        {
            foreach (DataRow row in access.GetAssignedMenu(userroleid).Rows)
            {
                ((Bill_Sys_UserObject)base.Session["USER_OBJECT"]).SZ_USER_ROLE_NAME.ToLower().Equals("attorney");
                switch (row[0].ToString())
                {
                case "Search":
                {
                    if (!(((Bill_Sys_UserObject)base.Session["USER_OBJECT"]).SZ_USER_ROLE_NAME.ToLower() != "doctor"))
                    {
                        break;
                    }
                    this.lnkHome.Visible = true;
                    continue;
                }

                case "Desk":
                {
                    this.lnkDesks.Visible = true;
                    continue;
                }

                case "Data Entry":
                {
                    this.lnkDataEntry.Visible = true;
                    continue;
                }

                case "Calendar":
                {
                    // this.lnkCalendar.Visible = false;
                    //this.lnkScheduleReport.Visible = true;
                    continue;
                }

                case "Quick Bill Entry":
                {
                    this.lnkQuickSearch.Visible = true;
                    continue;
                }

                case "Reports":
                {
                    this.lnkReports.Visible = true;
                    continue;
                }

                case "Doctor Screen":
                {
                    this.A2.Visible = false;
                    continue;
                }

                case "Billing":
                {
                    this.lnkBillingReport.Visible = true;
                    continue;
                }

                default:
                {
                    continue;
                }
                }
                this.lnkHome.Visible = true;
            }
        }
        catch (Exception exception)
        {
            log.Debug("attorney. Method - ShowAssignedLinks : " + exception.Message.ToString());
            log.Debug("attorney. Method - ShowAssignedLinks : " + exception.StackTrace.ToString());
            if (exception.InnerException != null)
            {
                log.Debug("attorney. Method - ShowAssignedLinks : " + exception.InnerException.Message.ToString());
                log.Debug("attorney. Method - ShowAssignedLinks : " + exception.InnerException.StackTrace.ToString());
            }
        }
    }
Пример #2
0
    private void ShowAssignedLinks(string userroleid)
    {//Logging Start
        string id = string.Format("Id: {0} Uri: {1}", Guid.NewGuid(), HttpContext.Current.Request.Url);

        using (Utils utility = new Utils())
        {
            utility.MethodStart(id, System.Reflection.MethodBase.GetCurrentMethod());
        }

        OptionMenuDataAccess _optMenuDataAccess = new OptionMenuDataAccess();

        try
        {
            DataTable dt = _optMenuDataAccess.GetAssignedMenu(userroleid);
            foreach (DataRow dr in dt.Rows)
            {
                switch (dr[0].ToString())
                {
                case "Search":
                    if (((Bill_Sys_UserObject)(Session["USER_OBJECT"])).SZ_USER_ROLE_NAME.ToLower() != "doctor")
                    {
                        lnkHome.Visible = true;
                    }
                    else
                    {
                        // lnkHome.Visible = false;
                    }
                    break;

                case "Desk":
                    //lnkDesks.Visible = true;
                    break;

                case "Data Entry":
                    lnkDataEntry.Visible = true;
                    break;

                case "Calendar":
                    lnkScheduleReport.Visible = true;
                    break;

                case "Quick Bill Entry":
                    //lnkQuickSearch.Visible = true;
                    break;

                case "Reports":
                    //lnkReports.Visible = true;
                    break;

                //...ashutosh
                case "Doctor Screen":
                    //A2.Visible = false;
                    break;

                //...
                //...Tushar
                case "Billing":
                    //lnkBillingReport.Visible = true;
                    break;
                    //...
                }
            }
        }
        catch (Exception ex)
        {
            Elmah.ErrorSignal.FromCurrentContext().Raise(ex);
            using (Utils utility = new Utils())
            {
                utility.MethodEnd(id, System.Reflection.MethodBase.GetCurrentMethod());
            }
            string str2 = "Error Request=" + id + ".Please share with Technical support.";
            base.Response.Redirect("../Bill_Sys_ErrorPage.aspx?ErrMsg=" + str2);
        }
        //Method End

        using (Utils utility = new Utils())
        {
            utility.MethodEnd(id, System.Reflection.MethodBase.GetCurrentMethod());
        }
    }
Пример #3
0
    private void ShowAssignedLinks(string userroleid)
    {
        string id = string.Format("Id: {0} Uri: {1}", Guid.NewGuid(), HttpContext.Current.Request.Url);

        using (Utils utility = new Utils())
        {
            utility.MethodStart(id, System.Reflection.MethodBase.GetCurrentMethod());
        }
        OptionMenuDataAccess access = new OptionMenuDataAccess();

        try
        {
            foreach (DataRow row in access.GetAssignedMenu(userroleid).Rows)
            {
                ((Bill_Sys_UserObject)base.Session["USER_OBJECT"]).SZ_USER_ROLE_NAME.ToLower();
                switch (row[0].ToString())
                {
                case "Search":
                {
                    if (!(((Bill_Sys_UserObject)base.Session["USER_OBJECT"]).SZ_USER_ROLE_NAME.ToLower() != "doctor"))
                    {
                        break;
                    }
                    this.lnkHome.Visible = true;
                    continue;
                }

                case "Desk":
                {
                    this.lnkDesks.Visible = true;
                    continue;
                }

                case "Data Entry":
                {
                    this.lnkDataEntry.Visible = true;
                    continue;
                }

                case "Calendar":
                {
                    //this.lnkCalendar.Visible = false;
                    this.lnkScheduleReport.Visible = true;
                    continue;
                }

                case "Quick Bill Entry":
                {
                    this.lnkQuickSearch.Visible = true;
                    continue;
                }

                case "Reports":
                {
                    this.lnkReports.Visible = true;
                    continue;
                }

                case "Doctor Screen":
                {
                    this.A2.Visible = false;
                    continue;
                }

                case "Billing":
                {
                    this.lnkBillingReport.Visible = true;
                    continue;
                }

                default:
                {
                    continue;
                }
                }
                this.lnkHome.Visible = false;
            }
        }
        catch (Exception exception)
        {
            log.Debug("Shared_MasterPage. Method - ShowAssignedLinks : " + exception.Message.ToString());
            log.Debug("Shared_MasterPage. Method - ShowAssignedLinks : " + exception.StackTrace.ToString());
            if (exception.InnerException != null)
            {
                log.Debug("Shared_MasterPage. Method - ShowAssignedLinks : " + exception.InnerException.Message.ToString());
                log.Debug("Shared_MasterPage. Method - ShowAssignedLinks : " + exception.InnerException.StackTrace.ToString());
            }
            Elmah.ErrorSignal.FromCurrentContext().Raise(exception);
            using (Utils utility = new Utils())
            {
                utility.MethodEnd(id, System.Reflection.MethodBase.GetCurrentMethod());
            }
            string str2 = "Error Request=" + id + ".Please share with Technical support.";
            base.Response.Redirect("Bill_Sys_ErrorPage.aspx?ErrMsg=" + str2);
        }
        //Method End
        using (Utils utility = new Utils())
        {
            utility.MethodEnd(id, System.Reflection.MethodBase.GetCurrentMethod());
        }
    }