You can use the key code page in order to find the:
event.code
to diference the number keyboard.
function getNumberFromKeyEvent(event) {
if (event.code.indexOf('Numpad') === 0) {
var number = parseInt(event.code.replace('Numpad', ''), 10);
if (number >= 0 && number <= 9) {
// numbers from numeric keyboard
}
}
}