Agreed with @DaveMaxwell - there is no way to definitively know if “789” should be “7.89” or “789.00”, unless you can guarantee that every entry will be exactly 5 digits in length.
If all you’re looking to do is make sure that all entered values are formatted for dollar amounts (which that appears to be the case), then you can just use toFixed(x) where x is the number of digits to appear after the decimal point. That will take “789” and make it “789.00”, but it will NOT take “78965” and make it “789.65”, it will make it “78965.00”.