
內容簡介
SoftGlaze PDF Invoices for WooCommerce 外掛能將 WooCommerce 訂單及手動創建的發票轉換為專業的 PDF 文件。所有渲染均在本地進行,確保安全性與高效能,並提供多種文件類型的自訂模板選擇。
【主要功能】
• 專業 PDF 發票生成
• 四種文件類型支援
• 自訂編號格式選項
• 自動生成信用單
• 本地渲染,無外部請求
外掛標籤
開發者團隊
② 後台搜尋「SoftGlaze PDF Invoices for WooCommerce」→ 直接安裝(推薦)
原文外掛簡介
SoftGlaze PDF Invoices turns WooCommerce orders — and invoices you create by hand — into clean, professional PDF documents. Everything renders 100% locally: the bundled dompdf engine runs on your own server, every logo, icon and font is embedded from local files, and a document render never makes an outbound HTTP request. The default install connects to no outside service; the opt-in exceptions are listed under External services.
Full documentation, setup guides and screenshots: https://softglaze.com/docs/pdf-invoices-plugin-for-woocommerce-and-manual
Four document types, one design system
Invoices, packing slips, proforma invoices and credit notes — one template engine, four faces. Each document type uses a stock design or a custom template you build, at the paper size you choose (A4 / Letter).
Credit notes on refund — refund an order and a credit note is offered automatically, referencing the original invoice.
Receipts — an optional “Receipt vs Invoice” choice at checkout, with its own template and (optionally) its own number sequence.
Delivery notes — print carrier, tracking number, shipping and expected-delivery dates on the invoice and/or packing slip (opt-in, per type).
Numbering that fits your books
Sequential auto-numbering with prefix/suffix, {YYYY} / {MM} placeholders, zero-padding and yearly reset — or simply reuse the WooCommerce order number or the raw order ID.
Separate, race-safe sequences for credit notes and proforma invoices, each with its own start / prefix / suffix / padding.
Migrating from another plugin? Detect existing YITH / WebToffee numbers and continue your sequence from the highest, so numbering stays unbroken.
Automation
Auto-generate documents on the order statuses you choose.
A configurable document × WooCommerce-email matrix — attach the right document to the right transactional email (e.g. the invoice on “Completed”, the packing slip on “Processing”).
Fulfillment stages — a safe parallel flow (In packaging → Dispatched → In transit → Delivered) that never touches WooCommerce’s own order statuses, with live dashboard counters, optional per-stage customer emails, and the current stage printed on packing slips.
Payment reminders — automatically email customers past their due date at the day-offsets you set; reminders stop the moment an order is paid.
Accountant export — on a chosen day each month, email your accountant a ZIP of last month’s invoice PDFs plus a CSV index. A global kill-switch pauses every automated email at once.
A real admin, not just a settings page
A Profit & Loss dashboard — Revenue, Item costs, Gross profit, Margin %, Tax collected, Refunds and Unpaid outstanding, with a month / quarter / year / custom switcher, inline charts, a monthly breakdown and top products, all exportable to CSV. (Honestly labelled “gross profit = revenue − item costs” — sales-and-margin at a glance, not double-entry accounting.)
A searchable, filterable Documents manager with bulk actions — generate, email, or download a ZIP — across both WooCommerce and manual documents, with source / type / status / stage / date filters.
A Products table mirroring your WooCommerce catalogue (thumbnail, SKU, price, cost, stock) with a Cost price field that feeds the margin maths, plus branded product-catalog PDFs.
On the WooCommerce order screen: generate / view / email documents, set the fulfillment stage, and record carrier & tracking — on both the classic and HPOS order screens. There’s also an Invoice column and bulk actions on the orders list, and a “Download invoice” button in My Account.
A built-in System Check page (and WordPress Site Health tests) that verifies PHP, extensions, storage and the engine, and renders a live sample PDF so you can confirm it works before you rely on it.
A guided first-run setup wizard for company details, currency and numbering (with a live invoice-number preview).
Design your documents visually
A drag-and-drop template builder: reorder sections (header, bill-to, meta, items, totals, payment, terms, signature, plus text / divider / spacer and a sanitised custom-HTML block), toggle what each shows, and choose which item columns print.
Design tokens — colours, a bundled dompdf-safe font, base size, heading case, corner radius, header / totals style, logo position and your uploaded logo.
A side-by-side live preview renders through the real engine as you edit, plus an “Exact PDF” button — what you preview is exactly what generates. Start from any of 10 stock designs, and export / import templates as JSON between sites.
Two layout modes — Flow and Canvas. Flow stacks sections down the page; Canvas places blocks freely — drag to move, resize with corner/edge handles, nudge with the arrow keys, and layer them front-to-back. Blocks are positioned as a percentage of the page, the same coordinates the PDF uses, so the layout you build is the layout that prints. Existing templates stay in Flow mode.
Works with or without WooCommerce
Manual invoices — a full “New invoice” screen: saved clients (de-duplicated by email), unlimited line items (quantity, unit price, cost, tax rate), currency, date, template and status. A race-safe number is assigned, the PDF is stored, and a share link is ready — even with WooCommerce switched off.
A public invoice-builder website — four shortcodes ([sgci_invoice_builder], [sgci_my_invoices], [sgci_dashboard], [sgci_login] / [sgci_register]) let visitors sign up, build their own invoices with a live preview, and manage them — a complete self-service invoice site. Every document is private to its owner; one user can never see another’s. When WooCommerce is active, the same view merges into a My Account → Invoices tab.
Share & send
Public share links — a tokenised, no-login viewer page with single-PDF download, per-document expiry (7 / 30 / 90 days or never), regenerate and revoke, and an optional QR code printed on the PDF.
Send any document by email from the order screen or the Documents manager, with an editable recipient / subject / message, dynamic {tags} filled in on send, and a logged send history.
Payments, deposits & client acceptance
Partial payments and deposits — record payments against any document (date, amount, method, note). Once a payment exists, the PDF prints an Amount paid and Balance due pair beneath the total (on all 10 stock designs and your custom templates), the dashboard’s “Unpaid outstanding” counts the remaining balance, and two tags — {amount_paid} and {balance_due} — are available in the builder. On WooCommerce orders the balance respects the order status (only Pending / On-hold show a balance).
Online client acceptance — turn on an “Accept” button on the public share link, per document type (typically a proforma or quote; off by default). The client types their name, ticks an agreement box and accepts; their name, the date/time and IP are recorded, an “Accepted online by …” stamp is added to the PDF, and the order screen logs who accepted. It is a clear, honest online acceptance — not a legally binding electronic signature.
WhatsApp delivery
Click-to-chat (free, zero setup) — every generated document gets a WhatsApp button on the order screen and the Documents manager. It opens WhatsApp (app or web) with the customer’s number and a message containing the document’s secure share link; your own WhatsApp sends it. There are no API keys, and the plugin makes no request of its own.
Cloud API server-send (optional, off by default) — connect your own WhatsApp Business Cloud API account and send the share link from your server with one click. Your access token is stored encrypted, and nothing is sent automatically.
Compliance & exports
VAT / fiscal-code at checkout (classic and block checkout) — each field independently optional or required, scoped to all countries / EU only / a country list, with per-country VAT format checks, the Italian Partita IVA & Codice Fiscale checksums, and an optional EU VIES online lookup (off by default).
Italian e-invoicing (FatturaPA) — generate the official FatturaPA 1.2 (FPR12) XML for invoices and credit notes, per-document or as a bulk ZIP, validated locally against the Agenzia delle Entrate schema before download. Honest scope: it produces the XML file — it does not transmit to the SDI, and it refuses to guess when data can’t be mapped cleanly.
Accounting exports — the Documents list exports to CSV or XML (respecting your active filters), and each document to a UBL-lite XML. Product lists export to CSV / XML too.
Compliance field packs — show your seller VAT, GST/HST and a generic Tax ID in the company block (per document type, off by default), and print an editable EU reverse-charge note (defaults to the Art. 196 wording). In automatic mode the note appears only where reverse charge actually applies — intra-EU B2B with your EU VAT number and a VAT-registered customer in another EU country — or you can set it to always print. The note is informational; it never changes your tax totals.
Multi-language & right-to-left documents
Print the customer-facing document in a chosen language — a store default under Settings → Documents → Language & direction, or per document (on the invoice editor and the WooCommerce order screen). The built-in labels (Invoice, Bill To, Subtotal, Tax, Total, and the rest) translate automatically.
French, German, Spanish, Dutch, Italian, Portuguese and Hebrew are built in; Hebrew (and other right-to-left languages) render the whole document right-to-left using the bundled font, with no extra setup. With no language chosen, documents render exactly as before, and your admin screens stay in English. (Arabic is not offered yet — the bundled PDF engine cannot join Arabic letters correctly.)
Cloud backup (optional, off by default)
Copy every generated document to your own Dropbox or Google Drive, through your own app credentials, with tokens stored encrypted. Nothing is uploaded, and no backup task is scheduled, until you connect an account.
Privacy, security & compatibility
No external requests by default. The PDF engine always renders locally. The opt-in network features are listed under External services.
HPOS (High-Performance Order Storage) compatible; all order data is read through WooCommerce CRUD.
Generated files live in a protected uploads directory (deny-all + index guard) and are served only through capability- and ownership-checked endpoints — a direct link to someone else’s document returns “not found”.
Every feature added since your current version is off by default and update-safe: an existing store’s checkout, documents, emails and numbering are unchanged until you opt in.
Developer-friendly — human-readable React source ships in src/; the filters sgci_document_template_json and sgci_document_html let you reshape output in code; and a shared dynamic-tag engine powers {invoice_number}, {order_number}, {total}, {share_url}, {carrier}, {tracking_code}, {order_meta:key}, {user_meta:key} and more.
Bundled libraries (all GPL-compatible, in vendor/): dompdf (LGPL-2.1) with php-font-lib and php-svg-lib, with docs and tests removed.
External services
On a default install the plugin connects to no outside service, and rendering a document never makes an outbound request. The four services below are the only ones it can send anything to. Each is off at install and does nothing until you switch it on with your own account details.
EU VIES VAT number check
What it is: the European Commission’s VAT Information Exchange System, which confirms that an EU VAT number exists.
When: only when Settings → Checkout → Verify EU VAT numbers online with VIES is on, each time a customer enters an EU VAT number at checkout. Format and checksum checks run locally first.
What is sent: the two-letter country code and the VAT number, from your server to https://ec.europa.eu/taxation_customs/vies/rest-api/ms/
Terms: https://commission.europa.eu/legal-notice_en
Privacy policy: https://commission.europa.eu/privacy-policy-websites-managed-european-commission_en
Dropbox backup
What it is: copies generated documents to your own Dropbox account, through your own Dropbox app.
When: only after you enter your Dropbox app key and secret under Settings → Backup and approve access on Dropbox’s page. Then each new document is uploaded by a WP-Cron task, and “Backup everything now” uploads existing ones. Disconnecting revokes and deletes the token.
What is sent: the document files, which contain the customer and order details printed on them, and their folder path; your app key and secret and the OAuth tokens. Endpoints: https://www.dropbox.com/oauth2/authorize (opened in your browser), https://api.dropboxapi.com/oauth2/token, https://content.dropboxapi.com/2/files/upload, https://api.dropboxapi.com/2/users/get_current_account (to show which account is connected) and https://api.dropboxapi.com/2/auth/token/revoke.
Terms: https://www.dropbox.com/terms
Privacy policy: https://www.dropbox.com/privacy
Google Drive backup
What it is: copies generated documents to your own Google Drive, through your own Google Cloud OAuth client, with only the drive.file scope (files the plugin creates).
When: only after you enter your Google client ID and secret under Settings → Backup and approve access on Google’s page. Then each new document is uploaded by a WP-Cron task, and “Backup everything now” uploads existing ones. Disconnecting revokes and deletes the token.
What is sent: the document files, which contain the customer and order details printed on them, and folder names; your client ID and secret and the OAuth tokens. Endpoints: https://accounts.google.com/o/oauth2/v2/auth (opened in your browser), https://oauth2.googleapis.com/token, https://www.googleapis.com/upload/drive/v3/files, https://www.googleapis.com/drive/v3/files (to find or create the backup folders), https://www.googleapis.com/drive/v3/about (to show which account is connected) and https://oauth2.googleapis.com/revoke.
Terms: https://policies.google.com/terms
Privacy policy: https://policies.google.com/privacy
WhatsApp Cloud API sending
What it is: sends a document’s share link to the customer on WhatsApp from your own WhatsApp Business account, through Meta’s WhatsApp Cloud API.
When: only after you switch it on under Settings → Automations → WhatsApp Cloud API and save your phone-number ID and access token, and then only when you click “Send WhatsApp” on a document. “Test connection” makes one request to read your number’s display name.
What is sent: the customer’s phone number, the message text with the document’s share link (or your approved template’s name and language with the link), and your access token, from your server to https://graph.facebook.com/v20.0/
Terms: https://www.whatsapp.com/legal/business-terms
Privacy policy: https://www.whatsapp.com/legal/privacy-policy
Links the plugin shows but never requests
The WhatsApp click-to-chat button opens a https://wa.me/ link in your own browser. Your server makes no request.
The Documentation link in the admin opens https://softglaze.com/docs/pdf-invoices-plugin-for-woocommerce-and-manual in your browser.
The FatturaPA namespace http://ivaservizi.agenziaentrate.gov.it/docs/xsd/fatture/v1.2 is an identifier written into the XML file. It is never fetched; the schema is bundled and validated locally.
