diff --git a/cypress/integration/origin-search.spec.js b/cypress/integration/origin-search.spec.js --- a/cypress/integration/origin-search.spec.js +++ b/cypress/integration/origin-search.spec.js @@ -65,7 +65,7 @@ .find('i') .should('have.class', 'mdi-check-bold') .and('have.attr', 'title', - 'Origin has at least one full visit by Software Heritage'); + 'Software origin has been archived by Software Heritage'); }); it('should show not found message when no repo matches', function() { diff --git a/swh/web/assets/src/bundles/browse/origin-search.js b/swh/web/assets/src/bundles/browse/origin-search.js --- a/swh/web/assets/src/bundles/browse/origin-search.js +++ b/swh/web/assets/src/bundles/browse/origin-search.js @@ -36,10 +36,19 @@ let table = $('#origin-search-results tbody'); for (let [i, origin] of origins.entries()) { let browseUrl = `${Urls.browse_origin()}?origin_url=${origin.url}`; - let tableRow = ``; - tableRow += `${encodeURI(origin.url)}`; - tableRow += ``; - tableRow += ``; + let tableRow = + ``; + tableRow += + `` + + '' + + 'Checking'; + tableRow += + '' + + `${encodeURI(origin.url)}`; + tableRow += + `` + + '' + + 'Checking'; tableRow += ''; table.append(tableRow); // get async latest visit snapshot and update visit status icon @@ -48,12 +57,16 @@ fetch(latestSnapshotUrl) .then(response => response.json()) .then(data => { - $(`#visit-type-origin-${i}`).text(data.type); + $(`#visit-type-origin-${i}`).html(data.type); $(`#visit-status-origin-${i}`).children().remove(); if (data) { - $(`#visit-status-origin-${i}`).append(''); + $(`#visit-status-origin-${i}`).html( + 'Archived'); } else { - $(`#visit-status-origin-${i}`).append(''); + $(`#visit-status-origin-${i}`).html( + 'Pending archival'); if ($('#swh-filter-empty-visits').prop('checked')) { $(`#origin-${i}`).remove(); } diff --git a/swh/web/templates/browse/search.html b/swh/web/templates/browse/search.html --- a/swh/web/templates/browse/search.html +++ b/swh/web/templates/browse/search.html @@ -1,7 +1,7 @@ {% extends "./layout.html" %} {% comment %} -Copyright (C) 2017-2019 The Software Heritage developers +Copyright (C) 2017-2020 The Software Heritage developers See the AUTHORS file at the top-level directory of this distribution License: GNU Affero General Public License version 3, or any later version See top-level LICENSE file for more information @@ -22,9 +22,9 @@ + - - +
Origin type Origin urlVisit typeVisit statusArchiving status