1
0
Fork 0
mirror of https://github.com/retspen/webvirtcloud synced 2026-11-10 20:26:48 +00:00

fix(templates): each delete page says what deleting its object does

The shared delete page asked only whether to delete the object. Each
view now gives its consequence: a deleted compute's VMs keep running
but the panel forgets them and their owners, a deleted user's VMs
stay, a group's members keep their accounts, a VM's owner loses only
the access, a removed VM's record no longer brings its owners back,
an SSH key stays on the VMs that have it, a flavor only goes as a
size template.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
catborise 2026-10-22 11:02:54 +03:00
parent f9c8c36a6b
commit fbe93d9aee
6 changed files with 54 additions and 7 deletions

View file

@ -6,6 +6,7 @@ from django.http import HttpResponse
from django.shortcuts import get_object_or_404, redirect, render
from django.urls import reverse
from django.utils import timezone
from django.utils.translation import gettext_lazy as _
from instances.models import Instance
from libvirt import libvirtError
from operations import claims
@ -127,7 +128,9 @@ def compute_delete(request, compute_id):
return render(
request,
"common/confirm_delete.html",
{"object": compute},
{"object": compute,
"consequence": _("Its VMs keep running on the host, but the panel forgets them and who owns them; "
"added again, the host's VMs come back without owners.")},
)