Skip to content
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

Feature/dc d3 dynamic charting #250

Merged
merged 23 commits into from
Jul 22, 2015
Merged

Conversation

frenchbread
Copy link
Contributor

No description provided.

@frenchbread
Copy link
Contributor Author

Hey @apinf/developers , please review this PR. #212 - Related issue.

@brylie brylie self-assigned this Jul 20, 2015

var stamp = moment(d._source.request_at);
stamp = stamp.format("YYYY-MM-DD-HH");
d.ymd = dateFormat.parse(stamp);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be changed to some more general label such as timeStamp. timeStamp would correspond with timeStampDimension (line 43) and timeStampGroup (line 46).

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@brylie Time format changed to iso.

};

Template.chartLayout.events({
"submit .filtering" : function(e){
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider using change instead of submit, as that would simplify usability. Also, consider identifying the "filtering" form more explicitly and by ID rather than class, since it will be the only filtering form on the page.

<option value="12">December</option>
</select>
Year:
<select name="year">
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider how this year list could be programatically generated based on available data. Add a follow-up task for a future sprint.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Open a task in the backlog to generate the list of months based on available data for a given year.

</span>

</form>
<div class="sampleChart" id="chart">
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Follow the class name convention from other classes using dashes rather than camel case. Basically, the whole projecct, and certainly a single template, should use a common convention for class names, etc.

@brylie
Copy link
Contributor

brylie commented Jul 21, 2015

@frenchbread check out how to use the change event on your form:

@frenchbread
Copy link
Contributor Author

@apinf/developers This one is done, so please review this PR and merge

@@ -1,49 +1,120 @@
Template.chartLayout.rendered = function () {
Template.lineChart.rendered = function () {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Where is the lineChart.html? Place this rendered function within a corresponding lineChart.js in the same folder. E.g.

/client/views/dashboard/charts/line/lineChart.html
/client/views/dashboard/charts/line/lineChart.js

@frenchbread
Copy link
Contributor Author

Fixed

@@ -0,0 +1,120 @@
Template.lineChart.rendered = function () {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Following your convention, this should go in:

/client/charts/line/line.js

@brylie
Copy link
Contributor

brylie commented Jul 22, 2015

This is getting really close, but still has a few organizational issues.

@frenchbread
Copy link
Contributor Author

How about now?

brylie added a commit that referenced this pull request Jul 22, 2015
@brylie brylie merged commit 6a37d90 into develop Jul 22, 2015
@brylie brylie deleted the feature/dc-d3-dynamic-charting branch July 22, 2015 10:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants