提交 b50af34e 编写于 作者: tony001's avatar tony001

调整数值框 app-span

上级 a2c305e0
......@@ -192,11 +192,6 @@ export default class AppSpan extends Vue {
this.text = '';
}else if(this.dataType){
this.dataFormat();
if(this.valueFormat){
this.dateFormat();
}else{
this.text = this.value;
}
}else{
this.text = this.value;
}
......@@ -211,12 +206,14 @@ export default class AppSpan extends Vue {
*/
public dataFormat(){
if(this.valueFormat){
return ;
this.dateFormat() ;
return;
}
let number:any = Number(this.value);
if(Object.is(this.dataType,"CURRENCY")){
let number:any = Number(this.value);
this.text = Number(number.toFixed(this.precision)).toLocaleString('en-US')+ ' '+ this.unitName;
}else if(Object.is(this.dataType,"FLOAT") || Object.is(this.dataType,"DECIMAL")){
let number:any = Number(this.value);
this.text = number.toFixed(this.precision);
}else {
this.text = this.value;
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册