Hi all,
will the new Barcode Type coded during conference will be merged into frappe framework?
Thx
Hi all,
will the new Barcode Type coded during conference will be merged into frappe framework?
Thx
https://github.com/frappe/frappe/pull/4335
This may spawn plenty of use cases; @akurungadam suggested bulk printing of barcode stickers. Let us know what you think
For retailers, an option to print stickers for the quantity of items they receive will help. This could be done from the Item itself via button and taking the number of stickers to print. The print format should be able to print that many stickers. Also, the stickers come in various sizes and the roll will be of x stickers in a row - so we may have to capture this configuration too. We’ll also have to consider other info - Item Name, Brand etc. to be printed alongside as part of the print format.
Not a priority for us right now, but will see if we can take this up some time.
Printing barcodes directly from goods received works well. Granted a lot of retail shops still print barcodes onto A4 layout pages But there are now some very cheap Thermal Barcode printers that print out a roll that is just one barcode wide. This saves the hassle of needing a software interface to print barcodes just on the remaining barcode stickers on an A4 sheet.
@pratu16x7 any chance to add options in barcode field? It would be useful to set barcode type, height etc …
Sure. That would be the ideal usage, as by default JsBarcode would give the 128 type ones, when EAN is just as popular. But to control those, you’d need some additional UI to set those options; for example in addition to the input field to set the value, you’d need a dropdown to set the type, another for height and so on. Why not raise a GitHub issue for this, will easier to keep track of the code changes required
@pratu16x7 sure i will …
i was thinking something like Select options, kind of:
Question is, how can i get values from Options in field definition?
Excellent! That would be perfect for setting the type (you wouldn’t need the "type: ", just EAN13
). Every control object has an options
property that receives whatever you set in there. There’s width
as well, but not height
as far as I’ve seen. For all these JsBarcode properties you can’t map this cleanly, we’d have to think creatively.
that’s why i was thinking having kind of property: value
, is not clean?
The options
field is of type small text
and not code
, so it’s not standard to use it to parse complex strings like key value pairs, but it is possible. We’ve so far used it to parse single values or list of options at the most
i see, if you consider the pair property: value
as string:
format: "EAN13"
font: "OCR-B"
and convert \n
into ,
. At that point could be possible to set option into JSBarcode, like:
JsBarcode(svg, value).options({format: "EAN13", font: "OCR-B"})
Could be a solution?
Sure, as I mentioned, it is possible. Send in a PR for this, and if this is not the only use case, we’ll see if options
can be a code
field as well.
I’ll try to send a PR …can u just let me know how to get options inside ControlBarcode
So in ControlBarcode
you can access it as this.options
Oh ok …stupid me … i’ll try to send a PR
Yippee!!!
Finally we are close to having a native barcode printing solution in ERPNext.
I look forward to having a chance to test this. I print several hundred barcode labels per day already and I really want to get rid of the clunky 3rd party printing software.
I am not a developer or coder, but if there is anything I can do to help you can count on my support!
BKM
You can already test in develop branch …i’m going to send a PR to have more options …
Got it !!
Will set up a developer server this afternoon. I will populate it with a copy of my live data and test over the weekend.
Thanks!
BKM
here it comes: