mirror of
https://github.com/home-assistant/frontend.git
synced 2025-07-16 13:56:35 +00:00
Create error when trying to backup wile system in freeze (#11634)
Co-authored-by: Bram Kragten <mail@bramkragten.nl>
This commit is contained in:
parent
830b449006
commit
92a9ed7080
@ -192,13 +192,7 @@ class UpdateAvailableCard extends LitElement {
|
|||||||
</a>`
|
</a>`
|
||||||
: ""}
|
: ""}
|
||||||
<span></span>
|
<span></span>
|
||||||
<ha-progress-button
|
<ha-progress-button @click=${this._update} raised>
|
||||||
.disabled=${!this._version ||
|
|
||||||
(this._shouldCreateBackup &&
|
|
||||||
this.supervisor.info?.state !== "running")}
|
|
||||||
@click=${this._update}
|
|
||||||
raised
|
|
||||||
>
|
|
||||||
${this.supervisor.localize("common.update")}
|
${this.supervisor.localize("common.update")}
|
||||||
</ha-progress-button>
|
</ha-progress-button>
|
||||||
</div>
|
</div>
|
||||||
@ -360,8 +354,14 @@ class UpdateAvailableCard extends LitElement {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private async _update() {
|
private async _update() {
|
||||||
|
if (this._shouldCreateBackup && this.supervisor.info.state === "freeze") {
|
||||||
|
this._error = this.supervisor.localize("backup.backup_already_running");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
this._error = undefined;
|
this._error = undefined;
|
||||||
this._updating = true;
|
this._updating = true;
|
||||||
|
|
||||||
try {
|
try {
|
||||||
if (this._updateType === "addon") {
|
if (this._updateType === "addon") {
|
||||||
await updateHassioAddon(
|
await updateHassioAddon(
|
||||||
|
@ -4514,7 +4514,8 @@
|
|||||||
"confirm_password": "Confirm backup password",
|
"confirm_password": "Confirm backup password",
|
||||||
"password_protection": "Password protection",
|
"password_protection": "Password protection",
|
||||||
"enter_password": "Please enter a password.",
|
"enter_password": "Please enter a password.",
|
||||||
"passwords_not_matching": "The passwords does not match"
|
"passwords_not_matching": "The passwords does not match",
|
||||||
|
"backup_already_running": "A backup or restore is already running, creating a new backup is currently not possible, try again later."
|
||||||
},
|
},
|
||||||
"dialog": {
|
"dialog": {
|
||||||
"network": {
|
"network": {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user