Angular js - 模糊时的舍入数字到小数点后两位

时间:2017-01-22 13:53:34

标签: angularjs

http://plnkr.co/edit/nqUPEI?p=preview

我有输入类型编号文本框&需要将其值格式化为两位小数。

For example if 

(1) If user enter 15.656 it should format to 15.66 on blur

(2) If user enter 15.6 it should format to 15.60 on blur

(3) If user enter 15 it should format to 15.00 on blur

Also will be using the textbox value to carry out further with other     textboxes.

0 个答案:

没有答案