summaryrefslogtreecommitdiff
path: root/indoteknik_custom/static
diff options
context:
space:
mode:
authorMiqdad <ahmadmiqdad27@gmail.com>2025-08-21 08:57:04 +0700
committerMiqdad <ahmadmiqdad27@gmail.com>2025-08-21 08:57:04 +0700
commit2026e1244712658e4ed2fa6182a778bb91910d5d (patch)
tree0f58f72ef18b8c90e86cb97c14bfb5f4b61a968a /indoteknik_custom/static
parent19f753388b29870183023c4d3e6f169ba4bdb333 (diff)
<Miqdad>hehe
Diffstat (limited to 'indoteknik_custom/static')
-rw-r--r--indoteknik_custom/static/src/js/check_product_barcode.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/indoteknik_custom/static/src/js/check_product_barcode.js b/indoteknik_custom/static/src/js/check_product_barcode.js
index f7a1bb75..d81d630a 100644
--- a/indoteknik_custom/static/src/js/check_product_barcode.js
+++ b/indoteknik_custom/static/src/js/check_product_barcode.js
@@ -4,7 +4,7 @@ odoo.define('indoteknik_custom.prevent_manual_typing', function (require) {
console.log("✅ Custom JS from indoteknik_custom loaded!");
- const THRESHOLD_MS = 40; // jeda antar karakter dianggap scanner kalau <40ms
+ const THRESHOLD_MS = 500;
let lastTime = 0;
let burstCount = 0;
@@ -16,7 +16,7 @@ odoo.define('indoteknik_custom.prevent_manual_typing', function (require) {
} else {
burstCount = 1;
}
- return burstCount >= 3; // setelah 3 char cepat, dianggap scanner
+ return burstCount >= 2;
}
document.addEventListener('keydown', function (e) {