Skip to main navigation Skip to main content Skip to page footer

Warenkorb Bestellung auf Rechnung

Eine Bestellung wurde erfolgreich aufgegeben und es wurde eine Bestell- sowie Rechnungsnummer vergeben. Bei der Zahlart Rechnung (onInvoice) kann die Ware vor oder nach dem Zahlungseingang versendet werden.

Die Bestellung gilt ab dem Abschluss des Checkouts als verbindlich. Die Zahlung erfolgt nachgelagert durch den Kunden und wird manuell im System verbucht. Der Bestellprozess wird erst dann abgeschlossen, wenn die Zahlung erfasst und – sofern es sich um physische Ware handelt – der Versand durchgeführt wurde.

stateDiagram-v2

    %% Frontend
    [*] --> prepared : Kunde stellt Warenkorb zusammen\nund startet Checkout

    prepared --> ordered : Checkout abgeschlossen\nBestätigungsmail\nRechnungsnummer

    %% Rechnungskauf: Versand vor oder nach Zahlung möglich
    ordered --> shipped : Versand vor Zahlung\n(optional)
    ordered --> paid : Zahlung verbucht

    %% Reihenfolge flexibel
    shipped --> paid : Zahlung nach Versand
    paid --> shipped : Versand nach Zahlung

    %% Abschluss
    paid --> processed : Abschluss ohne Versand\n(z. B. digitale Leistung)
    shipped --> processed : Abschluss nach Versand

    %% Nichtzahlung
    ordered --> canceled_unpaid : Keine Zahlung\nStorno

    canceled_unpaid --> processed : Storno abgeschlossen

    %% Conditions
    note right of processed
        Conditions:
        - paid_date MUSS gesetzt sein
        - shipped_date MUSS gesetzt sein,
        falls Versand erfolgt ist
    end note

Weitere Aktionen:

  • Retoure: Möglich sobald die Ware versandt wurde – d. h. im Zustand shipped oder processed.
  • Löechen: Das Löschen einer Bestellung ist nur im Status prepared möglich.

TypoScript Konfiguration

