diff --git a/views/core-edit.hbs b/views/core-edit.hbs deleted file mode 100644 index 16f3ed5..0000000 --- a/views/core-edit.hbs +++ /dev/null @@ -1,24 +0,0 @@ -{{!< default}} - -<div id="form-container" class="container"> - {{#form url class="form-horzontal"}} - - <div class="form-group"> - {{label "deviceName" "Edit Device Name:"}} - {{input "deviceName" coreName class="form-control"}} - {{#if values.0.coreName}} - <p class="bg-info">* Current value is, {{values.0.coreName}}</p> - {{/if}} - </div> - - <div class="form-group"> - {{label "locationDesc" "Edit Location:"}} - {{input "locationDesc" locationDesc class="form-control"}} - {{#if values.0.locationDesc}} - <p class="bg-info">* Current value is, {{values.0.locationDesc}}</p> - {{/if}} - </div> - - {{submit "save" "Save details" class="btn btn-primary"}} - {{/form}} -</div> diff --git a/views/core.hbs b/views/core.hbs deleted file mode 100644 index 4f297fb..0000000 --- a/views/core.hbs +++ /dev/null @@ -1,42 +0,0 @@ -{{!< default}} - -<p> - <b> - {{! Grab 1st coreName value (it will be same value for entire set).}} - {{#if alerts.0.coreName}} - Alerts from Particle Core: {{alerts.0.coreName}} - {{else}} - Alerts from Particle Core: # No Name # - {{/if}} - </b> - - <a href="https://particle.kaplon.us/core/edit/{{alerts.0.coreId}}" class="btn btn-primary">Edit Details</a> - <a href="https://particle.kaplon.us" class="btn btn-primary">Back to Device Listing</a> -</p> - -<table class="table table-striped"> - <thead> - <tr> - <th>Date</th> - <th>Time</th> - <th>Status</th> - </tr> - </thead> - <tbody> - {{#each alerts}} - <tr class="{{this.rowClass}}"> - <td>{{this.pubDate}}</td> - <td>{{this.pubTime}}</td> - <td>{{this.status}}</td> - </tr> - {{/each}} - </tbody> -</table> - -<script> - setTimeout( - function() { - location.reload(); - }, 10000 - ); -</script> diff --git a/views/default.hbs b/views/default.hbs index af6de45..19f1018 100644 --- a/views/default.hbs +++ b/views/default.hbs @@ -14,12 +14,13 @@ <!-- Optional theme --> <!-- <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap-theme.min.css"> --> - <style type="text/css">tr.alert-row {background-color:#FF0000 !important;} </style> + <style type="text/css">.jumbotron.closed {background-color:#FF0000 !important;} </style> + <style type="text/css">.jumbotron.open {background-color:Green !important;} </style> </head> <body class="container-fluid"> <div style="background:#D1E0E0" class="jumbotron"> - <h1 class="text-center">Tennis Courts Open?</h1> + <h1 class="text-center">TT Tennis Courts Are...</h1> </div> {{! Everything else gets inserted here }} diff --git a/views/index.hbs b/views/index.hbs index 118efa5..de4a4f1 100644 --- a/views/index.hbs +++ b/views/index.hbs @@ -1,16 +1,12 @@ {{!< default}} -<h1>TT Tennis Courts Are...</h1> - {{! Index-0 is the most recent message. }} -<div class="jumbotron-{{values.0.statusClass}}"> - <h2>{{values.0.status}}</h2> +<div class="jumbotron {{values.0.statusClass}}"> + <h2 class="text-center">{{values.0.status}}</h2> </div> -<br /> <div> - <h3>Update received: {{values.0.pubDate}}, {{values.0.pubTime}}</h3> + <h3 class="text-center">Update received: {{values.0.pubDate}}, {{values.0.pubTime}}</h3> </div> -<br /> <div> - <h4>Prior update was: {{values.1.status}} at {{values.1.pubDate}}, {{values.1.pubTime}}</h4> + <h4 class="text-center">Prior update was: {{values.1.status}} at {{values.1.pubDate}}, {{values.1.pubTime}}</h4> </div>