-
-
Notifications
You must be signed in to change notification settings - Fork 828
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
New Feature - Ability to access historical tags in script #1283
New Feature - Ability to access historical tags in script #1283
Conversation
Merge from origin master
Merge from origin master
…dnanebrahimi/FUXA into feature/getHistoricalTagScript
Good work! I'm reviewing your PR. |
Hi, in pr1283 branch I made a few changes, in particular the Date format is not compatible for internationality. |
I will check it. Thank you for the review. |
@unocelli By adding these two lines the dialog will show only historical tags |
I have forgotten, I will add it to the pr. Thanks a lot. |
Describe the feature
This is a missed feature for the script engine to access historical tags in the script.
by accessing historical tags in the script, you can now calculate historical data and show them in the view.
Describe the solution you'd like
Creating a new system function
$getHistoricalTags
that accepts three arguments:Usage:
console.log(await $getHistoricalTags(['t_7b1017a7-10924aca','t_5ed33907-40b642d3'],'2024/06/01 - 00:00:00','2024/06/30 - 23:59:59'));
With this line of code, you will get historical data for June
Or you can get historical data until present time by passing empty string like this:
console.log(await $getHistoricalTags(['t_7b1017a7-10924aca','t_5ed33907-40b642d3'],'2024/06/01 - 00:00:00',''));
Output: