diff --git a/src/components/configurator/ExtrasSelector.js b/src/components/configurator/ExtrasSelector.js
index 9492dee..98f6991 100644
--- a/src/components/configurator/ExtrasSelector.js
+++ b/src/components/configurator/ExtrasSelector.js
@@ -67,9 +67,16 @@ class ExtrasSelector extends Component {
sx={{ margin: 0 }}
onClick={(e) => e.stopPropagation()}
/>
-
- {this.formatPrice(extra.price)}
-
+
+
+ {this.formatPrice(extra.price)}
+
+ {extra.vat && (
+
+ (incl. {extra.vat}% MwSt.,*)
+
+ )}
+
diff --git a/src/data/configuratorData.js b/src/data/configuratorData.js
index 3b529fa..8a79f4b 100644
--- a/src/data/configuratorData.js
+++ b/src/data/configuratorData.js
@@ -41,54 +41,3 @@ export const tentShapes = [
visualDepth: 60
}
];
-
-export const extras = [
- {
- id: 'ph_tester',
- name: 'pH-Messgerät',
- description: 'Digitales pH-Meter',
- price: 29.99,
- image: '/assets/images/nopicture.jpg',
- category: 'Messung'
- },
- {
- id: 'nutrients_starter',
- name: 'Dünger Starter-Set',
- description: 'Komplettes Nährstoff-Set',
- price: 39.99,
- image: '/assets/images/nopicture.jpg',
- category: 'Nährstoffe'
- },
- {
- id: 'grow_pots',
- name: 'Grow-Töpfe Set (5x)',
- description: '5x Stofftöpfe 11L',
- price: 24.99,
- image: '/assets/images/nopicture.jpg',
- category: 'Töpfe'
- },
- {
- id: 'timer_socket',
- name: 'Zeitschaltuhr',
- description: 'Digitale Zeitschaltuhr',
- price: 19.99,
- image: '/assets/images/nopicture.jpg',
- category: 'Steuerung'
- },
- {
- id: 'thermometer',
- name: 'Thermo-Hygrometer',
- description: 'Min/Max Temperatur & Luftfeuchtigkeit',
- price: 14.99,
- image: '/assets/images/nopicture.jpg',
- category: 'Messung'
- },
- {
- id: 'pruning_shears',
- name: 'Gartenschere',
- description: 'Präzisions-Gartenschere',
- price: 16.99,
- image: '/assets/images/nopicture.jpg',
- category: 'Werkzeug'
- }
-];
\ No newline at end of file
diff --git a/src/pages/GrowTentKonfigurator.js b/src/pages/GrowTentKonfigurator.js
index 419b919..3362f49 100644
--- a/src/pages/GrowTentKonfigurator.js
+++ b/src/pages/GrowTentKonfigurator.js
@@ -16,7 +16,7 @@ import {
} from '@mui/material';
import ShoppingCartIcon from '@mui/icons-material/ShoppingCart';
import { TentShapeSelector, ExtrasSelector } from '../components/configurator/index.js';
-import { tentShapes, extras } from '../data/configuratorData.js';
+import { tentShapes } from '../data/configuratorData.js';
function setCachedCategoryData(categoryId, data) {
if (!window.productCache) {
@@ -497,6 +497,7 @@ class GrowTentKonfigurator extends Component {
}
}
+ const extras = getCachedCategoryData('Extras');
// Add extras prices
selectedExtras.forEach(extraId => {
const extra = extras.find(e => e.id === extraId);
@@ -570,6 +571,7 @@ class GrowTentKonfigurator extends Component {
}
}
+ const extras = getCachedCategoryData('Extras');
selectedExtras.forEach(extraId => {
const extra = extras.find(e => e.id === extraId);
if (extra) {
@@ -1034,7 +1036,7 @@ class GrowTentKonfigurator extends Component {
renderExtrasSection() {
const { selectedExtras } = this.state;
-
+ const extras = getCachedCategoryData('Extras');
return (
l.id === selectedLightType);
const availableVentilation = this.state.selectedTentShape ? this.getVentilationForTentShape(this.state.selectedTentShape) : [];
const selectedVentilation = availableVentilation.find(v => v.id === selectedVentilationType && v.isDeliverable);
+ const extras = getCachedCategoryData('Extras');
const selectedExtrasItems = extras.filter(e => selectedExtras.includes(e.id));
const savingsInfo = this.calculateSavings();
@@ -1086,11 +1089,15 @@ class GrowTentKonfigurator extends Component {
-
- {this.formatPrice(selectedTent.price)}
+
+ {this.formatPrice(selectedTent.price)}
+ {selectedTent.vat && (
+
+ (incl. {selectedTent.vat}% MwSt.,*)
+
+ )}
@@ -1100,11 +1107,15 @@ class GrowTentKonfigurator extends Component {
-
- {this.formatPrice(selectedLight.price)}
+
+ {this.formatPrice(selectedLight.price)}
+ {selectedLight.vat && (
+
+ (incl. {selectedLight.vat}% MwSt.,*)
+
+ )}
@@ -1114,11 +1125,15 @@ class GrowTentKonfigurator extends Component {
-
- {this.formatPrice(selectedVentilation.price)}
+
+ {this.formatPrice(selectedVentilation.price)}
+ {selectedVentilation.vat && (
+
+ (incl. {selectedVentilation.vat}% MwSt.,*)
+
+ )}
@@ -1128,11 +1143,15 @@ class GrowTentKonfigurator extends Component {
-
- {this.formatPrice(extra.price)}
+
+ {this.formatPrice(extra.price)}
+ {extra.vat && (
+
+ (incl. {extra.vat}% MwSt.,*)
+
+ )}
@@ -1146,6 +1165,9 @@ class GrowTentKonfigurator extends Component {
Sie sparen: {this.formatPrice(savingsInfo.savings)} ({savingsInfo.discountPercentage}% Bundle-Rabatt)
+
+ (incl. 19% MwSt.,*)
+
)}
@@ -1153,9 +1175,14 @@ class GrowTentKonfigurator extends Component {
Gesamtpreis:
-
- {this.formatPrice(totalPrice)}
-
+
+
+ {this.formatPrice(totalPrice)}
+
+
+ (incl. 19% MwSt.,*)
+
+