js 四舍五入

1 num.toFixed(2).replace(/\B(?=(\d{3})+(?!\d))/g, ',')

 

posted on 2019-03-20 09:41  江清澜静  阅读(80)  评论(0编辑  收藏  举报

导航