# Variablen in eigener Status Email

**URL:** <https://forum.shopware.com/t/variablen-in-eigener-status-email/92642>\
**Category:** Shopware 5\
**Created:** [28. Januar 2022 um 05:03 UTC](https://forum.shopware.com/t/variablen-in-eigener-status-email/92642 "2022-01-28T05:03:16Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Pyro](https://avatars.discourse-cdn.com/v4/letter/p/71e660/32.png) [@Pyro](https://forum.shopware.com/u/Pyro)\
**Post date:** [28. Januar 2022 um 05:03 UTC](https://forum.shopware.com/t/variablen-in-eigener-status-email/92642/1 "2022-01-28T05:03:16Z")

</div>

Hallo,

im der „System“ Bestellbestätigung kann ich ja recht komfortabel auf die Artikel Eigenschaften der aktuellen Bestellung zugreifen. Z.b.:

$sOrderDetails.$position.additional\_details.attributes.core.attr6

Aber wenn ich einen eigenen Status erstelle und dort versuche in der Statusemail auf die Daten zuzugreifen, komme ich nicht weiter. Die werden mir auch nicht in den Beispielvariablen angeboten.  
Hat jemand einen Tipp für mich?

Gruß Dirk

---

<div class="post-metadata">

**Author:** ![phil](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.shopware.com/phil/32/13661_2.png) [@phil](https://forum.shopware.com/u/phil)\
**Post date:** [28. Januar 2022 um 06:32 UTC](https://forum.shopware.com/t/variablen-in-eigener-status-email/92642/2 "2022-01-28T06:32:30Z")

</div>

Also wenn Du so vorgehst, wie in [Shopware 5 - Tutorials & FAQs - Neuen Bestell- & Zahlstatus erstellen](https://docs.shopware.com/de/shopware-5-de/tutorials-und-faq/neuen-bestell-und-zahlstatus-erstellen) beschrieben, dann hast Du in der zugehörigen Email auch alle Variablen zur Verfügung: $sUser, $sOrder, $sOrderDetails und $sDispatch.

LG Phil

---

<div class="post-metadata">

**Author:** ![Pyro](https://avatars.discourse-cdn.com/v4/letter/p/71e660/32.png) [@Pyro](https://forum.shopware.com/u/Pyro)\
**Post date:** [28. Januar 2022 um 06:54 UTC](https://forum.shopware.com/t/variablen-in-eigener-status-email/92642/3 "2022-01-28T06:54:04Z")

</div>

Ja, das geht alles. Ich komme aber eben nicht auf die Artikeldetails, welche in der Shopware eigenen Bestellbestätigung verfügbar sind. In den Fall ein FReitextfeld. Attr6 z.B.

---

<div class="post-metadata">

**Author:** ![phil](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.shopware.com/phil/32/13661_2.png) [@phil](https://forum.shopware.com/u/phil)\
**Post date:** [28. Januar 2022 um 22:39 UTC](https://forum.shopware.com/t/variablen-in-eigener-status-email/92642/4 "2022-01-28T22:39:22Z")

</div>

Hmm. Bist Du sicher dass das bei Status-Emails jemals funktioniert hat? Ich hab mal testweise sowohl in einer Standard-Status Email als auch in einer Custom-Status Email ein `{$sOrderDetails|print_r}` eingefügt, und die Ausgabe ist in beiden Fällen identisch:

```auto
Array
(
    [0] => Array
        (
            [orderdetailsID] => 208
            [orderID] => 59
            [ordernumber] => 20003
            [articleID] => 152
            [articleordernumber] => SW10152.1
            [price] => 29.95
            [quantity] => 1
            [invoice] => 29.95
            [name] => WINDSTOPPER MÜTZE WARM Schwarz
            [status] => 0
            [shipped] => 0
            [shippedgroup] => 0
            [releasedate] => 0000-00-00
            [modus] => 0
            [esdarticle] => 0
            [taxID] => 1
            [tax] => 19.00
            [tax_rate] => 19
            [esd] => 0
            [attributes] => Array
                (
                    [attribute1] => 
                    [attribute2] => 
                    [attribute3] => 
                    [attribute4] => 
                    [attribute5] => 
                    [attribute6] => 
                )

        )

    [1] => Array
        (
            [orderdetailsID] => 209
            [orderID] => 59
            [ordernumber] => 20003
            [articleID] => 0
            [articleordernumber] => SHIPPINGDISCOUNT
            [price] => -2
            [quantity] => 1
            [invoice] => -2
            [name] => Warenkorbrabatt
            [status] => 0
            [shipped] => 0
            [shippedgroup] => 0
            [releasedate] => 0000-00-00
            [modus] => 4
            [esdarticle] => 0
            [taxID] => 0
            [tax] => 
            [tax_rate] => 19
            [esd] => 0
            [attributes] => Array
                (
                    [attribute1] => 
                    [attribute2] => 
                    [attribute3] => 
                    [attribute4] => 
                    [attribute5] => 
                    [attribute6] => 
                )

        )

)
1

```

In der Bestellbestätigung (Vorlage sORDER) gibt es erheblich mehr Variablen und Properties - mach dort mal testweise den print\_r rein und lass dir die Vorschau anzeigen.

Warum das so ist, kann vermutlich nur Shopware beantworten…

LG Phil

---

<div class="post-metadata">

**Author:** ![Pyro](https://avatars.discourse-cdn.com/v4/letter/p/71e660/32.png) [@Pyro](https://forum.shopware.com/u/Pyro)\
**Post date:** [29. Januar 2022 um 06:50 UTC](https://forum.shopware.com/t/variablen-in-eigener-status-email/92642/5 "2022-01-29T06:50:05Z")

</div>

Hallo Phil,

nein, ob das schon mal funktioniert hat kann ich leider nicht sagen.  
Danke Dir aber dennoch für den Hinweis mit Print\_r.
