js验证后台传递的map数据是否为空

if(JSON.stringify(data)=='{}'){
$("#year").append("<option>--请选择--</option>");
}