Array ( [0] => GDPR Cookie Consent [1] => CCPA [2] => Getting Started [3] => Changelog [4] => GDPR [5] => Add and Categorise Cookies [8] => Auto-block cookies with Script Blocker [13] => Create Privacy Policy Page [15] => Customize Cookie Notice [18] => Customize Settings Pop up [19] => Change Toggle button color [21] => Display Cookie List [22] => FAQ [23] => Getting Started [24] => Multilingual Support [25] => Overview [26] => Import Export Suite for WooCommerce [28] => Order / Coupon / Subscription Export Import Plugin for WooCommerce [29] => PayPal Express Checkout Payment Gateway for WooCommerce [30] => Changelog [31] => Getting Started [32] => Issue Refund [34] => Video Tutorial [35] => Print Invoice, Packing Slip, Delivery Note & Label for WooCommerce [36] => Address Label [39] => Changelog [41] => Credit Note [43] => Delivery Note [45] => Dispatch Label [47] => FAQ [48] => Invoice [49] => Adding meta data [50] => Customizations [51] => Email PDF Invoice [52] => FAQ [53] => Getting Started [54] => Invoice Number [55] => Multilingual Support [56] => Overview [57] => Packing Slip [58] => Customizations [59] => Getting Started [60] => Pick List [62] => Proforma Invoice [65] => Shipping Label [68] => Product Import Export Plugin for WooCommerce [69] => Smart Coupons for WooCommerce [70] => Abandoned Cart Discount [71] => Advanced Coupon Options [72] => Bulk Generate [73] => Changelog [76] => Getting Started [78] => Import Coupon [80] => Sales Countdown Timer [81] => SignUp Coupon [82] => Store Credit [84] => Volume/Quantity based coupon [85] => Stripe Payment Gateway for WooCommerce [86] => Alipay [87] => Apple Pay [88] => Changelog [89] => Compatibility with Subscription [90] => Getting Started [93] => SCA Ready [94] => Stripe Checkout [95] => Stripe Overview [96] => Stripe via Credit Card [97] => Troubleshoot [98] => Video Tutorial [99] => Subscriptions for WooCommerce [100] => Changelog [101] => Email Notifications [102] => FAQ [103] => Getting Started [104] => Manually Add or Modify Subscriptions [105] => Subscriptions Payment Gateway Guide [106] => URL Coupons for WooCommerce [107] => Changelog [108] => FAQ [109] => Getting Started [110] => Import URL Coupons [111] => QR Code Coupon [112] => WordPress Users & WooCommerce Customers Import Export )

Documentation/Print Invoice, Packing Slip, Delivery Note & Label for WooCommerce/Use of predefined filters in WooCommerce shipping documents

Use of predefined filters in WooCommerce shipping documents

WooCommerce PDF Invoices, Packing Slips, Delivery Notes & Shipping Label plugin is equipped to handle all e-commerce document requirements. It consists of specific settings to configure the document types according to your desired functionality. You can even customize each document layout and append necessary details into it.

Apart from existing features, the plugin also provides additional filters to extend plugins functionality. Each filter is incorporated to serve distinct purposes.

In order to get access to these filters, first of all, install and activate the plugin from the WooCommerce dashboard. Navigate to the general settings of the plugin.

It is in the general settings where all the common information pertaining to various shipping documents are configured. It consists of a Help Guide tab which is further classified into Help Links and Filters. Help links will take you directly to the documentation and support. The filters will list out various code snippets which help to extend the underlying plugin functionality.

WooCommerce Invoice or Packing Slip-Help-Filter List
WooCommerce Invoice or Packing Slip-Help-Filter List

You can expand a filter to get its code snippet, copy the code and paste it in the function.php of your active child theme.

For example, to change the default appearance of the order date in the invoice, you can use the filter Alter order date.  You can simply copy the corresponding code snippet by expanding the filter as shown below:

WooCommerce Invoice or Packing Slip-Alter Order Date Filters
WooCommerce Invoice or Packing Slip-Alter Order Date Filters

Next, you will have to paste the code into the function.php file.

It is to be noted that, the filter should be placed within the concerned function with an adequate number of arguments placed appropriately within the parenthesis. In the above example, wf_pklist_alter_order_date is the filter name and wt_pklist_change_order_date_format is the function name.  Also, the return date format is specified as “Y-m-d” which means the order date will be displayed as Date:2019-09-26. However, you can insert the values accordingly to get your desired style. If  “Y-M-d” is used, then the order date will be displayed as Date:2019-Sep-26.

To know more about various date constants that can be used, refer to the article.

  • Was this article helpful ?
  • YesNo