EH
Asked
Good morning, i want to ask about the barcode when adding new product. If the product dont have a barcode we can generate a random barcode.
The question, is there a way to change the minimum number it can generate. Maybe for example minimal 10 digits or more or less.
The question, is there a way to change the minimum number it can generate. Maybe for example minimal 10 digits or more or less.
- EGAnsweredYes, you can set the number of digits to generate randomly, but not in terms of minimum or maximum, as it will be fixed to the number you entered.
To achieve this, edit the value in `generateCardNo(x)` function in `core.js`, path: `themes\default\admin\assets\js` in `line 125` to your desired digits or leave it empty to generate 16 digits barcode number.
Example `var code = generateCardNo(15);` or leave it empty `var code = generateCardNo();` to generate 16 digits barcode number - Login to Reply