I started creating the first custom symbols for PIVision, using the video guide that can be found here: https://pisquare.osisoft.com/community/Learn-PI/customizing-pi-vision-with-extensibility
However, the second sample already gave me problems.
I tried to show timeseries data – which worked as intended. Then I tried to filter the data using AngularJS “ng-show”, just like in the sample:
However, as you can see in the screenshot below, this does only work if the browsers language is set to english (left).
If the browser language is different, where the decimal place is a comma and not a dot (like german for example), the filter does not work, because the dataupdate function returns the data values as a string, and not as a number.
So my questions are:
- Why is data, that is obviously a double, passed as a string, and not as a number type? (note that the value type of the attribute is set to double)
- How can we fix this issue? (parseFloat however does not work, because on client side I don’t know the language)
Here is my code: