Exemple #1
0
        protected void AddAddOnsButtonClick(object sender, EventArgs e)
        {
            int addOnId;

            int.TryParse(ProductAvailableAddOnsDdl.SelectedValue, out addOnId);
            if (addOnId != 0)
            {
                var productAddOns = new ProductAddOns
                {
                    AddOnId   = addOnId,
                    ProductId = _productId
                };
                _productRepository.AddAddOns(productAddOns);

                _productRepository.ResetCache();

                RebindAddOns(true);
            }
        }