mirror of
https://github.com/rstrouse/ESPSomfy-RTS.git
synced 2025-12-13 02:52:11 +01:00
Do not allow application updates to be cancelled.
This commit is contained in:
parent
8bdfd214b5
commit
234f9d9eb5
8 changed files with 21 additions and 13 deletions
|
|
@ -3,11 +3,11 @@
|
|||
<head>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<meta charset="UTF-8">
|
||||
<link rel="stylesheet" href="main.css?v=2.3.2b" type="text/css" />
|
||||
<link rel="stylesheet" href="widgets.css?v=2.3.2b" type="text/css" />
|
||||
<link rel="stylesheet" href="icons.css?v=2.3.2b" type="text/css" />
|
||||
<link rel="stylesheet" href="main.css?v=2.3.2c" type="text/css" />
|
||||
<link rel="stylesheet" href="widgets.css?v=2.3.2c" type="text/css" />
|
||||
<link rel="stylesheet" href="icons.css?v=2.3.2c" type="text/css" />
|
||||
<link rel="icon" type="image/png" href="favicon.png" />
|
||||
<script type="text/javascript" src="index.js?v=2.3.2b"></script>
|
||||
<script type="text/javascript" src="index.js?v=2.3.2c"></script>
|
||||
</head>
|
||||
<body>
|
||||
<div id="divContainer" class="container main" data-auth="false">
|
||||
|
|
|
|||
|
|
@ -4277,6 +4277,9 @@ class Firmware {
|
|||
// Update the status on the client that started the install.
|
||||
if (pct >= 100 && prog.part === 100) git.remove();
|
||||
else {
|
||||
if (prog.part === 100) {
|
||||
document.getElementById('btnCancelUpdate').style.display = 'none';
|
||||
}
|
||||
let p = prog.part === 100 ? document.getElementById('progApplicationDownload') : document.getElementById('progFirmwareDownload');
|
||||
if (p) {
|
||||
p.style.setProperty('--progress', `${pct}%`);
|
||||
|
|
@ -4306,7 +4309,7 @@ class Firmware {
|
|||
else {
|
||||
general.reloadApp = true;
|
||||
// Change the display and allow the percentage to be shown when the socket emits the progress.
|
||||
let html = `<div>Installing ${ver.name}</div><div style="font-size:.7em;margin-top:4px;">Please wait as the files are downloaded and installed.</div>`;
|
||||
let html = `<div>Installing ${ver.name}</div><div style="font-size:.7em;margin-top:4px;">Please wait as the files are downloaded and installed. Once the application update process starts you may no longer cancel the update as this will corrupt the downloaded files.</div>`;
|
||||
html += `<div class="progress-bar" id="progFirmwareDownload" style="--progress:0%;margin-top:10px;text-align:center;"></div>`;
|
||||
html += `<label for="progFirmwareDownload" style="font-size:10pt;">Firmware Install Progress</label>`;
|
||||
html += `<div class="progress-bar" id="progApplicationDownload" style="--progress:0%;margin-top:10px;text-align:center;"></div>`;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue