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

Community Tip - Need to share some code when posting a question or reply? Make sure to use the "Insert code sample" menu option. Learn more! X

Selected Rows Values are not available from Infotable property

RN_8282441
1-Newbie

Selected Rows Values are not available from Infotable property

Hi,

I have MyCustomThing having (employees) infotable as property, and script-service  to fetch data and set that infotable property.

On Mashup, when i call GetPropetryValue() and map this Infotable(employees) to the grid, then data loading into grid.

But selected Row values are not having data of selected row to load Gauge widget or label.

Is there anything i am missing.

It will work, if i set service return type as infotable and map to Grid.

1 ACCEPTED SOLUTION

Accepted Solutions
jdass
12-Amethyst
(To:RN_8282441)

Hi Raj,

I have attached the modified entities. This is what I did

1) I created another infotable property InfoTableProp2 in TestThing

2) Created a service called getInfoTableValues and I used the infotable function UNION of get the rows of both the infotable properties.

3) Used the getInfoTableValues service in the mashup to display all the rows in one grid , and bound the selected rows of the service to the second grid.

View solution in original post

17 REPLIES 17
supandey
19-Tanzanite
(To:RN_8282441)

Hi Raj, what's triggering the selectedRow event? which field are you trying to bind from SelectedRow to the Gague?

Hi Sushant.

Thanks for addressing this issue.

what's triggering the selectedRow event? - > This event is not bind trigger to anything on mashup.


which field are you trying to bind from SelectedRow to the Gague?

On grid row select, There are two fields from selected rows that i am trying to bind for "Data" and "MaxValue" of Gauge widget.

jdass
12-Amethyst
(To:RN_8282441)

Hi Raj,

Please elaborate a little more on your use case.

Hi

Task is to set infotable property of thing via service, now retrieve this property and map to mashup grid.

on selecting any row of that grid, selected Rows columns should have values from that row ...but there values are not updating from selected row.

posipova
20-Turquoise
(To:RN_8282441)

Are you trying to map the infotable values to the gauge? That would not work.

Instead, try the following: drop two grids onto a mashup. Bind All data from your service onto one of the grids. Then bind Selected Rows of your service onto the second grid. Load your mashup and try making a selection from grid 1.

I have same use case, In same example can you map second grid from selected rows of Infotable as below (If you expand InfoProp you will get selected row)

because i have 5 infotable in property, how i can map all selected rows to just one Grid.

attaching example to reproduce this issue.

jdass
12-Amethyst
(To:RN_8282441)

Hi Raj,

I have attached the modified entities. This is what I did

1) I created another infotable property InfoTableProp2 in TestThing

2) Created a service called getInfoTableValues and I used the infotable function UNION of get the rows of both the infotable properties.

3) Used the getInfoTableValues service in the mashup to display all the rows in one grid , and bound the selected rows of the service to the second grid.

I think you have missed testValueStream while exporting entities,

getting error on import  [message: Import Failed: Validation Failure: Thing TestThing Had An Invalid Value Stream Thing : [testValueStream]]

jdass
12-Amethyst
(To:RN_8282441)

The output mashup:

Hi,

yeah getting infotable properties via services is one of the solution, i will definitely going to use this.

Really appreciate for your support.

one more thing, i am getting following error in log once on loading mashup. is it working fin to you?

I am using Thingworx 8

11:24:06 ERROR - An error occurred while calling dhxgrid::afterRender, Id = "dhxgrid-1". Exception: list.split is not a function

11:24:06 ERROR - An error occurred while calling dhxgrid::afterRender, Id = "dhxgrid-2". Exception: list.split is not a function

jdass
12-Amethyst
(To:RN_8282441)

Hi Raj,

Yes it works fine for me. The attachment has only the entities that I modified. 1) The TestThing and the 2) test mashup. Import the Thing first and then the mashup and keep the other entities you created in the Project. Ensure you have backup of your project before you replace your entities with mine. Let me know if you face any issue.

anyway I have created at my local Thanks!!

just an another error i am getting on mashup log.  while loading any grid. Please let me know if you have any solution

11:24:06 ERROR - An error occurred while calling dhxgrid::afterRender, Id = "dhxgrid-1". Exception: list.split is not a function

jdass
12-Amethyst
(To:RN_8282441)

Raj ,

Are you using ThingWorx 8.0.2 ?

jdass
12-Amethyst
(To:RN_8282441)

This looks like a bug in the Thingworx 8.0.2 version. It has been reported to R&D. Article Viewer | PTC

Did you try it in different browsers?

Yes i have tried with different browser but getting same error.

when I debugged then i found file Combined.8.0.0-b11.20170607.102535.00903.js    line no- 8407 splitting array of grid info with list.split(","); function where its an array of object.

  1. 0:{name: "No", label: "No", width: "100", align: "left", sortable: false, …}
  2. 1:{name: "Value", label: "Value", width: "100", align: "left", sortable: false, …}

This issue is still persist in ThingWorx 8.0.0-b11

Top Tags