public StoreSupplierResponse StoreSupplier(StoreSupplierRequeset request) { var response = new StoreSupplierResponse(); var bc = DependencyInjectionHelper.GetBusinessComponent <SupplierBusinessComponent>(); var supplier = SupplierAdapter.DtoToSupplier(request.Supplier); response.Id = bc.StoreSupplier(supplier); return(response); }
public void StoreSupplier(SupplierDTO supplier) { try { var request = new StoreSupplierRequeset(); request.Supplier = supplier; var response = this.Service.StoreSupplier(request); supplier.Id = response.Id; } catch (Exception ex) { if (ExceptionPolicy.HandleException(ex, "PL Policy")) { throw; } } }