Beispiel #1
0
    protected void UserAccessValidation()
    {
        int CurrentUserID = GetSessionUserID();

        string PageURL = UDFLib.GetPageURL(Request.Path.ToUpper());

        BLL_Infra_UserCredentials objUser = new BLL_Infra_UserCredentials();

        objUA = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);

        string     pageNOKURL = "CREW/CREWDETAILS_NOK.ASPX";
        UserAccess objUANOK   = new UserAccess();

        objUANOK = objUser.Get_UserAccessForPage(CurrentUserID, pageNOKURL);

        if (objUANOK.Add == 0)
        {
            ImgAddNewDependent.Visible  = false;
            ImgReloadDependents.Visible = false;
        }
        if (objUA.View == 0)
        {
            Response.Redirect("~/default.aspx?msgid=1");
        }

        if (objUA.Add == 0)
        {
            ImgAddNewDependent.Visible = false;
            btnUnplannedEval.Visible   = false;
        }
        if (objUA.Edit == 0)
        {
            lnkEditPersonalDetails.Visible = false;
            imgCrewPic.Enabled             = false;
        }
        if (objUA.Delete == 0)
        {
        }
        if (objUA.Approve == 0 || (Session["UTYPE"] != null && Session["UTYPE"].Equals("MANNING AGENT")))
        {
            lnkNTBR.Visible            = false;
            ImgBtnCrewApproval.Visible = false;
            btnUndoRejection.Visible   = false;
            imgBtnBrief.Visible        = false;
        }
        else
        {
            lnkNTBR.Visible = true;
            lnkNTBR.Attributes.Add("onclick", "EditCrewPrifileStatus(" + GetCrewID().ToString() + ")");

            ImgBtnCrewApproval.Visible = true;
            btnUndoRejection.Visible   = true;
            imgBtnBrief.Visible        = true;
        }
        if (objUA.Admin == 0)
        {
            lnkResetCrewPassword.Visible = false;
        }
    }
Beispiel #2
0
    protected void UserAccessValidation()
    {
        int    CurrentUserID = GetSessionUserID();
        string PageURL       = UDFLib.GetPageURL(Request.Path.ToUpper());

        objUA = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);

        if (objUA.View == 0)
        {
            lblMsg.Text = "You don't have sufficient privilege to access the requested information.";
        }

        if (objUA.Add == 0)
        {
            ImgAdd_PreJoiningExp.Visible = false;
        }
        if (objUA.Edit == 0)
        {
            lnkPreviousContacts.Visible = false;

            GridView_PreJoiningExp.Columns[GridView_PreJoiningExp.Columns.Count - 2].Visible = false;
        }
        if (objUA.Delete == 0)
        {
            GridView_PreJoiningExp.Columns[GridView_PreJoiningExp.Columns.Count - 1].Visible = false;
        }
        if (objUA.Approve == 0)
        {
        }
        //-- MANNING OFFICE LOGIN --
    }
    protected void UserAccessValidation()
    {
        string PageURL = UDFLib.GetPageURL(Request.Path.ToUpper());

        objUA = objUser.Get_UserAccessForPage(Convert.ToInt32(Session["USERID"]), PageURL);

        if (objUA.View == 0)
        {
            Response.Write("You don't have sufficient previlege to access the requested page");
            Response.End();
        }

        if (objUA.Add == 0)
        {
            btnSave.Enabled   = false;
            btnInvite.Enabled = false;
        }
        if (objUA.Edit == 0)
        {
        }
        if (objUA.Delete == 0)
        {
            btnDelete.Enabled = false;
        }
    }
Beispiel #4
0
    protected void UserAccessValidation()
    {
        int    CurrentUserID = GetSessionUserID();
        string PageURL       = UDFLib.GetPageURL(Request.Path.ToUpper());

        BLL_Infra_UserCredentials objUser = new BLL_Infra_UserCredentials();

        objUA = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);

        if (objUA.View == 0)
        {
            MainDiv.Visible      = false;
            AccessMsgDiv.Visible = true;
        }
        else
        {
            MainDiv.Visible      = true;
            AccessMsgDiv.Visible = false;
        }

        if (objUA.Add == 0)
        {
            ImgAdd.Visible = false;
        }
        if (objUA.Edit == 1)
        {
            uaEditFlag = true;
        }
        if (objUA.Delete == 1)
        {
            uaDeleteFlage = true;
        }
    }
