Google maps issues

(8 posts) (2 voices)
  1. ajdjackson, Member

    Hi

    I've a couple of issues with Google maps that I hope you can help with.

    The most serious is that I have built a dashboard report and have added the following to the main-top.html:

    <script type="text/javascript"> embed_url("https://xx-xxx.com/report.php?r=11&m=8&h=ebfee5196fc1f41d1da7c265065800f6ad3810a4&i=1&hdr=0&embed=1", false); </script>

    Instead of seeing the map I just get 'Generating the map...'. It displays when the dashboard report is run on its own.

    The next issue that when the dashboard report is run the Google control icons are missing eg where I would expect to see a + for zoom in all I see is a white box. It's the same for all the controls expect Map Style which I suppose is only a text field.

    Any thoughts?

    Cheers

    Jake

  2. ajdjackson, Member

    Hi

    Sorted the non-display issue by adding the script calls to google to the main-top.hml

    Just need to solve the missing icons.

    Cheers

    Jake

  3. myDBR Team, Key Master

    If you want to include a Google Maps in dashboard, you need to include both the Google's Map API call and the 'extensions/googlemaps/map.js' script. After that the maps should display correctly (also with icons).

    --
    myDBR Team

  4. ajdjackson, Member

    Hi

    I have those both in the main-top.html file:

    <style>.sidebar {display:none;}</style> <script type="text/javascript" src="https://maps.google.com/maps/api/js?key=mykey&libraries=visualization&amp"></script> <script type="text/javascript" src="extensions/googlemaps/map.js?v=3629"></script> <script type="text/javascript"> embed_url("https://xx-xxx.com/report.php?r=11&m=8&h=ebfee5196fc1f41d1da7c265065800f6ad3810a4&i=1&hdr=0&embed=1", false); </script>

    In the dashboard I just call the report's sp. The report itself displays as expected along with its icons - it's only in the dashboard are the icons missing.

    Cheers

    Jake

  5. myDBR Team, Key Master

    Jake,
    you can see from the Google Maps documentation the conditions where the controls are shown by default:

    https://developers.google.com/maps/documentation/javascript/controls

    --
    myDBR Team

  6. ajdjackson, Member

    Hi

    I'm getting the controls ok and they function - the issue is that the icons such as the zoom + is not visible just it's control box with no contents.

    Yet they display if I run the code below as a separate report:

    declare v_marker varchar(255); declare cwidth varchar(5) default "100%";

    set v_marker = 'user/images/circle.svg';

    select 'dbr.googlemaps', 'coordinates','Where are Customers are',cwidth,359;

    select a.tblcustomer_Lat, a.tblcustomer_Long, if(a.tblcustomer_URL is null,concat(a.tblcustomer_Name,' ',format(b.CustSize,0)),concat('',a.tblcustomer_Name,' ',format(b.CustSize,0))), f_cust_size(v_marker, b.custsize) from tblcustomer a join (select tblweeklycol_CustID as Cust, sum(tblweeklycol_SalesVal) as CustSize from tblweekly group by tblweeklycol_CustID) b on a.tblCustomer_SOID=b.Cust where a.tblcustomer_Name != "INDIRECT";

    I've no idea why they don't show.

    Cheers

    Jake

  7. myDBR Team, Key Master

    That looks like browser caching issue / network issue. Take a look at the browser debugger and see why the controls are not loading.

    --
    myDBR Team

  8. ajdjackson, Member

    Hi

    Just to say I got this sorted.

    It was the following css:

    .sdiv4 img {max-width:100%!important;object-fit: contain;padding:0;margin:0;}

    It overwrote the .gm-style img {max-width:none;}

    Cheers

    Jake


Reply

You must log in to post.