判断一个变量是否是NULL 、SPACE 、undefined

1、 

if(!this.checkNull("oEntity.Nachn")){
    MessageToast.show('姓不能为空!');
    oType = 'E';
    return;						
}

checkNull:function(obj){
    var content ;
    content = $(obj).val();		
    if(!content){
        return false;
    }else{
        return true;
    }
},

2、

$.isEmptyObject(oEntity.Werks)

?mid=&wid=51824&sid=&tid=8555&rid=LOADED&custom1=mp.csdn.net&custom2=%2Fpostedit%2F103231993&t=1574664871629?mid=&wid=51824&sid=&tid=8555&rid=FINISHED&custom1=mp.csdn.net&t=1574664871631

posted @ 2019-11-25 07:58  linhuang  阅读(5)  评论(0编辑  收藏  举报  来源