Beispiel #5
0
    protected void UserAccessValidation()
    {
        int    CurrentUserID = GetSessionUserID();
        string PageURL       = UDFLib.GetPageURL(Request.Path.ToUpper());

        objUA = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);

        if (objUA.View == 0)
        {
            lblMsg.Text = "You don't have sufficient privilege to access the requested information.";
        }

        if (objUA.Add == 0)
        {
        }
        if (objUA.Edit == 0)
        {
        }
        if (objUA.Delete == 0)
        {
        }
        if (objUA.Approve == 0)
        {
        }
        //-- MANNING OFFICE LOGIN --
    }
    protected void UserAccessValidation()
    {
        int    CurrentUserID = GetSessionUserID();
        string PageURL       = UDFLib.GetPageURL(Request.Path.ToUpper());

        objUA = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);

        if (objUA.View == 0)
        {
            lblMsg.Text = "You don't have sufficient privilege to access the requested information.";
            pnlAddMedHistory.Visible = false;
        }
        if (objUA.Add == 0)
        {
            lnkAddCostItem.Visible = false;
            lnkAddFollowUp.Visible = false;
            pnlFileUpload.Visible  = false;
            btnSave.Visible        = false;
        }
        if (objUA.Edit == 0)
        {
            lnkEditDetails.Visible = false;
            lnkAddCostItem.Visible = false;
            lnkAddFollowUp.Visible = false;
            pnlFileUpload.Visible  = false;
            btnSave.Visible        = false;
        }
        if (objUA.Delete == 0)
        {
        }
        if (objUA.Approve == 0)
        {
        }
    }
    /// <summary>
    /// To check acces for logged in user.
    /// like Add,Edit ,delete access for requested page.
    /// </summary>
    protected void UserAccessValidation()
    {
        int    CurrentUserID = GetSessionUserID();
        string PageURL       = UDFLib.GetPageURL(Request.Path.ToUpper());

        try
        {
            BLL_Infra_UserCredentials objUser = new BLL_Infra_UserCredentials();
            objUA = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);

            if (objUA != null)
            {
                if (objUA.View == 0)
                {
                    Response.Write("<center><br><br><h2><font color=gray>You do not have enough priviledge to access this page.</font></h2></center>");
                    Response.End();
                }

                // Only Admin can add/update mail id
                if (objUA.Admin == 1)
                {
                    btnsave.Visible = true;
                }
                else
                {
                    btnsave.Visible = false;
                }
            }
        }
        catch (Exception ex)
        {
            UDFLib.WriteExceptionLog(ex);
        }
    }
    protected void UserAccessValidation()
    {
        int    CurrentUserID = GetSessionUserID();
        string PageURL       = UDFLib.GetPageURL(Request.Path.ToUpper());

        objUA = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);

        if (objUA.View == 0)
        {
            Response.Redirect("~/default.aspx?msgid=1");
        }

        if (objUA.Approve == 0)
        {
            btnVerify.Visible            = false;
            lblVerificationDate.Visible  = false;
            lblVerificationDateH.Visible = false;
            lblVerifiedBy.Visible        = false;
            lblVerifiedByH.Visible       = false;
            lblComment.Visible           = false;
            btnVerify.Visible            = false;
            txtMessage.Visible           = false;
        }
        ViewState["del"] = objUA.Delete;
    }
Beispiel #9
0
    protected void UserAccessValidation()
    {
        int    CurrentUserID = GetSessionUserID();
        string PageURL       = UDFLib.GetPageURL(Request.Path.ToUpper());

        BLL_Infra_UserCredentials objUser = new BLL_Infra_UserCredentials();

        objUA = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);

        if (objUA.View == 0)
        {
            lblMessage.Text       = "You don't have sufficient previlege to access the requested information.";
            dvPageContent.Visible = false;
        }
        if (objUA.Add == 0)
        {
            // lnkEditInterviewPlanning.Visible = false;
            //GridView1.Columns[GridView1.Columns.Count - 1].Visible = false;
        }
        if (objUA.Edit == 0)
        {
        }
        if (objUA.Delete == 0)
        {
        }

        if (objUA.Approve == 0)
        {
        }
    }
