Example #1
0
 private bool CreateBrandName()
 {
     objRegion                   = new Region();
     objRegionBiz                = new RegionBiz();
     objRegion.RegionName        = txtRegionName.Text.Trim();
     objRegion.RegionDescription = txtRegionDescription.Text.Trim();
     objRegion.CreatedBy         = Convert.ToInt16(Session["userId"].ToString());
     MessageBox(objRegionBiz.CreateRegionName(objRegion));
     return(true);
 }
Example #2
0
        private void PopulateDropDownForRegion()
        {
            List <Region> objRegionList = new List <Region>();

            objRegionBiz = new RegionBiz();

            objRegionList            = objRegionBiz.GetRegionList();
            ddlRegion.DataSource     = objRegionList;
            ddlRegion.DataValueField = "RegionId";
            ddlRegion.DataTextField  = "RegionName";
            ddlRegion.DataBind();
        }
Example #3
0
        private void PopulateDropDownForRegion()
        {
            List <Region> objRegionList = new List <Region>();

            objRegionBiz = new RegionBiz();

            objRegionList            = objRegionBiz.GetRegionList();
            ddlRegion.DataSource     = objRegionList;
            ddlRegion.DataValueField = "RegionId";
            ddlRegion.DataTextField  = "RegionName";
            ddlRegion.DataBind();

            ddlRegion.Items.Insert(0, new ListItem("--Select Region--", "0"));
        }
Example #4
0
        private bool EditRegion()
        {
            objRegion    = new Region();
            objRegionBiz = new RegionBiz();
            GridViewRow row = gvRegion.SelectedRow;

            objRegion.RegionId          = Convert.ToByte(gvRegion.DataKeys[row.RowIndex].Values[0].ToString());
            objRegion.RegionName        = txtUpdateRegionName.Text.Trim();
            objRegion.RegionDescription = txtUpdateRegionDescription.Text.Trim();
            objRegion.IsActive          = ddlUpdateRegionStatus.SelectedValue == "1";
            objRegion.UpdatedBy         = Convert.ToInt16(Session["UserId"]);

            return(objRegionBiz.UpdateRegion(objRegion));
        }
Example #5
0
        private void GvBindRegion()
        {
            objRegion    = new Region();
            objRegionBiz = new RegionBiz();
            DataTable dtRegion = new DataTable();

            dtRegion            = objRegionBiz.GetRegionForGv(txtRegionName.Text.Trim());
            gvRegion.DataSource = dtRegion;
            gvRegion.DataBind();
            gvRegion.ShowHeaderWhenEmpty = true;
            gvRegion.EmptyDataText       = "No data found!";

            gvRegion.AlternatingRowStyle.BackColor = Color.AliceBlue;
            gvRegion.SelectedRowStyle.BackColor    = Color.DarkKhaki;
        }
Example #6
0
 public void Init()
 {
     _FakeUOW_AccesosDB = new FakeUOW_AccesosDB();
     _FakeUOW_AccesosDB.ACC_sRegiones = Regiones();
     _servicio = new RegionBiz(_FakeUOW_AccesosDB);
 }