fix: for rollback
This commit is contained in:
parent
bd4ce3ac45
commit
fba305020b
@ -51,6 +51,7 @@
|
|||||||
let rollbackVersion = localStorage.getItem('lastVersion');
|
let rollbackVersion = localStorage.getItem('lastVersion');
|
||||||
|
|
||||||
async function rollback() {
|
async function rollback() {
|
||||||
|
if (rollbackVersion) {
|
||||||
const sure = confirm(`Are you sure you want rollback Coolify to ${rollbackVersion}?`);
|
const sure = confirm(`Are you sure you want rollback Coolify to ${rollbackVersion}?`);
|
||||||
if (sure) {
|
if (sure) {
|
||||||
try {
|
try {
|
||||||
@ -92,6 +93,7 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
async function removeFqdn() {
|
async function removeFqdn() {
|
||||||
if (fqdn) {
|
if (fqdn) {
|
||||||
loading.remove = true;
|
loading.remove = true;
|
||||||
@ -361,7 +363,7 @@
|
|||||||
Rollback to a specific version
|
Rollback to a specific version
|
||||||
<Explainer
|
<Explainer
|
||||||
position="dropdown-bottom"
|
position="dropdown-bottom"
|
||||||
explanation="You can rollback to a specific version of your application. This will not affect your current running resources. <a href='https://github.com/coollabsio/coolify/releases' target='_blank'>See available versions</a>"
|
explanation="You can rollback to a specific version of Coolify. This will not affect your current running resources.<br><br><a href='https://github.com/coollabsio/coolify/releases' target='_blank'>See available versions</a>"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
<input
|
<input
|
||||||
@ -369,10 +371,12 @@
|
|||||||
bind:value={rollbackVersion}
|
bind:value={rollbackVersion}
|
||||||
readonly={!$appSession.isAdmin}
|
readonly={!$appSession.isAdmin}
|
||||||
disabled={!$appSession.isAdmin}
|
disabled={!$appSession.isAdmin}
|
||||||
name="lastVersion"
|
name="rollbackVersion"
|
||||||
id="lastVersion"
|
id="rollbackVersion"
|
||||||
/>
|
/>
|
||||||
<button class="btn btn-primary ml-2" on:click|preventDefault|stopPropagation={rollback}>Rollback</button>
|
<button class="btn btn-primary ml-2" disabled={!rollbackVersion} on:click|preventDefault|stopPropagation={rollback}
|
||||||
|
>Rollback</button
|
||||||
|
>
|
||||||
</div>
|
</div>
|
||||||
<div class="grid grid-cols-2 items-center">
|
<div class="grid grid-cols-2 items-center">
|
||||||
<div>
|
<div>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user