@@ -163,22 +163,27 @@ export function tansParams(params) {
// 客户等级
export function levelText(val){
let text = '';
- switch (val){
- case 0:
- text = '无';
- break;
- case 1:
- text = '钻石';
- case 2:
- text = '白金';
- case 3:
- text = '黄金';
- case 4:
- text = '普通';
+ if(val){
+ switch (val){
+ case 0:
+ text = '无';
+ break;
+ case 1:
+ text = '钻石';
+ case 2:
+ text = '白金';
+ case 3:
+ text = '黄金';
+ case 4:
+ text = '普通';
+ }
+ return text;
+ }else{
+ return text = '无';
}
- return text;
+