The barcode input form trims leading and trailing spaces from barcodes
in the Angular holdings editor.
Spaces in the middle of the barcode are not removed.
Signed-off-by: Bill Erickson <berickxx@gmail.com>
Signed-off-by: Ruth Frasur <rfrasur@library.in.gov>
Signed-off-by: Galen Charlton <gmc@equinoxOLI.org>
}
barcodeChanged(copy: IdlObject, barcode: string) {
- // note: copy.barcode(barcode) applied via ngModel
+
+ if (barcode) {
+ // Scrub leading/trailing spaces from barcodes
+ barcode = barcode.trim();
+ copy.barcode(barcode);
+ }
+
copy.ischanged(true);
copy._dupe_barcode = false;