plugin.tx_shop.settings.basketOrder {
    orderOptions {
        onInvoice {
            active = {$themes.configuration.extension.shop.checkout.onInvoice.active}
            attachProductFilesToAdminEmail = {$themes.configuration.extension.shop.checkout.onInvoice.attachProductFilesToAdminEmail}
            attachProductFilesToCustomerEmail = {$themes.configuration.extension.shop.checkout.onInvoice.attachProductFilesToCustomerEmail}
            attachInvoiceToAdminEmail = {$themes.configuration.extension.shop.checkout.onInvoice.attachInvoiceToAdminEmail}
            attachInvoiceToCustomerEmail = {$themes.configuration.extension.shop.checkout.onInvoice.attachInvoiceToCustomerEmail}
            attachDeliveryNoteToAdminEmail = {$themes.configuration.extension.shop.checkout.onInvoice.attachDeliveryNoteToAdminEmail}
            attachDeliveryNoteToCustomerEmail = {$themes.configuration.extension.shop.checkout.onInvoice.attachDeliveryNoteToCustomerEmail}
            attachOrderXmlToAdminEmail = {$themes.configuration.extension.shop.checkout.onInvoice.attachOrderXmlToAdminEmail}
            storeOrderXmlInFolder = {$themes.configuration.extension.shop.checkout.onInvoice.storeOrderXmlInFolder}
            storeOrderXmlInFolderName = {$themes.configuration.extension.shop.checkout.onInvoice.storeOrderXmlInFolderName}
            type = onInvoice
            checkoutPid = {$themes.configuration.pages.shop.checkout}
            successPid = {$themes.configuration.pages.shop.checkoutSuccess}
            errorPid = {$themes.configuration.pages.shop.checkoutError}
            service = CodingMs\Shop\Service\Checkout\OnInvoiceCheckoutService
            button {
                title = tx_shop_label.order_on_invoice_button_title
                label = tx_shop_label.order_on_invoice_button_label
                icon = fa fa-shopping-cart
            }
            fields {
                available = {$themes.configuration.extension.shop.checkout.onInvoice.fields.available}
                required = {$themes.configuration.extension.shop.checkout.onInvoice.fields.required}
            }
            status {
                prepared {
                    # Allowed to switch to this status
                    allowed {
                        ordered =
                    }
                }
                ordered {
                    allowed {
                        paid =
                        shipped {
                            # Show marked-as-shipped when not "only digital products" are in basket-order
                            condition {
                                basket = NotContainsDigitalProductsOnly
                            }
                        }
                        canceled_unpaid =
                    }
                }
                shipped {
                    # Hide whole shipped state when "only digital products" are in basket-order
                    hidden {
                        condition {
                            basket = ContainsDigitalProductsOnly
                        }
                    }
                    # Allowed to switch to this status
                    allowed {
                        paid {
                            # But it condition
                            condition {
                                # To have ordered_date not empty – it must be set!
                                ordered_date = NotEmpty
                                ordered_date = NotEmpty
                            }
                        }
                        processed {
                            # But it condition
                            condition {
                                # To have paid_date not empty – it must be set!
                                paid_date = NotEmpty
                            }
                        }
                        returned {
                            # Show marked-as-returned when not "only digital products" are in basket-order
                            condition {
                                basket = NotContainsDigitalProductsOnly
                            }
                        }
                    }
                }
                paid {
                    allowed {
                        shipped {
                            condition {
                                ordered_date = NotEmpty
                                shipped_date = Empty
                            }
                        }
                        processed {
                            condition {
                                shipped_date = NotEmpty
                            }
                        }
                    }
                }
                canceled_unpaid {
                    allowed {
                        processed =
                    }
                }
                processed {
                    allowed {
                        returned {
                            # Show marked-as-returned when not "only digital products" are in basket-order
                            condition {
                                basket = NotContainsDigitalProductsOnly
                            }
                        }
                    }
                }
            }
            email {
                customerConfirmation {
                    active = {$themes.configuration.extension.shop.checkout.onInvoice.email.customerConfirmation.active}
                    from {
                        name = {$themes.configuration.extension.shop.email.from.name}
                        email = {$themes.configuration.extension.shop.email.from.email}
                    }
                    to {
                        # Customer address data
                    }
                    template = {$themes.configuration.extension.shop.email.templates.onInvoice.customerConfirmation}
                }
                order {
                    active = {$themes.configuration.extension.shop.checkout.onInvoice.email.order.active}
                    from {
                        name = {$themes.configuration.extension.shop.email.from.name}
                        email = {$themes.configuration.extension.shop.email.from.email}
                    }
                    to {
                        name = {$themes.configuration.extension.shop.email.to.name}
                        email = {$themes.configuration.extension.shop.email.to.email}
                    }
                    template = {$themes.configuration.extension.shop.email.templates.onInvoice.order}
                }
            }
        }
    }
}
Dokumentation

TYPO3 Shop by coding.ms

Ein umfangreicher Shop für TYPO3 zur Realisierung von Webshops, Online-Shops oder Payment-Subscriptions, vergleichbar mit tt_products, Cart oder Aimeos. Enthalten sind PayPal, PayPal-Checkout, Klarna, Stripe, Bookmarks, UPS-API, Rechnungs­erstellung, Backend-Modul, Vergleichsfunktion, Staffelpreise sowie Produktvarianten, Filter, Steuer- und Versandlogik für den praktischen Einsatz.

Menü
Warenkorb 0 Produkte

Dieses Demo wurde gebaut mit*

EXT:bootstrap_package für das Site-Package aka Theme basierend auf Bootstrap 5.

EXT:modules für Benutzer-Plugins wie Benutzerprofile, Registrierung, Benutzeradressen und mehr.

EXT:shop für die gesamte Shop-Funktionalität.

EXT:questions für die FAQ-Seite und die in den Produktdetailseiten verlinkten FAQs.

EXT:glossaries für die Glossare und Definitionen.

EXT:fluid_fpdf zur Erstellung von Rechnungen, Lieferscheinen, Produktblättern und mehr.

EXT:parsedown_extra zum Rendern der Erweiterungsdokumentation von Markdown in HTML.

* Es wurden ausschließlich integrierte Einstellungen mit site-settings & TypoScript vorgenommen – keine Templates oder andere Dateien wurden geändert oder überschrieben!