mirror of
https://github.com/bitwarden/server.git
synced 2025-02-25 03:21:46 +01:00
support for stripe sources in billing info
This commit is contained in:
parent
25ea96f1bd
commit
aef68d4934
@ -36,6 +36,16 @@ namespace Bit.Core.Models.Business
|
|||||||
card.ExpYear);
|
card.ExpYear);
|
||||||
CardBrand = card.Brand;
|
CardBrand = card.Brand;
|
||||||
}
|
}
|
||||||
|
else if(source is Source src && src.Card != null)
|
||||||
|
{
|
||||||
|
Type = PaymentMethodType.Card;
|
||||||
|
Description = $"{src.Card.Brand}, *{src.Card.Last4}, " +
|
||||||
|
string.Format("{0}/{1}",
|
||||||
|
string.Concat(src.Card.ExpMonth < 10 ?
|
||||||
|
"0" : string.Empty, src.Card.ExpMonth),
|
||||||
|
src.Card.ExpYear);
|
||||||
|
CardBrand = src.Card.Brand;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public BillingSource(Braintree.PaymentMethod method)
|
public BillingSource(Braintree.PaymentMethod method)
|
||||||
|
Loading…
Reference in New Issue
Block a user