//千分位
numFormat(row) {
let num = "";
if (row) {
if (row == 0) {
num = 0;
} else {
num = Number(row)
.toFixed(2)
.toString()
.replace(/(\d{1,3})(?=(\d{3})+(?:$|\.))/g, "$1,");
}
}
return num;
}
网友评论