Blog

Adding QRCodes to the order detail table

Posted by:

You are here:
< Back

In a previous article i explained how to add QRCodes to apdf. This time i am going to explain how to do the same inside the invoice detail table, so you could create a QRCode for the product sku, order price, weight or basically any information of your products.

Getting Started

The process is pretty straight forward, all you need to do is this:

1.- Create a Custom Field

2.- Define which information you want to convert to QRCode, in this example i am going to convert the SKU of the product into a QRCode. To get the sku of the product i need this piece of code :

item[‘sku’]

Note: I could use the same piece of code to get other information like:

  • name:Product Name
  • qty:Quantity
  • weight:Weight
  • line_subtotal:Price of the product without taxes
  • line_total: Price of the product with taxes
  • line_tax: Tax of the product

3.- Generate a QRCode with the information that i defined in my previous step like this:

4.- Use my new Custom Field in my table like this:

 

Thats it! If you have any question please let me know!

 

0
  Related Posts
  • No related posts found.