mirror of
https://github.com/D4M13N-D3V/comissions-app-core-api.git
synced 2025-03-14 10:04:55 +00:00
fix: should pull balance correctly now
This commit is contained in:
parent
3c40d74912
commit
eba1de0cd0
@ -89,8 +89,7 @@ public class ArtistController : Controller
|
||||
{
|
||||
Enabled = account.PayoutsEnabled,
|
||||
Balance = balance,
|
||||
PayoutUrl = _paymentService.CreateDashboardUrl(Artist.StripeAccountId),
|
||||
OnboardUrl = _paymentService.CreateArtistAccountOnboardingUrl(Artist.StripeAccountId)
|
||||
PayoutUrl = _paymentService.CreateDashboardUrl(Artist.StripeAccountId)
|
||||
};
|
||||
return Ok(result);
|
||||
}
|
||||
|
@ -7,5 +7,4 @@ public class PayoutModel
|
||||
public double Balance { get; set; }
|
||||
public bool Enabled { get; set; }
|
||||
public string PayoutUrl { get; set; }
|
||||
public string OnboardUrl { get; set; }
|
||||
}
|
@ -146,7 +146,10 @@ public class StripePaymentServiceProvider:IPaymentService
|
||||
public double GetBalance(string accountId)
|
||||
{
|
||||
var balanceService = new BalanceService();
|
||||
var balance = balanceService.Get();
|
||||
var balance = balanceService.Get(new RequestOptions()
|
||||
{
|
||||
StripeAccount = accountId
|
||||
});
|
||||
return balance.Available[0].Amount/100;
|
||||
}
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user