Browse Source

removed unused comments and usings

pull/57/head
Galip Tolga Erdem 5 years ago
parent
commit
c15f28ed9b
  1. 7
      services/payment/src/EShopOnAbp.PaymentService.Application.Contracts/PaymentRequests/IPaymentRequestAppService.cs
  2. 2
      services/payment/src/EShopOnAbp.PaymentService.Application/PaymentRequests/PaymentRequestAppService.cs
  3. 1
      services/payment/src/EShopOnAbp.PaymentService.Application/PaymentServiceApplicationModule.cs
  4. 8
      services/payment/src/EShopOnAbp.PaymentService.Application/PaymentServices/PaymentServiceFactory.cs

7
services/payment/src/EShopOnAbp.PaymentService.Application.Contracts/PaymentRequests/IPaymentRequestAppService.cs

@ -12,12 +12,5 @@ namespace EShopOnAbp.PaymentService.PaymentRequests
Task<PaymentRequestDto> CompleteAsync(PaymentRequestCompleteInputDto input);
Task<bool> HandleWebhookAsync(string payload);
// /// <summary>
// /// 0 - Demo
// /// 1 - Paypal
// /// </summary>
// /// <param name="paymentTypeId"></param>
// /// <returns></returns>
// Task SetPaymentServiceAsync(int paymentTypeId);
}
}

2
services/payment/src/EShopOnAbp.PaymentService.Application/PaymentRequests/PaymentRequestAppService.cs

@ -5,7 +5,6 @@ using System;
using System.Linq;
using System.Threading.Tasks;
using EShopOnAbp.PaymentService.PaymentServices;
using Microsoft.Extensions.Logging;
namespace EShopOnAbp.PaymentService.PaymentRequests
{
@ -16,7 +15,6 @@ namespace EShopOnAbp.PaymentService.PaymentRequests
protected IPaymentRequestRepository PaymentRequestRepository { get; }
protected PayPalHttpClient PayPalHttpClient { get; }
public PaymentRequestAppService(
IPaymentRequestRepository paymentRequestRepository,
PayPalHttpClient payPalHttpClient,

1
services/payment/src/EShopOnAbp.PaymentService.Application/PaymentServiceApplicationModule.cs

@ -7,6 +7,7 @@ using EShopOnAbp.PaymentService.PayPal;
using PayPalCheckoutSdk.Core;
using System;
using EShopOnAbp.PaymentService.PaymentRequests;
using EShopOnAbp.PaymentService.PaymentServices;
namespace EShopOnAbp.PaymentService
{

8
services/payment/src/EShopOnAbp.PaymentService.Application/PaymentServices/PaymentServiceFactory.cs

@ -1,7 +1,6 @@
using System;
using EShopOnAbp.PaymentService.PaymentRequests;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Logging;
using PayPalCheckoutSdk.Core;
using Volo.Abp.DependencyInjection;
@ -10,13 +9,10 @@ namespace EShopOnAbp.PaymentService.PaymentServices;
public class PaymentServiceFactory : ITransientDependency
{
private readonly IServiceProvider _serviceProvider;
private readonly ILogger<PaymentServiceFactory> _logger;
public PaymentServiceFactory(IServiceProvider serviceProvider, ILogger<PaymentServiceFactory> logger)
public PaymentServiceFactory(IServiceProvider serviceProvider)
{
logger.LogInformation("== Payment SErvice Factory == ");
_serviceProvider = serviceProvider;
_logger = logger;
}
public IPaymentStrategy Create(int paymentTypeId)
@ -29,9 +25,7 @@ public class PaymentServiceFactory : ITransientDependency
if (paymentTypeId == 1)
{
var paypalService = _serviceProvider.GetRequiredService<PayPalHttpClient>();
_logger.LogInformation($"=== Resolved PaypalService {paypalService} ===");
var requestDomainService = _serviceProvider.GetRequiredService<PaymentRequestDomainService>();
_logger.LogInformation($"=== Resolved PaymentRequestDomainService {requestDomainService} ===");
return new PaypalService(paypalService, requestDomainService);
}

Loading…
Cancel
Save