Beispiel #10
0
    protected void UserAccessValidation()
    {
        UserAccess objUA = new UserAccess();

        int    CurrentUserID = GetSessionUserID();
        string PageURL       = UDFLib.GetPageURL(Request.Path.ToUpper());

        BLL_Infra_UserCredentials objUser = new BLL_Infra_UserCredentials();

        objUA = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);

        if (objUA.View == 0)
        {
            Response.Redirect("~/default.aspx");
        }

        if (objUA.Add == 0)
        {
            lnkAddNewQuestion.Visible = false;
        }
        if (objUA.Edit == 0)
        {
            GridView_Criteria.Columns[GridView_Criteria.Columns.Count - 3].Visible = false;
        }
        if (objUA.Delete == 0)
        {
            GridView_Criteria.Columns[GridView_Criteria.Columns.Count - 2].Visible = false;
        }

        if (objUA.Approve == 0)
        {
        }
    }
    protected void UserAccessValidation()
    {
        int    CurrentUserID = GetSessionUserID();
        string PageURL       = UDFLib.GetPageURL(Request.Path.ToUpper());

        objUA = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);

        if (objUA.View == 0)
        {
            lblMsg.Text = "You don't have sufficient privilege to access the requested information.";
        }
        if (objUA.Add == 0)
        {
        }
        if (objUA.Edit == 0)
        {
        }
        if (objUA.Delete == 0)
        {
        }
        if (objUA.Approve == 0)
        {
        }
        //-- MANNING OFFICE LOGIN --
        if (Session["USERCOMPANYID"].ToString() != "1")
        {
            //Response.Redirect("~/default.aspx?msgid=2");
        }
        else//--- CREW TEAM LOGIN--
        {
        }
    }
Beispiel #12
0
    protected void UserAccessValidation()
    {
        int    CurrentUserID = GetSessionUserID();
        string PageURL       = UDFLib.GetPageURL(Request.Path.ToUpper());

        BLL_Infra_UserCredentials objUser = new BLL_Infra_UserCredentials();

        objUA = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);


        if (objUA.View == 0)
        {
            Response.Redirect("~/default.aspx?msgid=1");
        }

        if (objUA.Add == 0)
        {
            ImgBtnAddNewJob.Visible = false;
            grdJoblist.Columns[grdJoblist.Columns.Count - 1].Visible = false;
        }
        if (objUA.Edit == 0)
        {
            grdJoblist.Columns[grdJoblist.Columns.Count - 3].Visible = false;
        }
        if (objUA.Delete == 0)
        {
        }
        if (objUA.Approve == 0)
        {
        }
    }
Beispiel #13
0
    protected void UserAccessValidation()
    {
        int    CurrentUserID = GetSessionUserID();
        string PageURL       = UDFLib.GetPageURL(Request.Path.ToUpper());

        BLL_Infra_UserCredentials objUser = new BLL_Infra_UserCredentials();

        objUA = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);


        //if (objUA.View == 0)
        //    Response.Redirect("~/default.aspx?msgid=1");

        if (objUA.Add == 0)
        {
        }
        if (objUA.Edit == 0)
        {
        }
        if (objUA.Delete == 0)
        {
        }
        if (objUA.Approve == 0)
        {
        }
        if (objUA.Admin == 1)
        {
            ViewState["WLADMIN"] = 1;
        }
        else
        {
            ViewState["WLADMIN"] = 0;
        }
    }
