JS数字千分: 1.例子:1000--->1,000 2.实现如下: salesToFormat: function (num) { var num = (num || 0).toString(), result = ''; while (num.length > 3) {//拿掉num的最后三位给result result = ',' + num.slice(-3) + result; num = num.slice(0, num.length - 3); } if (num) { resu…