# Mehrfachvererbung in Administration

**URL:** <https://forum.shopware.com/t/mehrfachvererbung-in-administration/71501>\
**Category:** Programmierung\
**Created:** [11. Dezember 2020 um 08:30 UTC](https://forum.shopware.com/t/mehrfachvererbung-in-administration/71501 "2020-12-11T08:30:16Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![mkar](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.shopware.com/mkar/32/14807_2.png) [@mkar](https://forum.shopware.com/u/mkar)\
**Post date:** [11. Dezember 2020 um 08:30 UTC](https://forum.shopware.com/t/mehrfachvererbung-in-administration/71501/1 "2020-12-11T08:30:16Z")

</div>

Hallo alle Zusammen,

in einem Plugin haben wir eine neue Komponente erstellt, indem wir die sw-product-detail mit Component.extend() erweitert haben. Das Plugin funktioniert alleine, ohne Drittplugins, auch wunderbar. Es treten keine Fehler auf und es tut das, was es tuen soll.

Ist nun aber ein Drittplugin installiert, welches die sw-product-detail überschreibt, tritt beim Aufruf der Komponente folgender Fehler auf:

```
TypeError: Cannot read property 'sw-product-detail' of undefined
    at s.$super (commons.js?1607528751227242:1)
    at s.productCriteria (pickware-erp-starter.js?1607509902470893:4775)
    at pn.get (vendors-node.js?16075287511442902:2)
    at pn.evaluate (vendors-node.js?16075287511442902:2)
    at s.productCriteria (vendors-node.js?16075287511442902:2)
    at s.loadProduct (app.js?16075287514887651:1)
    at s.loadAll (app.js?16075287514887651:1)
    at s.$super (commons.js?1607528751227242:1)
    at s.loadAll (my-test-component.js?160752875246042:1)
    at s.loadState (app.js?16075287514887651:1)

```

&nbsp;

Die erstellte Komponente sieht folgendermaßen aus:  
&nbsp;

```
...

Component.extend('my-test-component-detail', 'sw-product-detail', {
    template,

    ...

    methods: {

        loadAll() {
            return this.$super('loadAll').then(this.loadMyData());
        },

        ...
    }

    ...

});

```

&nbsp;

Hatte jemand schon ein ähnliches Problem mit Mehrfachvererbungen?

Ist in Shopware 6 noch ein Problem bzgl. der Mehrfachvererbung? Denn wenn ich z.B. einen $super-Call aufrufe und die parent Funktion auch einen $super-Call hat, entsteht eine Endlosschleife.

&nbsp;

Danke für die Tipps

---

<div class="post-metadata">

**Author:** ![shyim](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.shopware.com/shyim/32/7681_2.png) [@shyim](https://forum.shopware.com/u/shyim)\
**Post date:** [11. Dezember 2020 um 14:02 UTC](https://forum.shopware.com/t/mehrfachvererbung-in-administration/71501/2 "2020-12-11T14:02:29Z")

</div>

Welche Shopware Version hast du?

---

<div class="post-metadata">

**Author:** ![mkar](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.shopware.com/mkar/32/14807_2.png) [@mkar](https://forum.shopware.com/u/mkar)\
**Post date:** [11. Dezember 2020 um 14:06 UTC](https://forum.shopware.com/t/mehrfachvererbung-in-administration/71501/3 "2020-12-11T14:06:24Z")

</div>

Die Shopware Version ist 6.3.3.1