Beispiel #14
0
    protected void UserAccessValidation()
    {
        int    CurrentUserID = GetSessionUserID();
        string PageURL       = UDFLib.GetPageURL(Request.Path.ToUpper());

        objUA = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);
    }
    protected void UserAccessValidation()
    {
        int    CurrentUserID = GetSessionUserID();
        string PageURL       = UDFLib.GetPageURL(Request.Path.ToUpper());

        objUA = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);

        if (objUA.View == 0)
        {
            pnlViewAccounts.Visible = false;
            lblMsg.Text             = "You don't have sufficient privilege to access the requested information.";
        }
        if (objUA.Add == 0)
        {
            pnlEditAccount.Visible     = false;
            DetailsView_NewAcc.Enabled = false;
        }
        if (objUA.Edit == 0)
        {
            pnlEditAccount.Visible = false;
            GridView_BankAccounts.Columns[GridView_BankAccounts.Columns.Count - 3].Visible = false;
        }
        if (objUA.Delete == 0)
        {
            GridView_BankAccounts.Columns[GridView_BankAccounts.Columns.Count - 2].Visible = false;
        }
        if (objUA.Approve == 0)
        {
            DetailsView_NewAcc.Fields[DetailsView_NewAcc.Fields.Count - 7].Visible = false;
        }
    }
    protected void gridRule_RowDataBound(object sender, GridViewRowEventArgs e)
    {
        if (e.Row.RowType == DataControlRowType.DataRow)
        {
            ImageButton btnDelete     = (ImageButton)e.Row.FindControl("lnlDelete");
            ImageButton btnEdit       = (ImageButton)e.Row.FindControl("lblEdit");
            int         CurrentUserID = GetSessionUserID();
            string      PageURL       = UDFLib.GetPageURL(Request.Path.ToUpper());

            SMS.Properties.UserAccess objUA   = new SMS.Properties.UserAccess();
            BLL_Infra_UserCredentials objUser = new BLL_Infra_UserCredentials();
            objUA = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);

            if (objUA.Edit == 0)
            {
                btnEdit.Visible = false;
            }
            else
            {
                btnEdit.Visible = true;
            }

            if (objUA.Delete == 0)
            {
                btnDelete.Visible = false;
            }
            else
            {
                btnDelete.Visible = true;
            }
        }
    }
Beispiel #17
0
    protected void UserAccessValidation()
    {
        int    CurrentUserID = GetSessionUserID();
        string PageURL       = UDFLib.GetPageURL(Request.Path.ToUpper());


        objUA = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);

        if (objUA.View == 0)
        {
            Response.Redirect("~/default.aspx?msgid=1");
        }

        if (objUA.Add == 0)
        {
        }
        if (objUA.Edit == 0)
        {
        }
        if (objUA.Delete == 0)
        {
        }

        if (objUA.Approve == 0)
        {
        }

        //-- MANNING OFFICE LOGIN --
    }
    protected void UserAccessValidation()
    {
        int    CurrentUserID = GetSessionUserID();
        string PageURL       = UDFLib.GetPageURL(Request.Path.ToUpper());

        BLL_Infra_UserCredentials objUser = new BLL_Infra_UserCredentials();

        objUA = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);

        if (objUA.View == 0)
        {
            Response.Redirect("~/default.aspx?msgid=1");
        }
        if (objUA.Admin == 0)
        {
            trAddNewSTWC     = trAddNewTanker = false;
            editDeleteAccess = false;
            rt2.Visible      = false;
        }

        if (objUA.Add == 1)
        {
            tdSave.Visible       = true;
            btnSave.Visible      = true;
            btnGroupSave.Visible = true;
        }
        else
        {
            tdSave.Visible       = false;
            btnSave.Visible      = false;
            btnGroupSave.Visible = false;
        }
    }
Beispiel #19
0
    /// <summary>
    /// Check for access rights
    /// </summary>
    protected void UserAccessValidation()
    {
        try
        {
            int    CurrentUserID = GetSessionUserID();
            string PageURL       = UDFLib.GetPageURL(Request.Path.ToUpper());

            BLL_Infra_UserCredentials objUser = new BLL_Infra_UserCredentials();
            UserAccess objUA = new UserAccess();
            objUA = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);

            if (objUA.View == 0)
            {
                MainDiv.Visible      = false;
                AccessMsgDiv.Visible = true;
            }
            else
            {
                MainDiv.Visible      = true;
                AccessMsgDiv.Visible = false;
            }

            if (objUA.Add == 0)
            {
                btnSave.Visible = false;
            }
        }
        catch (Exception ex)
        {
            UDFLib.WriteExceptionLog(ex);
        }
    }
Beispiel #20
0
    /// <summary>
    /// To check access rights of user for requested page
    /// </summary>
    protected void UserAccessValidation()
    {
        try
        {
            UserAccess objUA = new UserAccess();
            BLL_Infra_UserCredentials objUser = new BLL_Infra_UserCredentials();
            string PageURL = UDFLib.GetPageURL(Request.Path.ToUpper());

            objUA = objUser.Get_UserAccessForPage(Convert.ToInt32(Session["USERID"]), PageURL);

            if (objUA.View == 0)
            {
                Response.Redirect("~/default.aspx?msgid=1");
            }

            if (objUA.Add == 0)
            {
            }
            if (objUA.Edit == 1)
            {
                uaEditFlag = true;
            }

            if (objUA.Delete == 1)
            {
                uaDeleteFlage = true;
            }
        }
        catch (Exception ex)
        {
            UDFLib.WriteExceptionLog(ex);
        }
    }
