var to = ol.proj.fromLonLat([Number(lng), Number(lat)]);var view = map.getMap().getView();// 设置地图等级view.setZoom(6);view.animate({ center: to, duration: 0});