<td><div class ="input-style-calc"/><input type="number" min="0" max="999" value="0" name="days" id="days" onkeyup="this.value=this.value.replace(/[^0-9]+/g,''); isright(this);" onchange=" isright(this);"/></div></td>
<td><span style="font-size: 14px;" id="result_ls">0</span> руб.</td>
<script>
function isright(obj)
{
if (obj.value>999) obj.value=999;
if (obj.value<1) obj.value='';
result_ls.innerText = (obj.value == '') ? '0' : obj.value;
}
</script>