示例#1
0
    protected void Page_Load(object sender, EventArgs e)
    {
        LoanAccountDSTableAdapters.GetLoanAccountTableAdapter loanAcc = new LoanAccountDSTableAdapters.GetLoanAccountTableAdapter();

        if (Request.QueryString["id"] == null)
        {
        }
        else
        {
            string EncID = Request.QueryString["id"];
            int    DecID = Convert.ToInt32(MyEncryption.Decrypt(EncID, "12345678910"));
            MySessionManager.AccountID = DecID;
            MySessionManager.ClientID  = Convert.ToInt32(loanAcc.GetClientIDFromAcc(Convert.ToInt32(MySessionManager.AccountID)));
        }

        if (Request.QueryString["action"] != null)
        {
            //  MySessionManager.CurrentTab=null;
            string action = Request.QueryString["action"];
            MySessionManager.CurrentTab = action;
            setPanel(action);
            Response.Redirect(util.RemoveQueryStringByKey(HttpContext.Current.Request.Url.AbsoluteUri, "action"));
        }
        else
        {
            setPanel("");
        }

        showAccountInfomartion();
        setUrls();
    }
 protected void Page_Load(object sender, EventArgs e)
 {
     ///Querystring Block
     ///
     if (Request.QueryString.Count > 0)
     {
         InvestmentAccountDSTableAdapters.GetInvAccountTableAdapter invAcc = new InvestmentAccountDSTableAdapters.GetInvAccountTableAdapter();
         string EncID = Request.QueryString["id"];
         int    DecID = Convert.ToInt32(MyEncryption.Decrypt(EncID, "12345678910"));
         MySessionManager.InvAccID = DecID;
         MySessionManager.ClientID = Convert.ToInt32(invAcc.GetClientID(MySessionManager.InvAppID));
         if (Request.QueryString["action"] == "int")
         {
             Page.Title = "Interest Maturity";
         }
         if (Request.QueryString["action"] == "inv")
         {
             Page.Title = "Investment Maturity";
         }
         if (Request.QueryString["action"] == "rol")
         {
             Page.Title = "Roll Over";
         }
     }
     setNotifications();
 }
示例#3
0
    protected void Page_Load(object sender, EventArgs e)
    {
        InvestmentDSTableAdapters.GetInvestmentAppTableAdapter invApp = new InvestmentDSTableAdapters.GetInvestmentAppTableAdapter();

        //int DecID = Convert.ToInt32(EncID);


        #region "QueryString Block"
        string EncID = Request.QueryString["id"];
        int    DecID = Convert.ToInt32(MyEncryption.Decrypt(EncID, "12345678910"));
        MySessionManager.InvAppID = DecID;
        MySessionManager.ClientID = Convert.ToInt32(invApp.GetClientID(MySessionManager.InvAppID));
        #endregion
        setNotifications();
        if ((!(util.alert1() == "")) && (MySessionManager.skipAlert == 0))
        {
            this.pAlertmsg.InnerText = util.alert1();
            // Define the name and type of the client scripts on the page.
            String csname1 = "PopupScript";
            String csname2 = "ButtonClickScript";
            Type   cstype  = this.GetType();

            // Get a ClientScriptManager reference from the Page class.
            ClientScriptManager cs = Page.ClientScript;

            // Check to see if the startup script is already registered.
            if (!cs.IsStartupScriptRegistered(cstype, csname1))
            {
                String cstext1 = "alertMessage();";
                cs.RegisterStartupScript(cstype, csname1, cstext1, true);
            }
            MySessionManager.skipAlert = 1;
        }
        showLoanAppInfo();
    }
示例#4
0
    protected void btnSaveAlert_Click(object sender, EventArgs e)
    {
        string EncID = appID.Value.Trim();
        int    DecID = Convert.ToInt32(MyEncryption.Decrypt(EncID, "12345678910"));

        LoanDSTableAdapters.LoanApplicationsTableAdapter loanApp = new LoanDSTableAdapters.LoanApplicationsTableAdapter();
        loanApp.saveAlert(alertmsg.Value,
                          DecID);
    }
    protected void btnSaveAlert_Click(object sender, EventArgs e)
    {
        string EncID = appID.Value.Trim();
        int    DecID = Convert.ToInt32(MyEncryption.Decrypt(EncID, "12345678910"));

        InvestmentDSTableAdapters.GetAlertTableAdapter InvApp = new InvestmentDSTableAdapters.GetAlertTableAdapter();
        InvApp.SaveInvAlert(alertmsg.Value,
                            DecID);
    }
