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

Chip Based Data Filter Widget

mpaisley90
7-Bedrock

Chip Based Data Filter Widget

Can someone show me how to build the Service we are supposed to put the query into for this filter widget to work. I have a service that brings the data back from the SQL server. But I do not understand the QueryFilter property to the query input parameter of the QueryDataTableEntries service in this reading.

 

https://support.ptc.com/help/thingworx/platform/r9/en/index.html#page/ThingWorx/Help/Mashup_Builder/Widgets/Grid_SortingAndFilteringTheGridData.html 

 

Please send or help if you can thanks.

 

 

3 REPLIES 3
PaiChung
22-Sapphire I
(To:mpaisley90)

I think nowadays in the mashup builder if you click on it, doesn't it provide some ui to build the query? (sorry its been a while)

Else it needs to be a json: https://support.ptc.com/help/thingworx/platform/r9/en/index.html#page/ThingWorx/Help/Composer/Things/ThingServices/QueryParameterforQueryServices.html

 

This would be for the new Chip Based Data Filter widget I have watched the videos and read the documents but it does not show how to bind that query to the service to make it work. I just wanted to see a service where it has the input of query and how it works. I can get the data and bring it to the grid advanced and everything I just wanted to let the users be able to filter the data with this chip-based data filter widget.

 

 

I have a service where I create an infotable from a \query to SQL database. 

 

var dt ;



//pull data off of the database table Get Cooker Historical Data based on passed in parameters

dt = Things["LOL.ThingWorxLOL_Prod_DB_Connection.DB"].Get_Cooker_Data({
Start_Date: Start_Date /* DATETIME */,
End_date: End_Date /* DATETIME */
});



me.Infotable = dt;

 

 

This brings me back the data I need from Start_Date to End_Date.

 

Can someone help me add a query filter that I can receive from the Chip Based Data Filter Widget please as I cannot figure out this query filter option? 

I would be greatly appreciative.

 

 

 

 

Announcements


Top Tags