cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

How to bind selected location from tree widget to google map widget

Re: How to bind selected location from tree widget to google map widget

Hi Omkar Darde​,

In your GetLocation service, I see you query with

select plant,location from facility where plant=(SELECT SUBSTRING_INDEX ([[name]],' > ',-1));​

And the output is Infotable with PlantDS, but I see your PlantDS has 5 data fields and not 2, could you test this service successfully?

For example, nevigate to this service, and click test button, and then you input parameter like: Continent1>Country1 > city1?(Use your real data),

if you got error, try to create a new DataShape with two data fields: plant(basetype is STRING),Location(basetype is LOCATION), and assign it to the output INFOTABLE.

Thanks,

Br,

Anna

Re: How to bind selected location from tree widget to google map widget

Hi Anna An,

Query seems to work correctly, here is the test result. 

Thanks

Omkar

Re: How to bind selected location from tree widget to google map widget

Hi Omkar Darde​,

What's the type of your location? Is it LOCATION baseType, if not, I think you need create another service which firstly call your GetLocation service,

and then you add in the second service as:

var location = new Object();

location.latitude = <LATITUDE>;

location.longitude = <LONGITUDE>;

and finally set output as LOCATION basetype, so you bind it to the SelectedLocation of Google map, it should display your city location.

Thanks,

Br,

Anna

Re: How to bind selected location from tree widget to google map widget

Hi Omkar,

I modified the sample again and it works on my side, as I do not have the data in your data base, so I used DataTable instead to store the city information(you just treat it the same to query from database), and the location is from my Mysql database, and the idea is that firstly you query from your database to get the plant, location, but it's stored in an INFOTABLE not ready-to-use, and you need another service to help you retrieve the location string and set it to a Location object and finally, in your mashup, bind the result to SelectedLocation.

I'm sorry for convenience, I modified on basis of my mahsup, please import the entities and have a test on your side, if it still not work, please let me know.

Thanks,

Br,

Anna

Re: How to bind selected location from tree widget to google map widget

Hi Anna,

Will you please provide the Thing_DT-Location. I just want to check the what kind of data it holds, as I am unable to see any data on tree widget on the mashup.

Kind Regards,

Omkar

Re: How to bind selected location from tree widget to google map widget

Hi Omkar,

Sorry it's difficult to export all the Data Tables, so I just keep a snapshot to you:

And also, I attached the Datashape I used for this DataTable(see attachement)

Re: How to bind selected location from tree widget to google map widget

Hey Anna,

We are able to navigate the location with the help of service.

Thanks for your help and support. We will get back to you if we need anything else.

Best Regrads,

Omkar

Re: How to bind selected location from tree widget to google map widget

Hi,

Further we want navigate to another mash up on double click of selected location of google map widget.

1) On double click on tree we want to highlight location , It is working fine

2) On double click on map selected location navigate to another mashup. This is also working fine but fails below scenario

When we try to achieve both together is not happening, what we found is to achieve above functionality we had to checked (Show Selection Marker check box). The moment we checked that navigation functionality from google widget to another mash up get stopped.

Thanks