bp - transfers - tax - rework
MODIFY
src/integration/billing/BillingIntegration.ts
src/integration/billing/BillingIntegration.ts
@@ -828,7 +828,6 @@ export default abstract class BillingIntegration {
return {
percentage,
flatFeePerSession,
- taxExternalID: null, // TODO - consider tax rates
feeAmount
};
}

MODIFY
src/integration/billing/stripe/StripeBillingIntegration.ts
src/integration/billing/stripe/StripeBillingIntegration.ts
@@ -1806,7 +1806,7 @@ export default class StripeBillingIntegration extends BillingIntegration {
// Build the description with the business owner locale
const description = this.buildTransferLineItemDescription(user, session);
// A single tax rate per session
- const tax_rates = (session.accountSessionFee.taxExternalID) ? [ session.accountSessionFee.taxExternalID ] : [];
+ const tax_rates = [];
// Prepare item parameters
const parameters: Stripe.InvoiceItemCreateParams = {
invoice: stripeInvoice.id,

MODIFY
src/types/Billing.ts
src/types/Billing.ts
@@ -193,7 +193,6 @@ export interface BillingPlatformFeeData {
}
export interface BillingAccountSessionFee extends BillingPlatformFeeStrategy {
- taxExternalID: string; // Tax to apply on the platform fee
feeAmount: number;
}

MODIFY
test/factories/BillingFactory.ts
test/factories/BillingFactory.ts
@@ -23,7 +23,6 @@ export const BillingTransferSessionFactory = Factory.define<BillingTransferSessi
.attr('accountSessionFee', () => ({
flatFeePerSession: 0.5,
percentage: 3,
- taxExternalID: null,
feeAmount: 0
}));
@@ -34,5 +33,4 @@ export const BillingPlatformFeeStrategyFactory = Factory.define<BillingPlatformF
export const BillingPlatformSessionFeeFactory = Factory.define<BillingAccountSessionFee>('billingaccountSessionFee')
.attr('flatFeePerSession', 0.5)
.attr('percentage', 3)
- .attr('taxExternalID', null)
.attr('feeAmount', 0);

bp - transfers - tax - rework