Piccoli fix su ITF 14 in emulazione tastiera
This commit is contained in:
@@ -110,6 +110,15 @@ public class KeyboardEmulatorBarcodeReader implements BarcodeReaderInterface {
|
||||
} catch (WrongFormatException e) {
|
||||
return BarcodeType.CODE128;
|
||||
}
|
||||
} else if (barcode.length() == 14) {
|
||||
try {
|
||||
int checksum = getEanChecksum(barcode);
|
||||
if (checksum == Integer.parseInt(barcode.substring(13))){
|
||||
return BarcodeType.INTERLEAVED_2OF5;
|
||||
}
|
||||
} catch (WrongFormatException e) {
|
||||
return BarcodeType.CODE128;
|
||||
}
|
||||
}
|
||||
return BarcodeType.CODE128;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user