示例#6
0
    protected void Page_Load(object sender, EventArgs e)
    {
        this.lblUserName.InnerText = "";

        if (Request.QueryString["id"] != null)
        {
            int id = Convert.ToInt32(MyEncryption.Decrypt(Request.QueryString["id"], "123456789"));

            SqlDataSource2.SelectParameters["userID"].DefaultValue = id.ToString();
        }
    }
    protected void Page_Load(object sender, EventArgs e)
    {
        ///Querystring Block
        InvestmentAccountDSTableAdapters.GetInvAccountTableAdapter invAcc = new InvestmentAccountDSTableAdapters.GetInvAccountTableAdapter();
        string EncID = Request.QueryString["id"];
        int    DecID = Convert.ToInt32(MyEncryption.Decrypt(EncID, "12345678910"));

        MySessionManager.InvAccID = DecID;
        MySessionManager.ClientID = Convert.ToInt32(invAcc.GetClientID(MySessionManager.InvAppID));


        setNotifications();
    }
    protected void Page_Load(object sender, EventArgs e)
    {
        #region QueryString
        if (Request.QueryString["id"] == null)
        {
        }
        else
        {
            string EncID = Request.QueryString["id"];
            int    DecID = Convert.ToInt32(MyEncryption.Decrypt(EncID, "12345678910"));
            this.userID.Value = DecID.ToString();
        }

        #endregion

        Panel seperator = new Panel();

        adminTableAdapters.GetAccessCodesTableAdapter AccessCodes = new adminTableAdapters.GetAccessCodesTableAdapter();
        admin.GetAccessCodesDataTable tblAccessCodes = AccessCodes.GetAccessMenuTypes();
        foreach (admin.GetAccessCodesRow tbl in tblAccessCodes)
        {
            Panel menuDiv = new Panel();
            HtmlGenericControl menuHdrDiv  = new HtmlGenericControl("div");
            HtmlGenericControl menuContDiv = new HtmlGenericControl("div");
            menuDiv.ID           = "menu_" + tbl.datType.ToString();
            menuHdrDiv.InnerHtml = "<p><h5><small> " + tbl.datType.ToString() + " </small></h5><hr style='margin:5px'/></p>";

            admin.GetAccessCodesDataTable tblAccessData = AccessCodes.GetAccessCodes(tbl.datType.ToString());
            foreach (admin.GetAccessCodesRow tbl1  in tblAccessData)
            {
                CheckBox chk1 = new CheckBox();
                chk1.ID       = "chk_" + tbl1.datID.ToString();
                chk1.CssClass = "checkbox";
                chk1.Text     = tbl1.datDescription.ToString();
                HtmlGenericControl formgroupDiv = new HtmlGenericControl("div");

                formgroupDiv.Attributes["class"] = "form-group";

                formgroupDiv.Controls.Add(chk1);
                menuContDiv.Controls.Add(formgroupDiv);
            }
            menuDiv.Controls.Add(menuHdrDiv);
            menuDiv.Controls.Add(menuContDiv);

            this.mainContainer.Controls.Add(menuDiv);
        }
        if (this.userID.Value != "")
        {
            LoadCheckItems(Convert.ToInt32(this.userID.Value));
        }
    }
 protected void Page_Load(object sender, EventArgs e)
 {
     #region QueryStringBlock
     if (Request.QueryString["id"] == null)
     {
     }
     else
     {
         string EncID = Request.QueryString["id"];
         int    DecID = Convert.ToInt32(MyEncryption.Decrypt(EncID, "12345678910"));
         //MySessionManager.AppID = DecID;
         //int DecID = Convert.ToInt32(EncID);
         MySessionManager.ClientID = DecID;
         getProfileType(MySessionManager.ClientID);
     }
     #endregion
 }
    protected void btnApply_Click(object sender, EventArgs e)
    {
        mainDSTableAdapters.ClientTableAdapter client = new mainDSTableAdapters.ClientTableAdapter();

        string EncID = this.ckey.Value;
        //Request.QueryString["id"];
        int DecID = Convert.ToInt32(MyEncryption.Decrypt(EncID, "12345678910"));
        int cType = Convert.ToInt32(client.GetClientType(DecID));

        if (ddlProducts.SelectedValue == "1")
        {
            int lType = 0;
            if (cType == 1)
            {
                lType = 1;
            }
            else if (cType == 2)
            {
                lType = 2;
            }
            else if (cType == 3)
            {
                lType = 4;
            }
            LoanDSTableAdapters.LoanApplicationsTableAdapter loanApp = new LoanDSTableAdapters.LoanApplicationsTableAdapter();
            string clientname = client.GetClientsName(DecID).ToString();

            loanApp.InsertNewApplication(DecID,
                                         clientname,
                                         lType,
                                         MySessionManager.CurrentUser.BranchID,
                                         MySessionManager.CurrentUser.UserID);
            ShowMessageBox("Loan Application for " + clientname + " submited successfully");
        }
        else if (ddlProducts.SelectedValue == "2")
        {
            string clientname = client.GetClientsName(DecID).ToString();

            InvestmentDSTableAdapters.GetInvestmentAppTableAdapter invapp = new InvestmentDSTableAdapters.GetInvestmentAppTableAdapter();
            invapp.InsertInvestmentApplication(DecID,
                                               clientname,
                                               1,
                                               MySessionManager.CurrentUser.BranchID);
            ShowMessageBox("Investment Application for " + clientname + " submited successfully");
        }
    }
    protected void Page_Load(object sender, EventArgs e)
    {
        InvestmentDSTableAdapters.GetInvestmentAppTableAdapter invApp = new InvestmentDSTableAdapters.GetInvestmentAppTableAdapter();

        //int DecID = Convert.ToInt32(EncID);


        #region "QueryString Block"
        string EncID = Request.QueryString["id"];
        int    DecID = Convert.ToInt32(MyEncryption.Decrypt(EncID, "12345678910"));
        MySessionManager.InvAppID = DecID;
        MySessionManager.ClientID = Convert.ToInt32(invApp.GetClientID(MySessionManager.InvAppID));
        #endregion
        try
        {
            mainDSTableAdapters.NotificationCountTableAdapter tblCounter = new mainDSTableAdapters.NotificationCountTableAdapter();
            mainDS.NotificationCountRow itemcount = tblCounter.NotificationCount(MySessionManager.CurrentUser.BranchID, MySessionManager.CurrentUser.UserID, MySessionManager.CurrentUser.TeamID)[0];

            this.pendingRecInfo.InnerText = (Convert.ToInt32(itemcount.receipts.ToString())).ToString();
            this.pendingDisInfo.InnerText = (Convert.ToInt32(itemcount.disbursementI.ToString()) + Convert.ToInt32(itemcount.disbursementII.ToString()) + Convert.ToInt32(itemcount.disbursementIII.ToString())).ToString();
        }
        catch (Exception ex)
        {
        }
        if ((!(util.alert1() == "")) && (MySessionManager.skipAlert == 0))
        {
            this.pAlertmsg.InnerText = util.alert1();
            // Define the name and type of the client scripts on the page.
            String csname1 = "PopupScript";
            String csname2 = "ButtonClickScript";
            Type   cstype  = this.GetType();

            // Get a ClientScriptManager reference from the Page class.
            ClientScriptManager cs = Page.ClientScript;

            // Check to see if the startup script is already registered.
            if (!cs.IsStartupScriptRegistered(cstype, csname1))
            {
                String cstext1 = "alertMessage();";
                cs.RegisterStartupScript(cstype, csname1, cstext1, true);
            }
            MySessionManager.skipAlert = 1;
        }
        showLoanAppInfo();
    }
