ionic 地图 PC端 加载不出来

图片说明

加载百度地图出现这个情况 代码如下:

.directive("appMap", function () {

return {

restrict: "E",

replace: true,

template: "

",

scope: {

center: "=", // Center point on the map (e.g. { latitude: 10, longitude: 10 }).

markers: "=", // Array of map markers (e.g. [{ lat: 10, lon: 10, name: "hello" }]).

width: "@", // Map width in pixels.

height: "@", // Map height in pixels.

zoom: "@", // Zoom level (one is totally zoomed out, 25 is very much zoomed in).

zoomControl: "@", // Whether to show a zoom control on the map.

scaleControl: "@", // Whether to show scale control on the map.

address:"@"

},

link: function (scope, element, attrs) {

var map;

// 百度地图API功能

map = new BMap.Map("allMap");

map.addControl(new BMap.ZoomControl());

// 创建地址解析器实例

var myGeo = new BMap.Geocoder();

// 将地址解析结果显示在地图上,并调整地图视野

myGeo.getPoint(scope.address, function(point){

if (point) {

map.centerAndZoom(point, 16);

map.addOverlay(new BMap.Marker(point));

}

}, "");

}

};

});
错误是在哪里啊?求大神指教

https://segmentfault.com/q/1010000002971823