Ejemplo n.º 1
0
        protected void ButtonYear_Click(object sender, EventArgs e)
        {
            int year = int.Parse(DropDownListYears.SelectedItem.ToString());

            idNotary = int.Parse(Session["NotaryID"].ToString());
            GridViewOwnWritings.DataSource       = bll.getAllOwnWritingsByNotary(idNotary, year);
            GridViewCo_NotaryWritings.DataSource = bll.getAllCoNotariesByNotary(idNotary, year);
            GridViewOwnWritings.DataBind();
            GridViewCo_NotaryWritings.DataBind();
            LabelYear.Text        = year + "";
            Session["ExportYear"] = year + "";
        }
Ejemplo n.º 2
0
        private void load()
        {
            notary              = bll.loadProtocolInfo(Session["ProtocolID"].ToString());
            LabelName.Text      = notary.NotaryName;
            LabelInitials.Text  = notary.NotaryInitials;
            LabelRBT.Text       = notary.RBTEnabled;
            LabelAvailable.Text = notary.NotaryAvailable;
            idNotary            = notary.NotaryID;
            Session["NotaryID"] = idNotary;
            int allwritingsByNotary = bll.getAllMovemetsByIdNotary(notary.NotaryID, bll.getActualFiscalYear());

            LabelTotalYear.Text = allwritingsByNotary + "";

            /*Resumen de cada Mes*/
            GridViewTotalYear.DataSource = bll.showSummaryYearPerMonths(notary.NotaryID);
            GridViewTotalYear.DataBind();
            LabelAnualActualLimit.Text = (notary.BalanceLimitMonth - allwritingsByNotary) + "";
            LabelAnualLimit.Text       = notary.BalanceLimitMonth + "";
            loadDropDown();
            /*Ultimos datos*/
            GridViewOwnWritings.DataSource       = bll.getAllOwnWritingsByNotary(idNotary, bll.getLastFiscalYear());
            GridViewCo_NotaryWritings.DataSource = bll.getAllCoNotariesByNotary(idNotary, bll.getLastFiscalYear());
            GridViewOwnWritings.DataBind();
            GridViewCo_NotaryWritings.DataBind();

            string protocolIDVar1 = Session["ProtocolID"].ToString();
            int    protocolIDvar  = int.Parse(protocolIDVar1);

            LabelMensualLimit.Text       = bll.getMensualLimitByProtocol(protocolIDvar) + "";
            LabelMensualActualLimit.Text = bll.getMensualActualLimitByProtocol(LabelName.Text) + "";



            LabelMonth.Text = bll.getMonth();
            LabelYear.Text  = bll.getLastFiscalYear() + "";


            GridViewMonths.DataSource = bll.loadAllWritingsByProtocol(notary.NotaryID);
            GridViewMonths.DataBind();
            LabelAnualActualLimitFake.Visible   = false;
            LabelMensualActualLimitFake.Visible = false;
            switch (Session["Varload"].ToString())
            {
            case "0":

                Session["Varload"] = "Por Defecto";
                alertBalance();
                break;
            }
        }