示例#12
0
 protected void Page_Load(object sender, EventArgs e)
 {
     if (Request.QueryString["id"] == null)
     {
         this.applicationtrails1.Visible = true;
         this.applicationtrail1.Visible  = false;
     }
     else
     {
         if (Request.QueryString["id"].Length > 0)
         {
             this.applicationtrail1.Visible  = true;
             this.applicationtrails1.Visible = false;
             string EncID = Request.QueryString["id"];
             int    DecID = Convert.ToInt32(MyEncryption.Decrypt(EncID, "12345678910"));
             MySessionManager.AppID = DecID;
         }
     }
 }
示例#13
0
    protected void Page_Load(object sender, EventArgs e)
    {
        #region QueryStringBlock
        if (Request.QueryString["id"] == null)
        {
        }
        else
        {
            string EncID = Request.QueryString["id"];
            int    DecID = Convert.ToInt32(MyEncryption.Decrypt(EncID, "12345678910"));
            //MySessionManager.AppID = DecID;
            //int DecID = Convert.ToInt32(EncID);
            MySessionManager.ClientID = DecID;
            loadClientInformation(MySessionManager.ClientID);
        }

        #endregion

        coporateclientprofile.Visible   = false;
        individualclientprofile.Visible = false;
        enterpriseclientprofile.Visible = false;
        loanaccounts.Visible            = false;
        invaccounts.Visible             = false;
        pendingloans.Visible            = false;
        pendinginvestments.Visible      = false;
        statuslog.Visible = false;

        if (Request.QueryString["loanAppid"] == null)
        {
        }
        else
        {
            string EncID = Request.QueryString["loanAppid"];
            int    DecID = Convert.ToInt32(MyEncryption.Decrypt(EncID, "12345678910"));
            //MySessionManager.AppID = DecID;
            //int DecID = Convert.ToInt32(EncID);
            MySessionManager.AppID = DecID;
            loadClientInformation(MySessionManager.ClientID);
            statuslog.Visible = true;
        }
    }
    protected void Page_Load(object sender, EventArgs e)
    {
        mTempTableAdapters.GetTransactionDetailsTableAdapter tempHolder = new mTempTableAdapters.GetTransactionDetailsTableAdapter();
        #region QueryStringBlock
        if (Request.QueryString["id"] != null)
        {
            string EncID = Request.QueryString["id"];
            int    DecID = Convert.ToInt32(MyEncryption.Decrypt(EncID, "12345678910"));
            MySessionManager.AccountID = DecID;
            //  ShowMessageBox(" " + DecID + " ");
            LoanAccountDSTableAdapters.GetLoanAccountTableAdapter loanAcc = new LoanAccountDSTableAdapters.GetLoanAccountTableAdapter();
            LoanAccountDS.GetLoanAccountDataTable tblLoanAcc = loanAcc.GetLoanAccount(Convert.ToInt32(MySessionManager.AccountID));
            if (tblLoanAcc.Rows.Count > 0)
            {
                lblClient.InnerText   = tblLoanAcc[0].datClientFullName.ToString();
                lblbranch.InnerText   = util.displayValue("tbl_teams", tblLoanAcc[0].datTeamID.ToString());
                lbldate.InnerText     = tblLoanAcc[0].datStartDate.ToLongDateString();
                lbltotalamt.InnerText = tblLoanAcc[0].datOutstandingAmount.ToString("C").Replace("$", "");
            }
        }
        if (!(Request.QueryString["trdelete"] == null))
        {
            try
            {
                string id = Request.QueryString["trdelete"];
                tempHolder.DeleteTransactionDetails1(Convert.ToInt32(MySessionManager.AccountID), Convert.ToInt32(id));

                Page.Response.Redirect(util.RemoveQueryStringByKey(HttpContext.Current.Request.Url.AbsoluteUri, "trdelete"));
            }
            catch
            { }
        }
        #endregion
        try
        { lblTotal.Text = tempHolder.GetTransTotalAmount(MySessionManager.AppID).ToString(); }
        catch (Exception ex)
        {
            lblTotal.Text = "0.00";
        }
    }
