# hook in Methode get der Klasse ListingPriceTable

**URL:** <https://forum.shopware.com/t/hook-in-methode-get-der-klasse-listingpricetable/53054>\
**Category:** Programmierung\
**Created:** [23. Mai 2018 um 13:53 UTC](https://forum.shopware.com/t/hook-in-methode-get-der-klasse-listingpricetable/53054 "2018-05-23T13:53:21Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![CarstenHarnisch](https://avatars.discourse-cdn.com/v4/letter/c/f0a364/32.png) [@CarstenHarnisch](https://forum.shopware.com/u/CarstenHarnisch)\
**Post date:** [23. Mai 2018 um 13:53 UTC](https://forum.shopware.com/t/hook-in-methode-get-der-klasse-listingpricetable/53054/1 "2018-05-23T13:53:21Z")

</div>

Ich würde gerne in die get Methode hooken wollen in der Klasse&nbsp;Shopware\Bundle\SearchBundleDBA\ListingPriceTable

```
$this->subscribeEvent ( 'Shopware\Bundle\SearchBundleDBA\ListingPriceTable::get::after', 'onListingPriceTableGet' );

```

funktioniert nur leider nicht ! Verstehe nicht wirklich warum das nicht zieht …

gruss

Carsten

---

<div class="post-metadata">

**Author:** ![Michael\_Telgmann](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.shopware.com/michael_telgmann/32/20289_2.png) [@Michael\_Telgmann](https://forum.shopware.com/u/Michael_Telgmann)\
**Post date:** [23. Mai 2018 um 14:20 UTC](https://forum.shopware.com/t/hook-in-methode-get-der-klasse-listingpricetable/53054/2 "2018-05-23T14:20:16Z")

</div>

Hallo Carsten,

Die Klassen unter “Shopware\Bundle” lassen sich nicht hooken. Zum Erweitern der Services musst du hier das Decorator Pattern anwenden:&nbsp;[Service extensions](https://developers.shopware.com/developers-guide/shopware-5-core-service-extensions/)

Viele Grüße aus Schöppingen

![cool](https://europe1.discourse-cdn.com/flex013/uploads/shopware/original/1X/86c57fbace799dd4eb1f1b8a2d3bdc1733f0aea1.png "cool")&nbsp;Michael Telgmann

---

<div class="post-metadata">

**Author:** ![CarstenHarnisch](https://avatars.discourse-cdn.com/v4/letter/c/f0a364/32.png) [@CarstenHarnisch](https://forum.shopware.com/u/CarstenHarnisch)\
**Post date:** [24. Mai 2018 um 02:37 UTC](https://forum.shopware.com/t/hook-in-methode-get-der-klasse-listingpricetable/53054/3 "2018-05-24T02:37:48Z")

</div>

ok, besten Dank. Das erklärt dann natürlich das „Problem“.

herzlichst

Carsten Harnisch

---

<div class="post-metadata">

**Author:** ![CarstenHarnisch](https://avatars.discourse-cdn.com/v4/letter/c/f0a364/32.png) [@CarstenHarnisch](https://forum.shopware.com/u/CarstenHarnisch)\
**Post date:** [24. Mai 2018 um 04:13 UTC](https://forum.shopware.com/t/hook-in-methode-get-der-klasse-listingpricetable/53054/4 "2018-05-24T04:13:20Z")

</div>

es gibt da leider ein weiteres Problem da die Klasse „ListingPriceSwitcher“ einen Bug hat. Ich habe dazu einen Issue geöffnet (SW-21817)
