protected void InsertSupplierAPI()
        {
            SupplierAPItbl sa = new SupplierAPItbl();

            sa.SupplierId  = Convert.ToInt32(ddlSupplierID.SelectedValue);
            sa.APILink     = txtAPILink.Text;
            sa.APIKey      = txtAPIKey.Text;
            sa.Username    = txtUsername.Text;
            sa.Password    = txtPassword.Text;
            sa.Description = txtDescription.Text;

            lstSupAPI = objsupAPIBL.InsertSupAPI(sa).ToList();
            ScriptManager.RegisterStartupScript(this, GetType(), "alertMessage", "alertMessage('Data Inserted Successfully');", true);
            btnUpdate.Visible = false;
            btnSave.Visible   = true;

            Reset();
        }
        protected void GetSupplierAPIById(int id)
        {
            SupplierAPItbl sa = new SupplierAPItbl();

            sa.SupplierAPIId = Convert.ToInt32(id.ToString());
            List <SupplierAPItbl> lsa = new List <SupplierAPItbl>();

            lsa = objsupAPIBL.GetSupAPIbyId(sa).ToList();

            foreach (var el in lsa)
            {
                hdnSupplierAPIId.Value      = Convert.ToString(el.SupplierAPIId);
                ddlSupplierID.SelectedValue = el.SupplierId.ToString();
                txtAPILink.Text             = el.APILink;
                txtAPIKey.Text      = el.APIKey;
                txtUsername.Text    = el.Username;
                txtPassword.Text    = el.Password;
                txtDescription.Text = el.Description;
            }
            btnSave.Visible   = false;
            btnUpdate.Visible = true;
        }
 public IEnumerable <SupplierAPItbl> DeleteSupAPI(SupplierAPItbl sa)
 {
     return(objSupAPIDA.SupplierAPIAll(5, sa));
 }
 public IEnumerable <SupplierAPItbl> UpdateSupAPI(SupplierAPItbl sa)
 {
     return(objSupAPIDA.SupplierAPIAll(4, sa));
 }
 public IEnumerable <SupplierAPItbl> InsertSupAPI(SupplierAPItbl sa)
 {
     return(objSupAPIDA.SupplierAPIAll(3, sa));
 }
 public IEnumerable <SupplierAPItbl> GetSupAPIbyId(SupplierAPItbl sa)
 {
     return(objSupAPIDA.SupplierAPIAll(2, sa));
 }
 public IEnumerable <SupplierAPItbl> GetAllSupplierAPI(SupplierAPItbl sa)
 {
     return(objSupAPIDA.SupplierAPIAll(1, sa));
 }