示例#15
0
        /// <summary>
        /// This Method Decrypts Any Value To Original String With Specific Ways Described In The Type
        /// </summary>
        /// <example>string Encryption.Decrypt("BlaBlaBla",Ecryptiontypes.FormAuth);</example>

        public static string Decrypt(string strToDecrypt, Encryptiontypes type)
        {
            string back = "";

            try
            {
                switch (type)
                {
                case Encryptiontypes.Mine:
                    MyEncryption my = new MyEncryption();
                    back = my.Decrypt(strToDecrypt);
                    break;

                case Encryptiontypes.FormAuth:
                    Encryption en = new Encryption();
                    back = en.DecryptFrmAuth(strToDecrypt);
                    break;

                case Encryptiontypes.Des:
                    SymmCrypto sy = new SymmCrypto(SymmCrypto.SymmProvEnum.DES);
                    back = sy.Decrypting(strToDecrypt, "");
                    break;

                case Encryptiontypes.Rijndal:
                    SymmCrypto syy = new SymmCrypto(SymmCrypto.SymmProvEnum.Rijndael);
                    back = syy.Decrypting(strToDecrypt, "");
                    break;

                default:
                    break;
                }
            }
            catch
            {
                back = "";
            }
            return(back);
        }
示例#16
0
 protected void btnSaveRole_Click(object sender, EventArgs e)
 {
     try
     {
         if (Request.QueryString["id"] != null)
         {
             int id = Convert.ToInt32(MyEncryption.Decrypt(Request.QueryString["id"], "123456789"));
             adminTableAdapters.tbl_secondary_rolesTableAdapter role = new adminTableAdapters.tbl_secondary_rolesTableAdapter();
             int?ct = null;
             if (ddlCreditTeam.SelectedValue != "0")
             {
                 ct = Convert.ToInt32(ddlCreditTeam.SelectedValue);
             }
             role.Insert(id,
                         Convert.ToInt32(ddlPosition.SelectedValue),
                         ddlPosition.SelectedItem.Text,
                         ct,
                         Convert.ToInt32(ddlBranch.SelectedValue)
                         );
         }
     }
     catch (Exception ex) { }
 }
