From installation to the finished document: create a text per payment method, use placeholders and templates, set document types and scopes, include PayPal Pay Upon Invoice and adapt the text block to the layout of the invoice.
Shopware 6.6 or 6.7. The plugin extends the Shopware document template and needs no theme build. For bank data to be available as placeholders, it should be maintained in the Shopware document settings.
Important: The text appears on documents created after saving. PDF documents that were already generated stay unchanged until they are created again.
Installation
The easiest way is the Plugin Suite: select the plugin, install and activate it, updates then come with one click. Alternatively upload the ZIP in the Shopware admin under Extensions, My extensions, Upload extension, then install and activate it. No SSH access is required.
Opening the plugin
The plugin sits in the admin menu under Stone & Water, Payment information on PDF documents. Below the header there are two tabs: Payment methods with the texts and Settings with position and appearance on the document.
Payment method overview
The list shows all payment methods with the status of the text: Own text, Inherited from a parent scope or No text. At the top you choose sales channel and language, the search field filters by name.
With "Show inactive payment methods" payment methods that are deactivated in Shopware appear too. Labels show when a payment method is not assigned to the selected sales channel or when it is PayPal Pay Upon Invoice. The column "Show on invoice" switches the output on or off directly from the list.
Creating a text
"Edit" opens the window of the payment method. In the field Text you write the note that appears on the document directly below the selected payment method. Formatting such as bold, lists and line breaks is kept. After "Save" the text is active for new documents right away.
The switch Show on document defines whether the text is printed for the selected document type. When switched off the text stays saved and appears again as soon as you switch it on.
Inserting templates
"Insert template" offers two ready-made texts: Bank transfer with invoice amount, payment period, bank details and customer and order number as payment reference, and PayPal Pay Upon Invoice (Ratepay) with the note on the assignment to Ratepay and the bank data of the payment. The template lands in the text and can then be adjusted freely.
Using placeholders
Placeholders are written in curly brackets, for example {orderNumber}. A click in the placeholder list inserts it at the cursor position. When the document is created Shopware replaces it with the value of the respective order. The list is divided into groups and collapsed when opened.
Due date with a date: {dueDate:14} inserts the document date plus 14 days, the number can be changed freely, for example {dueDate:30}. {paymentDueDate} instead uses the payment due date from the Shopware document settings.
Custom fields: {orderCustomField:name} and {transactionCustomField:name} read a custom field of the order or the payment. Replace name with the technical name of the field.
Preview
The preview in the edit window shows the text as it appears on the document, using the current appearance from the settings. Without an entry the latest order with this payment method is used. In the field "Order number for preview" you can choose another order. If there is no order with the payment method yet, the preview works with sample data.
Invoice, delivery note, credit note, cancellation
The edit window has a tab per document type: invoice, delivery note, credit note and cancellation invoice. The invoice is the basis. The other document types use its text until you create an own one there; adjusted tabs are marked.
For delivery note, credit note and cancellation invoice the switch "Show on document" is off at first. That way the bank details, for example, do not end up on the delivery note by accident.
Sales channel and language
At the top of the edit window you choose the sales channel and language you are editing the text for. The basis is "All sales channels" and "All languages". Every other scope uses their text until you set an own one with "Customise text for this scope". "Inherit again" returns to the parent text.
Sales channels and languages with own values are marked in the selection. If you switch scope with unsaved changes, the plugin asks first.
Position on the document
Under Settings, General you define where the text is placed: directly below the line "Selected payment method", after the shipping method before the additional text, or after the whole block, also after the additional text. The additional text is the Shopware snippet document.paymentShippingInfo.additionalInfo, maintained under Settings, Snippets.
Spacing and appearance
Under Spacing you set margin and padding of the text block per side in pixels. Under Appearance you set background and text colour, border width, border colour, corner radius, font size, line height and alignment. Empty colours and the value 0 for font size and line height keep the values of the document.
Custom CSS
For cases the settings do not cover there are custom CSS rules. They are inserted into the head of the document. The text block has the class staw-payment-info.
PayPal Pay Upon Invoice
With PayPal Pay Upon Invoice the customer transfers to Ratepay. The bank data, payment reference and due date are stored in the payment of the order and can be inserted with the placeholders of the PayPal Pay Upon Invoice group. The template "PayPal Pay Upon Invoice" already contains the note on the assignment to Ratepay.
For Pay Upon Invoice PayPal adds its own note and bank data block to the document. If "Hide PayPal Pay Upon Invoice default block" is active, this block is removed as soon as an own text is printed. Without an own text the PayPal default block stays.
Note: PayPal only provides the payment data once the payment is completed. If it is still missing, the preview shows a corresponding note.
Troubleshooting
Text does not appear: Check the main switch "Print payment information", the switch "Show on document" for the document type and whether a text is stored or inherited for the matching sales channel and the language of the order. Then create the document again.
Placeholder stays empty: The value is missing in the order or in the document settings, for example an IBAN that is not maintained. For PayPal Pay Upon Invoice PayPal only delivers the data once the payment is completed.
Bank data twice with PayPal Pay Upon Invoice: Switch on "Hide PayPal Pay Upon Invoice default block". It applies as soon as an own text is printed for the payment method.
Support
Questions and requests are welcome directly - support comes from the developer, not from a queue. A feature can also be requested through the Plugin Suite in the admin.
All settings
Every setting of the plugin with default value and explanation, in the same order as in the administration. The texts come directly from the plugin (version 1.1.6). Settings apply to the selected sales channel, without an own value the value of "All sales channels" is inherited.
General
Print payment informationDefault: on
Turns the output on all documents on or off.
Position on the documentDefault: Directly below the payment method
Directly below the line "Selected payment method", after the shipping method before the additional text, or after the whole block, also after the additional text.
Hide PayPal Pay Upon Invoice default blockDefault: on
Hides the note and bank data block PayPal adds itself for Pay Upon Invoice when an own text is printed.
Spacing
MarginDefault: top 4, right 0, bottom 8, left 0
Space between the text block and the surrounding content, in pixels.
PaddingDefault: 0 on all sides
Space between border and text, in pixels - mainly useful with a background colour or border.
Appearance
Background colourDefault: empty (transparent)
Leave empty for transparent.
Text colourDefault: empty
Leave empty for the document text colour.
Border widthDefault: 0
Value in pixels, 0 for no border.
Border colourDefault: #d1d5db
Colour of the border.
Corner radiusDefault: 0
Value in pixels.
Font sizeDefault: 0
Value in points, 0 keeps the document font size.
Line heightDefault: 0
Factor, for example 1.4 - 0 keeps the document line height.
AlignmentDefault: Left
Alignment of the text in the block: left, centre, right or justified.
Custom CSS
CSS rulesDefault: empty
Inserted into the head of the document. The text block has the class staw-payment-info.
Edit window per payment method
Scope (sales channel and language)Default: All sales channels, All languages
Defines the sales channel and language you are editing the text for. Without an own value the parent scope is inherited.
Document typeDefault: Invoice
Tabs for invoice, delivery note, credit note and cancellation invoice. The other document types use the invoice text until an own text is created there.
Show on documentDefault: on for the invoice, off for the other document types
Turns the output of the text on the selected document type on or off for the selected scope. The text stays saved.
TextDefault: empty
Appears on the PDF document directly below the selected payment method. Formatting and placeholders are kept.
Order number for previewDefault: empty (latest order)
Optional. Without an order number the latest order with this payment method is used.
All placeholders
All placeholders in the same grouping as in the edit window.
Order
Order number{orderNumber}
Order date{orderDate}
Total amount (gross){amountTotal}
Total amount (net){amountNet}
Tax amount{amountTax}
Shipping costs{shippingTotal}
Currency{currency}
Payment method{paymentMethod}
Customer
Customer number{customerNumber}
First name{customerFirstName}
Last name{customerLastName}
Company{customerCompany}
Email{customerEmail}
Document
Document number{documentNumber}
Document date{documentDate}
Invoice number{invoiceNumber}
Document date plus days{dueDate:14}
Payment due date (document setting){paymentDueDate}
Shop and bank (document settings)
Company name{companyName}
Bank{bankName}
IBAN{bankIban}
BIC{bankBic}
PayPal Pay Upon Invoice (Ratepay)
Account holder{puiAccountHolder}
Bank{puiBankName}
IBAN{puiIban}
BIC{puiBic}
Payment reference{puiReference}
Due date{puiDueDate}
More
Order custom field{orderCustomField:name}
Payment custom field{transactionCustomField:name}
Availability
Directly through Stone & Water
Available now
Monthly9,99 €
Best valueYearly101,90 €15 % cheaper
All prices net plus VAT.
Download the free Plugin Suite and upload it in the admin, no SSH needed. It installs and updates the plugin with one click. You buy the licence directly from us, with an invoice from us and support straight from the developer.
The plugin will be listed in the official Shopware Community Store. Installation and automatic updates then run through the plugin manager in the backend, billing through your Shopware account. We will link it here as soon as it is available.