Carriers post the shipping label and (for international) the commercial invoice
to the delivery order's chatter, where they were hard to find. Add two smart
buttons on the stock.picking form that open the latest of each via the PDF
preview dialog (fusion_pdf_preview when installed, else open in a new tab).
Document discovery is carrier-agnostic (computed from the picking's attachments):
labels match 'Label*'; invoices match '*CommercialInvoice*' (UPS/Canada Post) or
'ShippingDoc-*' (FedEx/DHL, _get_delivery_doc_prefix). Buttons hide when absent.
Verified on entech: real FedEx picking resolved its label (invoice correctly
none for a domestic ship); synthetic UPS names resolved label+invoice and the
invoice button fired fusion_pdf_preview.open_attachment.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
- Relabel UPS 'Bill My Account' -> "Bill recipient's UPS account" with clear
help (it bills the customer's own UPS account; $0 shipping line; falls back to
Bill Shipper when the customer has no account on file).
- Improve the customer 'UPS Account Number' field help (stored per-customer,
auto-recalled at ship time for Bill Receiver).
- Add ups_rest_documentation_type setting (No / UPS commercial invoice) on the
UPS REST carrier, mirroring FedEx. Default 'invoice' preserves the existing
auto-generate-on-international behaviour; gate require_invoice on it so it can
be turned off. Surfaced on the UPS REST config page.
Validated live on entech (UPS production): CA->US shipment generated the label
+ a 60KB commercial invoice PDF (country of origin auto = CA, HS code applied),
then voided. Bill Receiver request confirmed accepted by UPS.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>