Skip to content

Commit

Permalink
fix date passing to getstatus, remove debugging
Browse files Browse the repository at this point in the history
  • Loading branch information
instanttim committed Oct 29, 2015
1 parent 1de90a5 commit f862585
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 12 deletions.
15 changes: 4 additions & 11 deletions Web Server/getstatus.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,29 +29,22 @@
if (isset($_GET["date"])) {
// TODO: I should verify that the date is properly formatted.
$date = $_GET["date"];
} else if (DEBUG) {
// DEBUG: just always use the same date as today.
$date = "2015-05-05";
}

if (isset($_GET["scope"])) {
// TODO: I should verify that it's an integer in a valid range.
$scope = $_GET["scope"];
}

switch ($_GET["q"]) {
// FIXME: most if not all of these don't work if a date is actually passed in!!
case 'years':
// query_years($date);
query_years();
query_years($date);
break;
case 'months':
// query_months($date);
query_months();
query_months($date);
break;
case 'days':
// query_days($date);
query_days();
query_days($date);
break;
case 'full_day':
query_full_day($date, $scope);
Expand Down
1 change: 0 additions & 1 deletion Web Server/js/charts.js
Original file line number Diff line number Diff line change
Expand Up @@ -448,7 +448,6 @@ function get_cc_input_volts() {

}


function get_cc_input_current() {

/*global deviceLabel, full_day_data */
Expand Down

0 comments on commit f862585

Please sign in to comment.