mirror of
https://dev.azure.com/hugendubel/ISA/_git/ISA-Frontend
synced 2025-12-31 09:37:15 +01:00
Merged in bugifx/HIMA-1043_invalid-bar-code-fix (pull request #969)
HIMA-1043 set custom symbol counts
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import { Barcode, ScanSettings } from 'scandit-sdk';
|
||||
import { Barcode, ScanSettings, SymbologySettings } from 'scandit-sdk';
|
||||
import { ScanditSdkBarcodePickerComponent, ScanditSdkService } from 'scandit-sdk-angular';
|
||||
|
||||
import { AfterViewInit, ChangeDetectorRef, Component, EventEmitter, Output, ViewChild, OnDestroy } from '@angular/core';
|
||||
@@ -23,28 +23,20 @@ export class RemissionShippingDocumentScannerScanditComponent implements AfterVi
|
||||
@Output() scan = new EventEmitter();
|
||||
@Output() manualEntry = new EventEmitter();
|
||||
destroy$ = new Subject();
|
||||
private activeSymbolCounts = [7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20];
|
||||
|
||||
public settings = new ScanSettings({
|
||||
enabledSymbologies: [
|
||||
Barcode.Symbology.CODE128,
|
||||
Barcode.Symbology.EAN13,
|
||||
Barcode.Symbology.INTERLEAVED_2_OF_5,
|
||||
Barcode.Symbology.CODE25
|
||||
],
|
||||
searchArea: {
|
||||
height: 0.5,
|
||||
width: 0.5,
|
||||
x: 0.25,
|
||||
y: 0.25
|
||||
}
|
||||
});
|
||||
public settings: ScanSettings;
|
||||
|
||||
@ViewChild('scanner') scanner: ScanditSdkBarcodePickerComponent;
|
||||
log = 'tst';
|
||||
constructor(private cameraError: CameraErrorHandler, private cdRef: ChangeDetectorRef, private native: NativeContainerService) {
|
||||
this.webview = this.native.isUiWebview();
|
||||
this.settings = new ScanSettings({
|
||||
enabledSymbologies: [Barcode.Symbology.CODE128, Barcode.Symbology.EAN13, Barcode.Symbology.INTERLEAVED_2_OF_5]
|
||||
});
|
||||
const twoOfFifeSymbology = this.settings.getSymbologySettings(Barcode.Symbology.INTERLEAVED_2_OF_5);
|
||||
twoOfFifeSymbology.setActiveSymbolCounts(this.activeSymbolCounts);
|
||||
}
|
||||
|
||||
ngAfterViewInit() {
|
||||
this.webview = this.native.isUiWebview();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user