ClearFoundation Tracker - ClearOS
View Issue Details
0003391ClearOSclearos-frameworkpublic2015-07-08 15:092015-07-28 13:55
user2 
user2 
normalfeaturehave not tried
closedfixed 
 
7.1.0 Beta 37.1.0 Beta 3 
0003391: Clean up clearos_chart in preparation for non-report widgets
The "clearos_chart()" javascript function in the theme was the product of the migration from ClearOS 6 to 7. It is currently only used by the Reports driver, but it should be usable by other apps too. Notably:

- Two Kaspersky apps use standalone charts
- Dashboard widgets

The current function should be tweaked and documented to make it easier for app developers.
No tags attached.
related to 0003381closed  Clean up clearos_chart in preparation for non-report widgets 
related to 0003371closed user2 Clean up clearos_chart in preparation for non-report widgets 
Issue History
2015-07-08 15:09user2New Issue
2015-07-08 15:09user2Issue generated from: 0003381
2015-07-08 15:10user2Statusnew => confirmed
2015-07-08 21:11user2Relationship addedrelated to 0003371
2015-07-08 21:11user2Relationship addedrelated to 0003381
2015-07-09 06:14bchambersNote Added: 0001711
2015-07-12 11:26user2Target Version7.1.0 Beta 3 => 7.1.0 RC1
2015-07-28 13:55user2Target Version7.1.0 RC1 => 7.1.0 Beta 3
2015-07-28 13:55user2Statusconfirmed => resolved
2015-07-28 13:55user2Fixed in Version => 7.1.0 Beta 3
2015-07-28 13:55user2Resolutionopen => fixed
2015-07-28 13:55user2Assigned To => user2
2015-07-28 13:55user2Statusresolved => closed

Notes
(0001711)
bchambers   
2015-07-09 06:13   
Network visualiser also uses a chart. Currently, JS calling jquery object directly.

Would be nice to standardize on Flot library syntax and if themer wants to change graphing engines, they would have to map variables/parameters to the new one, as necessary.

Eg., I should be able to dump this obj into clearos graph function:

series: {
            pie: {
                show: true,
                radius: 1,
                label: {
                    show: true,
                    radius: 3/4,
                    formatter: labelFormatter,
                    threshold: 0.1
                },
            }
        },
        legend: {
            backgroundOpacity: 0
        }

And it should work in Flot, but not necessarily others. This way, we don't have to keep updating the theme if someone needs to add another parameter supported by Flot but not in the convenience/wrapper function.