# FlowBuilder: Action ohne Dialog?

**URL:** <https://forum.shopware.com/t/flowbuilder-action-ohne-dialog/95828>\
**Category:** Programmierung\
**Created:** [17. August 2022 um 11:47 UTC](https://forum.shopware.com/t/flowbuilder-action-ohne-dialog/95828 "2022-08-17T11:47:28Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![gaxweb](https://avatars.discourse-cdn.com/v4/letter/g/ea5d25/32.png) [@gaxweb](https://forum.shopware.com/u/gaxweb)\
**Post date:** [17. August 2022 um 11:47 UTC](https://forum.shopware.com/t/flowbuilder-action-ohne-dialog/95828/1 "2022-08-17T11:47:28Z")

</div>

Im [Tutorial](https://developer.shopware.com/docs/guides/plugins/plugins/framework/flow/add-flow-builder-action), das sehr zu wünschen übrig lässt, wird beschrieben wie man eine Action mit Dialog-Popup erstellt. Ich benötige aber keine Einstellungen.

Wie kann ich eine FlowAction ohne Dialog erstellen? Wenn ich den Teil mit dem Dialog aus dem Tutorial weg lasse, dann übernimmt es die ausgewählte Action nicht. Fehler gibt es auch keine aus, daher stehe ich gerade auf dem Schlauch.

---

<div class="post-metadata">

**Author:** ![gaxweb](https://avatars.discourse-cdn.com/v4/letter/g/ea5d25/32.png) [@gaxweb](https://forum.shopware.com/u/gaxweb)\
**Post date:** [5. Dezember 2023 um 16:02 UTC](https://forum.shopware.com/t/flowbuilder-action-ohne-dialog/95828/2 "2023-12-05T16:02:41Z")

</div>

Mittlerweile steht dazu ja was in der Doku: [Add custom flow Action | Shopware Documentation](https://developer.shopware.com/docs/guides/plugins/plugins/framework/flow/add-flow-builder-action.html#custom-configuration-for-action-without-the-modal)

…aber es passiert halt nix, wenn ich das so in der `index.js` eintrage. Hat da jemand Erfahrung mit? Stimmt überhaupt was da steht? Offenbar nicht alles: [Flow Builder Action Erweiterung zeigt kein Label - #2 von RobertK](https://forum.shopware.com/t/flow-builder-action-erweiterung-zeigt-kein-label/100727/2)

Es hatte auch schon mal funktioniert, aber Shopware ist ja ständig noch dabei am FlowBuilder rumzufummeln…

Stimmt jetzt z.B. `Component.register` oder `Component.override`? Mal steht das eine, mal das andere drin. Ich kann mir nicht vorstellen, dass `register` stimmt, denn `sw-flow-sequence-action` gibt es in SW ja bereits, oder nicht?

Ich verwende übrigens v6.5.7.3.

---

<div class="post-metadata">

**Author:** ![gaxweb](https://avatars.discourse-cdn.com/v4/letter/g/ea5d25/32.png) [@gaxweb](https://forum.shopware.com/u/gaxweb)\
**Post date:** [6. Dezember 2023 um 12:42 UTC](https://forum.shopware.com/t/flowbuilder-action-ohne-dialog/95828/3 "2023-12-06T12:42:44Z")

</div>

Ok, bin einen Schritt weiter. Wenn ich `Shopware.Component.override()` verwende (und den Cache leere…), dann funktioniert meine Aktion - aber die von SW nicht mehr.

Wenn ich `Shopware.Component.require()` verwende, ist es umgekehrt, weil er ein Custom Element vermisst, das den Namen meiner Action enthält. Aber ich will/brauche ja gar kein Modal Dialog, also auch kein Template.

Und nun?

---

<div class="post-metadata">

**Author:** ![gaxweb](https://avatars.discourse-cdn.com/v4/letter/g/ea5d25/32.png) [@gaxweb](https://forum.shopware.com/u/gaxweb)\
**Post date:** [6. Dezember 2023 um 13:33 UTC](https://forum.shopware.com/t/flowbuilder-action-ohne-dialog/95828/4 "2023-12-06T13:33:59Z")

</div>

Ich hab es jetzt so gelöst:

```auto
// <plugin root>/src/Resources/app/administration/src/extension/sw-flow-sequence-action/index.js
const { Component } = Shopware;

// hier hab ich OVERRIDE statt REGISTER verwendet
Component.override('sw-flow-sequence-action', {
    methods: {
        openDynamicModal(value) {
            if (!value) {
                return;
            }

            const actionName = this.flowBuilderService.getActionName('ADD_TAG')

            if (value === actionName) {
                this.selectedAction = actionName;
                this.onSaveActionSuccess({ config:{} });
                return;
            }  
            // hier hab ich das ELSE eingefügt, um an die Originalmethode durch zu reichen, denn sonst passiert nix mehr
             else {
                return this.$super('openDynamicModal', value);
            }
        },
    },
});

```

So ganz glücklich bin ich damit nicht, aber wenigstens funktioniert es im Gegensatz zum Code in der Doku.
