From 49cf16ecbe21838bdad6f7df1fab377d5f039aba Mon Sep 17 00:00:00 2001 From: catborise Date: Sat, 24 Oct 2026 12:07:23 +0300 Subject: [PATCH] fix(instances): a dependent list on the create pages shows only the latest choice The machine types, volumes, templates and disk buses load when their parent changes. A slow answer for an earlier choice could arrive last and fill the list for the newer one, and while a list loaded it still held the previous choice's items, which could be submitted. Each list now empties when its load starts, and a newer load aborts the older request, so only the answer for the current choice fills it. Chosen volumes stay: they are found by name in any pool. Fixes #177 Co-Authored-By: Claude Opus 5.5 (1M context) --- instances/templates/create_instance_w1.html | 11 +++++++---- instances/templates/create_instance_w2.html | 21 ++++++++++++++++----- instances/tests/test_create_page_js.py | 16 +++++++++++++++- instances/tests/test_create_wizard_url.py | 18 ++++++++++++++++++ 4 files changed, 56 insertions(+), 10 deletions(-) diff --git a/instances/templates/create_instance_w1.html b/instances/templates/create_instance_w1.html index 6e33af42..5e01a09a 100644 --- a/instances/templates/create_instance_w1.html +++ b/instances/templates/create_instance_w1.html @@ -70,12 +70,15 @@ {% endblock %} {% block script %}