Skip to content

Commit

Permalink
Feat - Testing implementation of text box in index html
Browse files Browse the repository at this point in the history
  • Loading branch information
davidusb-geek committed Mar 16, 2023
1 parent bfdc3b4 commit 0252ec0
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions src/emhass/templates/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,10 @@ <h4 style="font-family: Helvetica;color: darkblue;">Use the buttons below to fit
<button type="button" id="forecast-model-fit" class="button button1" >ML forecast model fit</button>
<button type="button" id="forecast-model-predict" class="button button2" >ML forecast model predict</button>
<button type="button" id="forecast-model-tune" class="button button3" >ML forecast model tune</button>
<<!-- h4 style="font-family: Helvetica;color: darkblue;">Pass any needed data dictionary here</h4>
<div class="input-group">
<textarea id="runtimeparams" name="runtimeparams" rows="6" cols="65"></textarea>
</div> -->
<br>
</form>
<br><br>
Expand Down Expand Up @@ -87,6 +91,23 @@ <h4 style="font-family: Helvetica;color: darkblue;">Use the buttons below to fit
$.ajax(settings).done(function (response) {
});
});
// document.getElementById('forecast-model-fit').addEventListener('click', function() {
// var formData = $("runtimeparams").serialize();
// // send ajax
// $.ajax({
// url: "/action/forecast-model-fit",
// type : "POST",
// contentType : "application/json;charset=UTF-8",
// dataType : 'json',
// data : formData,
// success : function(result) {
// console.log(result);
// },
// error: function(xhr, resp, text) {
// console.log(xhr, resp, text);
// }
// })
// });
document.getElementById('forecast-model-fit').addEventListener('click', function() {
var url = "/action/forecast-model-fit"
var settings = {
Expand Down

0 comments on commit 0252ec0

Please sign in to comment.