Example #1
0
 public void ShowSuppliers(IEnumerable <SupplierDTO> supplierDtos)
 {
     SupplierResultsGridView.DataSource    = supplierDtos;
     SupplierResultsGridView.EmptyDataText = Constants.EmptyData.SupplierResults;
     SupplierResultsGridView.DataBind();
     SupplierResultsGridView.EmptyDataText = string.Empty;
 }
Example #2
0
        protected void SupplierResultsGridView_SelectedIndexChanged(object sender, EventArgs e)
        {
            var selectedSupplierId = int.Parse(SupplierResultsGridView.DataKeys[SupplierResultsGridView.SelectedRow.RowIndex].Value.ToString());

            using (var partManagementRepository = SharePointServiceLocator.GetCurrent().GetInstance <IPartManagementRepository>())
            {
                if (this.Page.Request.QueryString[Constants.PartSku] != null)
                {
                    //Add Part Supplier
                    string partSku = this.Page.Request.QueryString[Constants.PartSku].ToString();
                    partManagementRepository.AddNewPartSupplier(selectedSupplierId, partSku);
                    LoadPartSuppliers(partSku);

                    //Clear Search Results
                    SupplierResultsGridView.DataSource = null;
                    SupplierResultsGridView.DataBind();
                }
            }
        }
 public void ClearControls()
 {
     SupplierResultsGridView.DataSource = null;
     SupplierResultsGridView.DataBind();
     Update();
 }