Beispiel #21
0
    protected void UserAccessValidation()
    {
        int    CurrentUserID = GetSessionUserID();
        string PageURL       = UDFLib.GetPageURL(Request.Path.ToUpper());

        BLL_Infra_UserCredentials objUser = new BLL_Infra_UserCredentials();

        objUA = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);

        if (objUA.View == 0)
        {
            Response.Redirect("~/default.aspx");
        }

        if (objUA.Add == 0)
        {
            lnkEditInterviewPlanning.Visible = false;
            GridView1.Columns[GridView1.Columns.Count - 1].Visible = false;
        }
        if (objUA.Edit == 0)
        {
        }
        if (objUA.Delete == 0)
        {
        }

        if (objUA.Approve == 0)
        {
        }
        UAAdminRights = objUA.Admin.ToString();
    }
Beispiel #22
0
    protected void UserAccessValidation()
    {
        int    CurrentUserID = GetSessionUserID();
        string PageURL       = UDFLib.GetPageURL(Request.Path.ToUpper());

        objUA = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);

        if (objUA.View == 0)
        {
            lblMsg.Text = "You don't have sufficient privilege to access the requested information.";
        }
        if (objUA.Add == 0)
        {
            //   ImgAddTraining.Visible = false;
        }
        if (objUA.Edit == 0)
        {
            GridView_Trainings.Columns[GridView_Trainings.Columns.Count - 3].Visible = false;
        }
        if (objUA.Delete == 0)
        {
            GridView_Trainings.Columns[GridView_Trainings.Columns.Count - 2].Visible = false;
        }
        if (objUA.Approve == 0)
        {
        }
        //-- MANNING OFFICE LOGIN --
        if (Session["USERCOMPANYID"].ToString() != "1")
        {
        }
        else//--- CREW TEAM LOGIN--
        {
        }
    }
Beispiel #23
0
    protected void UserAccessValidation()
    {
        BLL_Infra_UserCredentials objUser = new BLL_Infra_UserCredentials();
        UserAccess objUA = new UserAccess();

        int    CurrentUserID = GetSessionUserID();
        string PageURL       = UDFLib.GetPageURL(Request.Path.ToUpper());

        objUA = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);

        if (objUA.View == 0)
        {
            Response.Redirect("~/default.aspx?msgid=1");
        }

        if (objUA.Add == 0)
        {
        }
        if (objUA.Edit == 0)
        {
        }
        if (objUA.Delete == 0)
        {
        }
        if (objUA.Approve == 0)
        {
        }
    }
    protected void UserAccessValidation()
    {
        int    CurrentUserID = GetSessionUserID();
        string PageURL       = UDFLib.GetPageURL(Request.Path.ToUpper());

        BLL_Infra_UserCredentials objUser = new BLL_Infra_UserCredentials();

        objUA = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);

        if (objUA.View == 0)
        {
            Response.Redirect("~/default.aspx?msgid=1");
        }


        if (objUA.Edit == 1)
        {
            uaEditFlag = true;
        }
        else
        // btnsave.Visible = false;
        if (objUA.Delete == 1)
        {
            uaDeleteFlage = true;
        }
    }
    protected void UserAccessValidation()
    {
        int    CurrentUserID = GetSessionUserID();
        string PageURL       = UDFLib.GetPageURL(Request.Path.ToUpper());

        BLL_Infra_UserCredentials objUser = new BLL_Infra_UserCredentials();

        objUA = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);

        if (objUA.View == 0)
        {
            pnl.Visible = false;
            lblMsg.Text = "You don't have sufficient previlege to access the requested information.";
        }
        else
        {
            pnl.Visible = true;
        }

        if (objUA.Add == 0)
        {
        }
        if (objUA.Edit == 1)
        {
            uaEditFlag = true;
        }
        //else
        // btnsave.Visible = false;

        if (objUA.Delete == 1)
        {
            uaDeleteFlage = true;
        }
    }
