From a17c73419376d28499815f5e9cf6155d38dd2dac Mon Sep 17 00:00:00 2001 From: micheal Date: Sat, 28 Jan 2023 15:46:53 -1100 Subject: [PATCH] Limit in upgrade only support current top versions. --- .../default/launcher/web_ui/config_update.html | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/code/default/launcher/web_ui/config_update.html b/code/default/launcher/web_ui/config_update.html index 85906cea4b..6f8afdafdd 100644 --- a/code/default/launcher/web_ui/config_update.html +++ b/code/default/launcher/web_ui/config_update.html @@ -392,6 +392,21 @@ } }); } + + var current_version = ""; + var pageRequests = { + 'cmd': 'get_version' + }; + $.ajax({ + type: 'GET', + url: '/config', + data: pageRequests, + dataType: 'JSON', + success: function (result) { + current_version = result['current_version']; + } + }); + function get_releasedversions() { $.ajax({ type: 'GET', @@ -402,6 +417,9 @@ for (var i in result) { var ver = result[i]['tag_name']; + if ( ver[0] != current_version[0]) { + continue; + } var new_option = document.getElementById("released-versions-selector").appendChild(document.createElement("option")); new_option.value = ver; new_option.text = ver;