HomePhorge

Separate chart functions into a class tree

Description

Separate chart functions into a class tree

Summary:
Depends on D20440. Ref T13279. Create a class to represent a chartable function: something we can get some data points out of.

Then, make the chart chart two functions.

For now, the only supported function is "fact(key)", which pulls data from the Facts ETL pipeline, identified by "key", and takes no other arguments.

In future changes, I plan to support things like "fact(tasks.open.project, PHID-PROJ-xyz)", "constant(1000)" (e.g. to draw a goal line), "sum(fact(...), fact(...))" (to combine data from several projects), and so on.

The UI may not expose this level of power for a while (or maybe ever) but until we get close enough to the UI that these features are a ton of extra work I'm going to try to keep things fairly flexible/modular.

Test Plan: {F6382286}

Reviewers: amckinley

Reviewed By: amckinley

Subscribers: yelirekim

Maniphest Tasks: T13279

Differential Revision: https://secure.phabricator.com/D20441

Details

Provenance
epriestleyAuthored on Apr 17 2019, 5:15 AM
themackabuPushed on Mar 25 2025, 8:07 PM
Parents
rP45b3c23148d0: Fetch chart data via async request and redraw charts when the window is resized
Branches
Unknown
Tags
Unknown

Event Timeline