Skip to content

Commit f8cfa7d

Browse files
authored
Merge pull request #94 from mroberge/clean-menu-items
fix menu options
2 parents 5151825 + 6fa1aad commit f8cfa7d

File tree

2 files changed

+3
-25
lines changed

2 files changed

+3
-25
lines changed

index.html

Lines changed: 1 addition & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,6 @@
2525

2626
<!-- my graphing stuff here -->
2727
<script src="src/graph-flowduration.js"></script>
28-
<script src="src/graph-hydrograph.js"></script>
29-
<script src="src/graph-hyetograph.js"></script>
30-
<script src="src/graph-loghistogram.js"></script>
3128
<script src="src/graph-scatterChart.js"></script>
3229

3330
<!-- Local Storage functions -->
@@ -247,25 +244,15 @@
247244
<a href="#" class="dropdown-toggle" data-toggle="dropdown">Graph <b class="caret"> </b></a>
248245
<ul class="dropdown-menu">
249246
<li>
250-
<a href="#" data-bind="click: hydro">Hydrograph</a>
247+
<a href="#" data-bind="click: scatter">Hydrograph</a>
251248
</li>
252249
<li>
253250
<a href="#" data-bind="click: flow">Flow Duration</a>
254251
</li>
255-
<li>
256-
<a href="#" data-bind="click: histo">Histogram</a>
257-
</li>
258-
<li>
259-
<a href="#" data-bind="click: hyeto">Hyetograph</a>
260-
</li>
261-
<li>
262-
<a href="#" data-bind="click: scatter">Scatter</a>
263-
</li>
264252
<li class="divider"></li>
265253
<li>
266254
<a href="#" data-bind="click: toggleLegend">Show Legend</a>
267255
</li>
268-
269256
</ul>
270257
</li>
271258
<li data-target="#carousel-example-generic" data-slide-to="2">

src/viewModel.js

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -52,21 +52,12 @@ var viewModel = {
5252
},
5353
plotGraph : function() {
5454
console.log(this.graph());
55-
if (this.graph() == "hydro") {
56-
hydrograph(this.siteId());
57-
} else if (this.graph() === "flow") {
55+
if (this.graph() === "flow") {
5856
flowduration(this.siteId());
59-
} else if (this.graph() === "histo") {
60-
loghistogram(this.siteId());
61-
} else if (this.graph() === "hyeto") {
62-
hyetograph(this.siteId());
6357
} else if (this.graph() === "scatter") {
6458
var graphDiv = d3.select("#graph_div");
65-
//console.log(this.dataArray());
66-
//fourthChart.datum(dataArray());
6759
d3.select("#graph_div svg").remove();
6860
graphDiv.datum(this.dataArray()).call(fourthChart);
69-
//scatterChart();
7061
} else {
7162
console.log("no option selected");
7263
}
@@ -76,7 +67,7 @@ var viewModel = {
7667
siteName : ko.observable(),
7768
siteDict : ko.observableArray(),
7869
dataArray : ko.observableArray([]),//Initial value set to empty.
79-
tuNexrad : ko.observable({status: "requesting data"}) //just a single object, which happens to be an array...
70+
tuNexrad : ko.observable({status: "requesting data"})
8071
};
8172

8273

0 commit comments

Comments
 (0)