pricing - Feature toggle removal
MODIFY
src/assets/i18n/en.json
src/assets/i18n/en.json
"generatedUser": "Generated user for '{{email}}'",
"chargingAtSiteArea": "Charging session: {{sessionID}} - Start Date: {{startDate}} at {startTime} - Energy Consumption: {{totalConsumption}} kWh at {{siteAreaName}}",
"chargingAtChargeBox": "Charging session: {{sessionID}} - Start Date: {{startDate}} at {{startTime}} - Energy Consumption: {{totalConsumption}} kWh at charging station {{chargeBoxID}}",
- "flatFee-itemDescription": "Session: {{sessionID}} - Start Date: {{startDate}} at {{startTime}} at charging station {{chargeBoxID}} - Flat Fee",
- "energy-itemDescription": "Session: {{sessionID}} - Start Date: {{startDate}} at {{startTime}} at charging station {{chargeBoxID}} - Energy Consumption: {{quantity}} kWh",
- "chargingTime-itemDescription": "Session: {{sessionID}} - Start Date: {{startDate}} at {{startTime}} at charging station {{chargeBoxID}} - Charging Time: {{duration}}",
- "parkingTime-itemDescription": "Session: {{sessionID}} - Start Date: {{startDate}} at {{startTime}} at charging station {{chargeBoxID}} - Parking Time: {{duration}}",
"header-itemDescription": "Session: {{sessionID}} - Start Date: {{startDate}} at {{startTime}} at charging station {{chargeBoxID}}",
"flatFee-shortItemDescription": "Flat Fee",
"energy-shortItemDescription": "Energy Consumption: {{quantity}} kWh",

MODIFY
src/assets/i18n/it.json
src/assets/i18n/it.json
"generatedUser": "Utenza generata per '{{email}}'",
"chargingAtSiteArea": "Charging session: {{sessionID}} - Start Date: {{startDate}} at {startTime} - Energy Consumption: {{totalConsumption}} kWh at {{siteAreaName}}",
"chargingAtChargeBox": "Charging session: {{sessionID}} - Start Date: {{startDate}} at {{startTime}} - Energy Consumption: {{totalConsumption}} kWh at charging station {{chargeBoxID}}",
- "flatFee-itemDescription": "Session: {{sessionID}} - Start Date: {{startDate}} at {{startTime}} at charging station {{chargeBoxID}} - Flat Fee",
- "energy-itemDescription": "Session: {{sessionID}} - Start Date: {{startDate}} at {{startTime}} at charging station {{chargeBoxID}} - Energy Consumption: {{quantity}} kWh",
- "chargingTime-itemDescription": "Session: {{sessionID}} - Start Date: {{startDate}} at {{startTime}} at charging station {{chargeBoxID}} - Charging Time: {{duration}}",
- "parkingTime-itemDescription": "Session: {{sessionID}} - Start Date: {{startDate}} at {{startTime}} at charging station {{chargeBoxID}} - Parking Time: {{duration}}",
"header-itemDescription": "Session: {{sessionID}} - Start Date: {{startDate}} at {{startTime}} at charging station {{chargeBoxID}}",
"flatFee-shortItemDescription": "Flat Fee",
"energy-shortItemDescription": "Energy Consumption: {{quantity}} kWh",

MODIFY
src/assets/i18n/pt.json
src/assets/i18n/pt.json
"generatedUser": "Utilizador criado para '{{email}}'",
"chargingAtSiteArea": "Charging session: {{sessionID}} - Start Date: {{startDate}} at {startTime} - Energy Consumption: {{totalConsumption}} kWh at {{siteAreaName}}",
"chargingAtChargeBox": "Charging session: {{sessionID}} - Start Date: {{startDate}} at {{startTime}} - Energy Consumption: {{totalConsumption}} kWh at charging station {{chargeBoxID}}",
- "flatFee-itemDescription": "Session: {{sessionID}} - Start Date: {{startDate}} at {{startTime}} at charging station {{chargeBoxID}} - Flat Fee",
- "energy-itemDescription": "Session: {{sessionID}} - Start Date: {{startDate}} at {{startTime}} at charging station {{chargeBoxID}} - Energy Consumption: {{quantity}} kWh",
- "chargingTime-itemDescription": "Session: {{sessionID}} - Start Date: {{startDate}} at {{startTime}} at charging station {{chargeBoxID}} - Charging Time: {{duration}}",
- "parkingTime-itemDescription": "Session: {{sessionID}} - Start Date: {{startDate}} at {{startTime}} at charging station {{chargeBoxID}} - Parking Time: {{duration}}",
"header-itemDescription": "Session: {{sessionID}} - Start Date: {{startDate}} at {{startTime}} at charging station {{chargeBoxID}}",
"flatFee-shortItemDescription": "Flat Fee",
"energy-shortItemDescription": "Energy Consumption: {{quantity}} kWh",

MODIFY
src/integration/billing/stripe/StripeBillingIntegration.ts
src/integration/billing/stripe/StripeBillingIntegration.ts
@@ -1051,10 +1051,7 @@ export default class StripeBillingIntegration extends BillingIntegration {
begin: transaction.timestamp?.valueOf(),
}
};
- if (FeatureToggles.isFeatureActive(Feature.BILLING_SHOW_SESSION_HEADER)) {
- // To be clarified - do we put general information on top
billingInvoiceItem.headerDescription = this.buildLineItemDescription(transaction, true);
- }
// Returns a item representing the complete charging session (energy + parking information)
return billingInvoiceItem ;
}
@@ -1244,10 +1241,7 @@ export default class StripeBillingIntegration extends BillingIntegration {
duration = '';
}
// Get the translated line item description
- let descriptionPattern = `billing.${dimensionType}-shortItemDescription`;
- if (!FeatureToggles.isFeatureActive(Feature.BILLING_SHOW_SESSION_HEADER)) {
- descriptionPattern = `billing.${dimensionType}-itemDescription`;
- }
+ const descriptionPattern = `billing.${dimensionType}-shortItemDescription`;
const description = i18nManager.translate(descriptionPattern, {
sessionID,
startDate,

MODIFY
src/utils/FeatureToggles.ts
src/utils/FeatureToggles.ts
@@ -7,7 +7,6 @@ export enum Feature {
PRICING_NEW_MODEL,
PRICING_CHECK_BACKWARD_COMPATIBILITY,
BILLING_SHOW_PRICING_DETAIL,
- BILLING_SHOW_SESSION_HEADER,
}
export default class FeatureToggles {
@@ -19,7 +18,6 @@ export default class FeatureToggles {
Feature.PRICING_NEW_MODEL,
// Feature.PRICING_CHECK_BACKWARD_COMPATIBILITY,
// Feature.BILLING_SHOW_PRICING_DETAIL,
- Feature.BILLING_SHOW_SESSION_HEADER,
];
// Check whether the feature is active or not!

pricing - Feature toggle removal