Skip to content

Commit

Permalink
Merge pull request #33 from mcrossley/master
Browse files Browse the repository at this point in the history
- Fixes WLL timestamps always being in UTC, now uses local time
- Adds web tags <#snowlying>, <#snowfalling>, both provide 1|0 responses
- Adds Current Conditions editor to admin interface
- Adds All Time Records editor to admin interface
  • Loading branch information
mcrossley authored Nov 1, 2019
2 parents 3d33df5 + 2089409 commit 9b55a35
Show file tree
Hide file tree
Showing 34 changed files with 16,381 additions and 15,088 deletions.
20 changes: 19 additions & 1 deletion CumulusMX/Api.cs
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ public class EditControllerGet : WebApiController
public EditControllerGet(IHttpContext context) : base(context)
{
}

[WebApiHandler(HttpVerbs.Get, RelativePath + "edit/*")]
public bool EditData()
{
Expand All @@ -121,6 +121,18 @@ public bool EditData()

case "raintoday":
return this.JsonResponse(dataEditor.EditRainToday(this));

case "currentcond.json":
return this.JsonResponse(dataEditor.GetCurrentCond());

case "alltimerecords.json":
return this.JsonResponse(dataEditor.GetAllTimeRecData());

case "alltimerecordsdayfile.json":
return this.JsonResponse(dataEditor.GetAllTimeRecDayFile());

case "alltimerecordslogfile.json":
return this.JsonResponse(dataEditor.GetAllTimeRecLogFile());
}

throw new KeyNotFoundException("Key Not Found: " + lastSegment);
Expand Down Expand Up @@ -173,6 +185,12 @@ public bool EditData()

case "diarydelete":
return this.JsonResponse(dataEditor.DeleteDiary(this));

case "currcond":
return this.JsonResponse(dataEditor.EditCurrentCond(this));

case "alltime":
return this.JsonResponse(dataEditor.EditAllTimeRecs(this));
}

throw new KeyNotFoundException("Key Not Found: " + lastSegment);
Expand Down
Loading

0 comments on commit 9b55a35

Please sign in to comment.