Hi, I am able to ingest data in time series datastore (by using modbus/websocket river). I verified that by querying its rest api.
Now, I want to show this data on UI. Please provide some directions. Is there a github UI app which is already integrated with time series service , which I can download and modify to include my time series service instance and datapoints.
I could not find any clear directions on UI and time series service integration.
Thanks Ritesh
Hi Ritesh,
I was trying to call timeseries api from my application ui but i am getting an error like this "How to solve - No ‘Access-Control-Allow-Origin’ header is present on the requested resource. Origin ‘null’ is therefore not allowed access".
I just want to ask you that do you have any information to solve this because you have already tried this.
To avoid Access-Control-Allow-Origin errors you should proxy requests through your web server. Your browser makes the request to the web server, and the web server adds the authentication token, then proxies the request to the back end service. This is how the predix-webapp-starter works.
Answer by Greg Stroup · Jun 01, 2016 at 09:49 AM
This set of tutorials should help you. The very last tutorial shows an example of displaying time series data in the web UI. It's using a 3rd party component called chart.js, not the px-chart component. (In the future, we'll probably update this tutorial to use px-chart.) Anyway, the concept is the same. Call the time series REST API, get the response, tweak it for display, then display on the chart. The predix-seed has sample code using the px-chart component.
Thanks @Greg for your response. I knew about that app, its talking to timeseries via wind series using time series SDK. I tried to modfiy it to directly call TS api but it didn't work
Is there an example where we are directly calling time series rest api's from any UI app? In predix-seed, could you please point me to the file where we are actually calling time series api's.
Appreciate your response.
Thanks Ritesh
The predix-seed app loads sample data from JSON files:
The RMD Reference App calls the real Time Series API:
https://github.com/PredixDev/rmd-ref-app-cards/blob/master/rmd-ref-app-ts-card.html
Hi Greg,
The both link not working as you mentioned above. I am facing same issue like : Display time series data on UI
Hi @hv00127867@techmahindra.com,
maybe this post can help you
Those links are stale now, since the code has changed quite a bit in the last year. The best approach for you is to take a look at the predix-seed application. A tutorial on this topic should be coming soon. For now, take a look at this file: https://github.com/PredixDev/predix-seed/blob/master/public/elements/seed-app/seed-app.html You can uncomment the nav item for "wind data", then look at the winddata-view.html file in the views directory for some example code.
Data Query implementation in the UI seed app via View-Service and Timeseries 1 Answer
404 Error: Cannot POST (Loopback) 2 Answers
Setting up the Dashboard Seed project: bower error 4 Answers
Any suggestions for Dashboard Layout in predix 1 Answer
Predix Machine can't connect to the cloud via Proxy 3 Answers