mirror of
https://github.com/sle118/squeezelite-esp32.git
synced 2025-12-06 19:47:02 +03:00
Fix build issue - release
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
idf_component_register(SRC_DIRS .
|
||||
INCLUDE_DIRS .
|
||||
INCLUDE_DIRS . ${IDF_PATH}/components/driver
|
||||
REQUIRES json tools platform_config display
|
||||
|
||||
)
|
||||
|
||||
@@ -65,7 +65,17 @@ var RefreshAPIIntervalActive = false;
|
||||
var LastRecoveryState=null;
|
||||
var LastCommandsState=null;
|
||||
var output = '';
|
||||
function delay_msg(t, v) {
|
||||
return new Promise(function(resolve) {
|
||||
setTimeout(resolve.bind(null, v), t)
|
||||
});
|
||||
}
|
||||
|
||||
Promise.prototype.delay = function(t) {
|
||||
return this.then(function(v) {
|
||||
return delay_msg(t, v);
|
||||
});
|
||||
}
|
||||
function stopCheckStatusInterval(){
|
||||
if(checkStatusInterval != null){
|
||||
clearTimeout(checkStatusInterval);
|
||||
@@ -1096,7 +1106,10 @@ function runCommand(button,reboot) {
|
||||
},
|
||||
complete: function(response) {
|
||||
console.log('reboot call completed');
|
||||
Promise.resolve().delay(5000).then(function(v) {
|
||||
console.log('Getting updated commands');
|
||||
getCommands();
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
@@ -1177,7 +1190,7 @@ function getCommands() {
|
||||
}
|
||||
else {
|
||||
advancedtabhtml+='<br>'+innerhtml;
|
||||
advancedtabhtml+='<div class="buttons"><input id="btn-'+ command.name + '" type="button" class="btn btn-danger btn-sm" cmdname="'+command.name+'" value="'+command.name+'" onclick="runCommand(this);"></div></div><td></tr>';
|
||||
advancedtabhtml+='<div class="buttons"><input id="btn-'+ command.name + '" type="button" class="btn btn-danger btn-sm" cmdname="'+command.name+'" value="'+command.name+'" onclick="runCommand(this, false);"></div></div><td></tr>';
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user