Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Post function to print barcode of a custom field onto the network printer

keval.doshi July 1, 2018

Hello everyone,

 

I am building an inventory management system in JIRA. To automate a few processes and to avoid manual errors we use barcodes. Now, we need an option to generate a barcode based on a custom field value and send that barcode for a print on the network printer using a post function call with Scriptrunner. 

 

Please let me know how do I go about doing this.

 

 

1 answer

Suggest an answer

Log in or Sign up to answer
0 votes
Aron Gombas _Midori_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
September 21, 2018

Interesting use case!

You can definitely implement it based on this idea:

  1. Use the barcode feature of the Better PDF Exporter app. Basically, if you don't want anything else, but the barcode itself, create a PDF template that contains nothing else, but the barcode. The app allows encoding any information, including custom field values, in the barcodes! See this tutorial.
    1. Extra hint: you can customize your template from the default issue-fo.vm by dropping all fields and turning the QR code to the barcode you need. (See the screenshot at the bottom.)
  2. Then implement the post function in ScriptRunner which renders the PDF with the barcode. It is also simple, see this second tutorial.
  3. Now you have the PDF document in the Groovy script, triggered by the post function. You will send that to the print. I don't actually know how to do this, but I guess it would copying the bytes to some source that is consumed by the printer.

jira-single-issue-export-with-qr-code

keval.doshi September 23, 2018

@Aron Gombas _Midori_ thanks for such an elaborate suggestion. I would definitely try this and let you know how it goes.

TAGS
AUG Leaders

Atlassian Community Events