Minor diff page improvements - list should be sorted 'newest first' and no need to include the current version to compare against (#716)

pull/720/head
dgtlmoon 2022-06-23 10:16:05 +02:00 zatwierdzone przez GitHub
rodzic 83555a9991
commit dbd9b470d7
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 4AEE18F83AFDEB23
2 zmienionych plików z 2 dodań i 2 usunięć

Wyświetl plik

@ -830,7 +830,7 @@ def changedetection_app(config=None, datastore_o=None):
newest=newest_version_file_contents,
previous=previous_version_file_contents,
extra_stylesheets=extra_stylesheets,
versions=dates[1:],
versions=dates[:-1], # All except current/last
uuid=uuid,
newest_version_timestamp=dates[-1],
current_previous_version=str(previous_version),

Wyświetl plik

@ -22,7 +22,7 @@
{% if versions|length >= 1 %}
<label for="diff-version">Compare newest (<span id="current-v-date"></span>) with</label>
<select id="diff-version" name="previous_version">
{% for version in versions %}
{% for version in versions|reverse %}
<option value="{{version}}" {% if version== current_previous_version %} selected="" {% endif %}>
{{version}}
</option>