Пример #1
0
        public DeleteProductResponse DeleteProduct(DeleteProductRequest request)
        {
            DeleteProductResponse response = new DeleteProductResponse();
            ProductBusinessComponent bc = DependencyInjectionHelper.GetProductBusinessComponent();

            bc.DeleteProduct(request.Id);

            return response;
        }
Пример #2
0
 public void DeleteProduct(int productId)
 {
     try
     {
         DeleteProductRequest request = new DeleteProductRequest();
         request.Id = productId;
         DeleteProductResponse response = Service.DeleteProduct(request);
     }
     catch (Exception ex)
     {
         if (ExceptionPolicy.HandleException(ex, "PL Policy")) throw;
     }
 }