Template:Team:Paris Saclay/simbox
From 2013.igem.org
(Difference between revisions)
Line 144: | Line 144: | ||
{ | { | ||
var tmpval= document.getElementById('simbox_ctl_'+simid+'_'+i).value; | var tmpval= document.getElementById('simbox_ctl_'+simid+'_'+i).value; | ||
- | + | if(!is_posint(tmpval)) | |
+ | { | ||
+ | alert('Invalid quantity set for molecule "'+simulations[simid].molecules[i].name+'".'); | ||
+ | return false; | ||
+ | } | ||
+ | simulations[simid].molecules[i].quantity= parseInt(tmpval); | ||
} | } | ||
} | } |
Revision as of 22:00, 2 August 2013