小于5显示数,不显示数字

This commit is contained in:
daihh
2022-12-01 15:28:16 +08:00
parent 749c14add2
commit ef5dc84212

View File

@@ -242,7 +242,7 @@ export function getHMS(time) {
/**格式化人数的文档 ,学习人数,关注人数等*/
export function formatUserNumber(num) {
let rsNum =0;
if(num<5){return 0;}
if(num<5){return num;}
if(num>=5 && num<= 10){return 10 +"+";}
if(num<=94){
rsNum=Math.round((num)/10)*10;