예제 #1
0
        protected void Page_Load(object sender, EventArgs e)
        {
            try
            {
                TrackManagement2PageManager ObjTrackManagement2PageManager = new TrackManagement2PageManager();
                LstEvtType  = ObjTrackManagement2PageManager.GetEventsType();
                LstHouse    = ObjTrackManagement2PageManager.GetHouse();
                LstLandlord = ObjTrackManagement2PageManager.GetLandlords();
                LstParty    = ObjTrackManagement2PageManager.GetParties();


                if (!Page.IsPostBack)
                {
                    PopolaCboTemplate(CboTemplates);

                    //TextBox1.Text = (new DateTime(DateTime.Now.Year, DateTime.Now.Month, 30)).ToString();
                    //string date = DateTime.Now;
                    //dataprova.Value = (new DateTime(DateTime.Now.Year, DateTime.Now.Month, 30)).ToString();
                    //AuditPageManager ObjAuditPageManager = new AuditPageManager();

                    //popola le combo
                    //PopolaCboUsers(CboUsers, ObjAuditPageManager.GetUsers());
                    //CboUsers.Items.Add(new ListItem("--Select--", "0"));
                    //Utility.SetDropByValue(CboUsers, "0");

                    ////inizializza classi CSS del paginatore
                    //HidePreviousClass = "disabled";

                    //bindong a tabella
                    BindBrotherEvts();
                    //BindRepeater();

                    //aggiunge il tag script con il path del file jquery con la validazione della pagina nella masterpage
                    Literal LitPathFormScriptValidation = (Literal)Master.FindControl("LitPathFormScriptValidation");

                    //LitPathFormScriptValidation.Text = "<script src='../js/TrackManagement.js'></script>";
                    //LitRe2017ScriptInject.Text= "<script src='../js/TrackManagement.js'></script>";
                    // ViewState["LstEvtType"] = LstEvtType;
                }
            }
            catch (Exception ex)
            {
                PrintError(ex);
            }
        }
        protected void Page_Load(object sender, EventArgs e)
        {
            try
            {
                TrackManagement2PageManager ObjTrackManagement2PageManager = new TrackManagement2PageManager();
                LstEvtType  = ObjTrackManagement2PageManager.GetEventsType();
                LstHouse    = ObjTrackManagement2PageManager.GetHouse();
                LstLandlord = ObjTrackManagement2PageManager.GetLandlords();
                LstParty    = ObjTrackManagement2PageManager.GetParties();

                if (!Page.IsPostBack)
                {
                    if (Request.QueryString["Id"] == null)
                    {
                        LitTitle.Text = "Create new template";
                    }
                    else
                    {
                        LitTitle.Text          = "Update template";
                        MemIdTemp              = Request.QueryString["Id"].ToString();
                        ViewState["MemIdTemp"] = Request.QueryString["Id"].ToString();

                        PnlSplitting.Visible         = true;
                        PnlBtnCreateTemplate.Visible = false;
                    }
                    BindEvts();


                    //aggiunge il tag script con il path del file jquery con la validazione della pagina nella masterpage
                    Literal LitPathFormScriptValidation = (Literal)Master.FindControl("LitPathFormScriptValidation");

                    //LitPathFormScriptValidation.Text = "<script src='../js/TrackManagement.js'></script>";
                    //LitRe2017ScriptInject.Text= "<script src='../js/TrackManagement.js'></script>";
                    // ViewState["LstEvtType"] = LstEvtType;
                }
            }
            catch (Exception ex)
            {
                PrintError(ex);
            }
        }
예제 #3
0
        protected void Page_Load(object sender, EventArgs e)
        {
            try
            {
                TrackManagement2PageManager ObjTrackManagement2PageManager = new TrackManagement2PageManager();
                LstEvtType  = ObjTrackManagement2PageManager.GetEventsType();
                LstHouse    = ObjTrackManagement2PageManager.GetHouse();
                LstLandlord = ObjTrackManagement2PageManager.GetLandlords();
                LstParty    = ObjTrackManagement2PageManager.GetParties();

                if (!Page.IsPostBack)
                {
                    if (Request.Cookies["TxtDa"] == null)
                    {
                        TxtDa.Text = (new DateTime(DateTime.Now.Year, DateTime.Now.Month, 1)).ToString("yyyy-MM-dd");
                        TxtA.Text  = (new DateTime(DateTime.Now.Year, DateTime.Now.Month, DateTime.DaysInMonth(DateTime.Now.Year, DateTime.Now.Month))).ToString("yyyy-MM-dd");
                    }
                    else
                    {
                        TxtDa.Text = Request.Cookies["TxtDa"].Value;
                        TxtA.Text  = Request.Cookies["TxtA"].Value;
                    }


                    //TextBox1.Text = (new DateTime(DateTime.Now.Year, DateTime.Now.Month, 30)).ToString();
                    //string date = DateTime.Now;
                    //dataprova.Value = (new DateTime(DateTime.Now.Year, DateTime.Now.Month, 30)).ToString();
                    //AuditPageManager ObjAuditPageManager = new AuditPageManager();

                    //popola le combo
                    //PopolaCboUsers(CboUsers, ObjAuditPageManager.GetUsers());
                    //CboUsers.Items.Add(new ListItem("--Select--", "0"));
                    //Utility.SetDropByValue(CboUsers, "0");

                    //inizializza classi CSS del paginatore
                    HidePreviousClass = "disabled";



                    //aggiunge il tag script con il path del file jquery con la validazione della pagina nella masterpage
                    Literal LitPathFormScriptValidation = (Literal)Master.FindControl("LitPathFormScriptValidation");
                    //LitPathFormScriptValidation.Text = "<script src='../js/TrackManagement.js'></script>";
                    //LitRe2017ScriptInject.Text= "<script src='../js/TrackManagement.js'></script>";
                    // ViewState["LstEvtType"] = LstEvtType;
                }

                //bindong a tabella
                BindRepeater();
                ////*******************
                ////chiamata put da togliere
                //UpdateHouseEvtInputDto ObjUpdateHouseEvtInputDto = new UpdateHouseEvtInputDto(); //data = "{'id': 99,'houseId':6}";
                //ObjUpdateHouseEvtInputDto.id = 99;
                //ObjUpdateHouseEvtInputDto.houseId = 7;
                //ObjTrackManagement2PageManager.UpdateHouseEvt(ObjUpdateHouseEvtInputDto);
                ////*****************
            }
            catch (Exception ex)
            {
                PrintError(ex);
            }
        }