i use IHttpContextAccessor
for redirect to payment page but this is not work and don't redirect to payment page
i try redirect to google.com but can't do it
public async Task<ProcessPaymentResult> ProcessPayment(ProcessPaymentRequest processPaymentRequest)
{
var result = new ProcessPaymentResult();
result.NewPaymentStatus = PaymentStatus.Pending;
return await Task.FromResult(result);
}
public async Task PostProcessPayment(PostProcessPaymentRequest postProcessPaymentRequest)
{
var total = Convert.ToInt32(Math.Round(postProcessPaymentRequest.Order.OrderTotal, 2));
string urlToRedirect = "http://www.google.com";
_httpContextAccessor.HttpContext.Response.Redirect(urlToRedirect);
return;
}
plz help me thx