示例#17
0
    protected void Page_Load(object sender, EventArgs e)
    {
        if (MySessionManager.CurrentUser == null)
        {
            Response.Redirect("~/logout.aspx");
        }
        LoanDSTableAdapters.LoanApplicationsTableAdapter loanApp = new LoanDSTableAdapters.LoanApplicationsTableAdapter();
        setNotifications();
        showLoanAppInfo();
        setUrls();
        if (Request.QueryString["id"] == null)
        {
        }
        else
        {
            string EncID = Request.QueryString["id"];
            int    DecID = Convert.ToInt32(MyEncryption.Decrypt(EncID, "12345678910"));
            MySessionManager.AppID    = DecID;
            MySessionManager.ClientID = Convert.ToInt32(loanApp.getClientID(MySessionManager.AppID));
            showLoanAppInfo();
        }
        if (!(Request.QueryString["ops"] == null))
        {
            if (!(Request.QueryString["tab"] == null))
            {
                if (!(Request.QueryString["tab"] == ""))
                {
                    currentTab = int.Parse(Request.QueryString["tab"]);
                }
                else
                {
                    currentTab = Convert.ToInt32(MySessionManager.CurrentTab);
                }
                ops = Request.QueryString["ops"].ToString();
                setTab();
                MySessionManager.CurrentTab = currentTab.ToString();
                MySessionManager.OpsTab     = "load";

                string urlpath = util.RemoveQueryStringByKey(HttpContext.Current.Request.Url.AbsoluteUri, "tab");
                urlpath = util.RemoveQueryStringByKey(urlpath, "ops");
                Response.Redirect(urlpath);
            }
            else
            {
                if (!(Request.QueryString["tab"] == ""))
                {
                    currentTab = int.Parse(Request.QueryString["tab"]);
                }
                else
                {
                    currentTab = 0;
                }

                ops = "load";
                setTab();

                MySessionManager.CurrentTab = currentTab.ToString();
                MySessionManager.OpsTab     = "load";
                util.RemoveQueryStringByKey(HttpContext.Current.Request.Url.AbsoluteUri, "tab");
                util.RemoveQueryStringByKey(HttpContext.Current.Request.Url.AbsoluteUri, "ops");
            }
        }
        else
        {
            ops = MySessionManager.OpsTab.ToString();

            //For handling the tabs
            if (!(MySessionManager.CurrentTab == ""))
            {
                currentTab = int.Parse(MySessionManager.CurrentTab);
            }
            else
            {
                currentTab = 0;
            }

            setTab();
        }
        if ((!(util.alert() == "")) && (MySessionManager.skipAlert == 0))
        {
            this.pAlertmsg.InnerText = util.alert();
            // Define the name and type of the client scripts on the page.
            String csname1 = "PopupScript";
            String csname2 = "ButtonClickScript";
            Type   cstype  = this.GetType();

            // Get a ClientScriptManager reference from the Page class.
            ClientScriptManager cs = Page.ClientScript;

            // Check to see if the startup script is already registered.
            if (!cs.IsStartupScriptRegistered(cstype, csname1))
            {
                String cstext1 = "alertMessage();";
                cs.RegisterStartupScript(cstype, csname1, cstext1, true);
            }
            MySessionManager.skipAlert = 1;
        }
    }
示例#18
0
        public string DecryptMine(string val)
        {
            MyEncryption my = new MyEncryption();

            return(my.Decrypt(val));
        }