提交 98869121 编写于 作者: 张平's avatar 张平

Merge branch 'dev-cme-1216' into 'release'

学习人数保留一位小数点 codereviewer : 张平

学习人数保留一位小数点 codereviewer : 张平

See merge request !2
...@@ -34,9 +34,9 @@ export default { ...@@ -34,9 +34,9 @@ export default {
computed: { computed: {
newStudyNum: function() { newStudyNum: function() {
if(this.studyNum > 1000 && this.studyNum < 10000) { if(this.studyNum > 1000 && this.studyNum < 10000) {
return (this.studyNum / 1000 + 'K'); return ((Math.round((this.studyNum / 1000) * 10) / 10) + 'K');
}else if(this.studyNum > 10000) { }else if(this.studyNum > 10000) {
return (this.studyNum / 10000 + 'W'); return ((Math.round((this.studyNum / 10000) * 10) / 10) + 'W');
}else { }else {
return this.studyNum; return this.studyNum;
} }
...@@ -44,7 +44,7 @@ export default { ...@@ -44,7 +44,7 @@ export default {
}, },
created() {}, created() {},
mounted() { mounted() {
}, },
methods: { methods: {
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册