当模态加载时,地图部分显示为灰色但在调整大小窗口时会显示,但在重新加载页面时会再次消失。
here is how the map is visible
f($("#google_ptm_map").length > 0){
var gPTMCords = new google.maps.LatLng(29.867865, 77.891575);
var gPTMOptions = {zoom: 16,center: gPTMCords, mapTypeId: google.maps.MapTypeId.ROADMAP}
var gPTM = new google.maps.Map(document.getElementById("google_ptm_map"), gPTMOptions);
var cords = new google.maps.LatLng(29.864865, 77.896575);
var marker = new google.maps.Marker({position: cords, map: gPTM, title: "Marker 1"});
}
<div id="google_ptm_map" style="width: 100%; height: 200px;"></div>