Hitachi Vantara Pentaho Community Forums
Results 1 to 9 of 9

Thread: Setup Google maps

  1. #1
    Join Date
    Sep 2009
    Posts
    15

    Default Setup Google maps

    Dear Experts,

    If i want to make google maps dashboard lik Steel Wheels samples, can i use report designer or what kind of program that i should use?.. because i no idea to make that kind of dashboard..

  2. #2
    Join Date
    Nov 2009
    Posts
    28

    Default

    Hi!
    I'm not an expert but I can try to give some help.
    If you want to make a dashboard you need CDF installed in Pentaho.
    I can also recommend that you download and install CDF-DD which gives you great help in making dashboards.
    But there are no pre built components for a google map. I guess that's because you need a map license from google and you can only use the free map api if it's public.
    Also you need to feed the map with latitude and longitude.

    But I suggest you create a new xaction for in Design Studio.
    If you follow the video from Michael Tarallo, http://michaeltarallo.blogspot.com/2...1_archive.html, it would be pretty easy.
    Once the Xaction-fil is complete you can use it within CDF (or standalone) by using the Xaction component.

    I havn't tried it myself but I think it would work.

    Br,
    Andreas

  3. #3
    Join Date
    Nov 2009
    Posts
    16

    Default

    I don't think it as that simple. I am struggling with this -xaction is a piece of cake but the CDF is not easy. Does not want to display map.

    Michael Tarrallo from Pentaho has suggested the following, but I still have not figured this out:

    CDF renders the content using AJAX, so if you want to call the Google Maps .xaction object you may have to use an iframe property instead -- see this CDF code snippet here:

    This is a call to an .xaction that renders a custom map component, using SVG, you can see it in the sample in one of my blog entries.
    ..
    myMap =
    {
    name: "myMap",
    type: "xaction",
    solution: "work_verticals",
    path: "Retail/Dashboard/svg",
    action: "usa_map_svg.xaction",
    // listeners:,
    htmlObject: "MapObject",
    // serviceMethod:"ViewAction",
    iframe:true,
    executeAtStart:true,
    preExecution:function(){
    },

    postExecution:function(){}
    }

    So first, you may need to create a .xaction using a message template that references a html page, with the google maps api code in it.

    ..and then, use a CDF xaction component, to call the .xaction using the iframe:true property.

    This should work for you.

  4. #4
    Join Date
    Jun 2007
    Posts
    50

    Default Here to help!

    Matt, if you are involved in the sales process of becoming a Pentaho partner or customer, I'd be happy to get on a call with you and even provide you some working samples with CDF.

    Please contact Ben Tebbs, your account manager, to arrange the call. I am wishful that it is something simply overlooked.

    Susan,

    CDF is API based (JavaScript and HTML coding) - The Google Maps example is also API based ( Java (JSP) and HTML, JavaScript coding) - it does require an understanding of Pentaho Action Sequences (.xaction files) as well, and is usally left for the more Pentaho experienced users.

    There are tutorials here that can help you understand the design tools and there responsibilities.

    Design Studio is the tool that allows you to edit, review and create .xaction files, known as Action Sequences.

    http://www.pentaho.com/products/demo...ales_tools.php

    I have created a sample on the Pre-Sales Consulting Portal that uses a .xaction and a HTML template with the JavaScript Google Maps API code in it.

    You can get the sample here:

    http://wiki.pentaho.com/display/PRES...sulting+Portal - Main Page

    http://wiki.pentaho.com/display/PRES...ced+Techniques - Samples Tips and Techniques

    Dynamic Google Map Widget:
    http://wiki.pentaho.com/display/PRES...+Light+Widgets

    Please let me know how you make out.

    If you are interested in becoming a Pentaho subscription customer, where you can receive immediate development assistance for these types of requests, please contact your account manager and I can further assist you.

    Please reference the blog entries as well, you will see how powerful the suite is.

    Kind Regards,

    Mike Tarallo
    Pre-Sales Director
    Pentaho

  5. #5
    Join Date
    Jun 2007
    Posts
    50

    Thumbs up I have a working sample, I will post as soon as I can clean it up

    See the attached images in this case...

    A google map widget created using a .xaction - from the sample available on the Pre-Sales Consulting Portal.

    and a CDF template calling that component using this syntax:

    theReport =
    {
    name: "theReport",
    type: "xaction",
    solution: "bi-developers",
    path: "action_sequence_examples",
    action: "call_a_google_map.xaction",
    listeners:["begin_date","end_date"],
    parameters: [["begin_date","begin_date"],["end_date","end_date"]],
    htmlObject: "report_object_div",
    iframe:true,
    serviceMethod:"ViewAction",
    executeAtStart:true,
    preExecution:function(){},
    postExecution:function(){}

    }
    Attached Images Attached Images   

  6. #6
    Join Date
    Sep 2009
    Posts
    15

    Default

    Can it runs on Pentaho Bi Server 2.0? Thanks

  7. #7
    pstoellberger Guest

    Default

    i think you should be able to use that in 2.0 as well

    any news on that widget mike?

  8. #8
    Join Date
    Jul 2012
    Posts
    1

    Default

    report designer is for generating report.
    inorder to make dashboards,you shoud look for something like CDE(community dashboard editor)

  9. #9

    Default

    Hi,

    riteshk: They are talking about CDF and thats core part of Ctools (including CDE);

    Susan, AndreasT, matt_gardner,
    If change BI Server + CTools version is not an issue do it shoud be quite simple!
    With CDE is possible to use PROTOVIS component wich u can make a instance of googlemaps... place it upon a layout component and get data through CDA (u can eve listen for parameters)...

    It would go like this:

    first add a JS resource (file) with:
    https://maps.google.com/maps/api/js?sensor=false

    Them add a layout componente (map_holder)

    Them add a protovis componente (and configure it like a normal chart) with JS like:
    (where "queryResult" will receive the CDA from protovis componente conf.)

    function plot(vis,queryResult){

    /* carrega dados */
    var data = queryResult.resultset;
    var markersArray = [];

    /* Opcoes do mapa */
    var myLatlng = new google.maps.LatLng(-15.794280, -47.882023);
    // var homeLatlng = new google.maps.LatLng(-22.813857, -43.244848);

    var myOptions = {
    zoom: 8,
    center: myLatlng,
    mapTypeId: google.maps.MapTypeId.ROADMAP
    };

    var map = new google.maps.Map(document.getElementById("map_holder"),myOptions);

    // console.debug(data[0][0]);
    }

    No need for complex xactions... or xml edit... u just go for the basic js api....

    The major problem with "google maps" approch is the licence issues... U should look for Openlayers ( http://openlayers.org/ ) as a alternative... (i goes pretty much like googlemaps)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Privacy Policy | Legal Notices | Safe Harbor Privacy Policy

Copyright © 2005 - 2019 Hitachi Vantara Corporation. All Rights Reserved.