Beispiel #26
0
    protected void UserAccessValidation()
    {
        int    CurrentUserID = GetSessionUserID();
        string PageURL       = UDFLib.GetPageURL(Request.Path.ToUpper());

        UserAccess objUA = new UserAccess();
        BLL_Infra_UserCredentials objUser = new BLL_Infra_UserCredentials();

        objUA = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);

        if (objUA.View == 0)
        {
            Response.Write("<center><br><br><h2><font color=gray>You do not have enough priviledge to access this page.</font></h2></center>");
            Response.End();
        }
        if (objUA.Add == 0)
        {
            pnlUploadDocument.Enabled = false;
            //btnAddFolderAccess.Enabled = false;
        }
        if (objUA.Edit == 0)
        {
            pnlUploadDocument.Enabled = false;
        }
        if (objUA.Delete == 0)
        {
            //btnRemoveFolderAccess.Enabled = false;
        }

        if (objUA.Approve == 0)
        {
        }
    }
Beispiel #27
0
    protected void UserAccessValidation()
    {
        int    CurrentUserID = Convert.ToInt32(Session["userid"]);
        string PageURL       = UDFLib.GetPageURL(Request.Path.ToUpper());
        BLL_Infra_UserCredentials objUser = new BLL_Infra_UserCredentials();

        objUA = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);

        if (objUA.View == 0)
        {
            Response.Redirect("~/default.aspx?msgid=1");
        }

        if (objUA.Add == 0)
        {
            btnCreateContract.Visible = false;
        }
        if (objUA.Edit == 0)
        {
        }
        if (objUA.Approve == 0)
        {
            btnCreateContract.Visible = false;
        }
        if (objUA.Delete == 0)
        {
            // You don't have sufficient previlege to access the requested page.
        }
    }
    protected void UserAccessValidation()
    {
        int    CurrentUserID = GetSessionUserID();
        string PageURL       = UDFLib.GetPageURL(Request.Path.ToUpper());

        Session["PageURL"] = UDFLib.GetPageURL(Request.Path.ToUpper());
        BLL_Infra_UserCredentials objUser = new BLL_Infra_UserCredentials();

        objUA             = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);
        Session["Edit"]   = objUA.Edit;
        Session["Delete"] = objUA.Delete;
        Session["Add"]    = objUA.Add;
        if (objUA.View == 0)
        {
            Response.Redirect("~/default.aspx?msgid=1");
        }

        if (objUA.Add == 1)
        {
            uaAddFlag = true;
        }
        //    btnsave.Visible = false;
        if (objUA.Edit == 1)
        {
            uaEditFlag = true;
        }
        else
        {
            //btnAlert.Visible = false;
            //btnPortCost.Visible = false;
            //btnPort.Visible = false;
            //PortCallNotification.Visible = false;
        }
        if (objUA.Delete == 1)
        {
            uaDeleteFlage = true;
        }

        DataTable dt = objPortCall.Get_PortCallAlertList(Convert.ToInt32(Session["USERID"].ToString()), "0");

        if (dt.Rows.Count > 0)
        {
            int iCount = 0;
            foreach (DataRow dr in dt.Rows)
            {
                if (Convert.ToInt32(dr["READ_ID"]) == 0)
                {
                    iCount++;
                }
            }

            if (iCount > 0)
            {
                btnAlerts.Visible = true;
            }
        }
    }
Beispiel #29
0
    protected void UserAccessValidation()
    {
        string PageURL = UDFLib.GetPageURL(Request.Path.ToUpper());

        objUA = objUser.Get_UserAccessForPage(Convert.ToInt32(Session["USERID"]), PageURL);
        if (objUA.View == 0)
        {
            lblMsg.Text            = "You don't have sufficient privilege to access the requested information.";
            pnlViewFBMInfo.Visible = false;
        }
    }
    protected void UserAccessValidation()
    {
        int    CurrentUserID = GetSessionUserID();
        string PageURL       = UDFLib.GetPageURL(Request.Path.ToUpper());

        SMS.Properties.UserAccess objUA   = new SMS.Properties.UserAccess();
        BLL_Infra_UserCredentials objUser = new BLL_Infra_UserCredentials();

        objUA = objUser.Get_UserAccessForPage(CurrentUserID, PageURL);
        //if (objUA.View == 0)
        //    Response.Redirect("~/default.aspx?msgid=1");
    }