What is the right path for JsBarcode.all.min.js that should be given for the source to be used locally instead of downloading it from the Internet?
In ERPNext version 10 and version 11, it contains JsBarcode.all.min.js under the path: /home/frappe/frappe-bench/apps/frappe/frappe/public/js/lib$, I need to use it instead of downloading it from the link https://cdn.jsdelivr.net/npm/jsbarcode@3.9.0/dist/JsBarcode.all.min.js, so what is the right path that I have to give it in the following codes (in case of javascript or in the printing format):
I tried to place this path: “public/js/lib/JsBarcode.all.min.js” but it is giving the 404 (NOT FOUND) error at the browser console.
Appreciate the kindly help from @fkardame and @Pawan because I found a topic about this in this link:
One note on this reference post:
Using the code the proposed from @Pawan, I am able to view the barcode at the image, but after refreshing, I do not see the barcode again, and really I do not know what is the benefit of using the code field type?
I think that @bkm also complained about the same problem (displaying the image but does not save).
I will have to login to your system and check your custom script that you are using to really comment on the issue you are having. I have personally used similar script for a customer and it is working fine. Also, the idea behind sharing a generic code snippet is that the user / developer / implementor puts in some effort to modify it according to their needs.
Anyway, my problem that I need to know what is the right path to be given for getScript in the line: $.getScript("/public/js/lib/JsBarcode.all.min.js", function( data, textStatus, jqxhr )
So what I am missing to keep the barcode image appearing? I think something related to the code field which is barcode_svg and its related with the image field.
Regards
Bilal