Page Menu
Home
Software Heritage
Search
Configure Global Search
Log In
Files
F9337276
D6175.id22387.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
3 KB
Subscribers
None
D6175.id22387.diff
View Options
diff --git a/assets/src/bundles/vault/vault-table-row.ejs b/assets/src/bundles/vault/vault-table-row.ejs
--- a/assets/src/bundles/vault/vault-table-row.ejs
+++ b/assets/src/bundles/vault/vault-table-row.ejs
@@ -5,7 +5,7 @@
See top-level LICENSE file for more information
%>
-<% if (cookingTask.object_type === 'directory') { %>
+<% if (cookingTask.swhid.match(/^swh:1:dir:.*/)) { %>
<tr id="vault-task-<%= cookingTask.swhid %>"
title="Once downloaded, the directory can be extracted with the following command:
@@ -36,8 +36,8 @@
<td class="vault-origin">unknown</td>
<% } %>
<td>
- <i class="<%= swh.webapp.getSwhObjectIcon(cookingTask.object_type) %> mdi-fw"></i>
- <%= cookingTask.object_type %>
+ <i class="<%= swh.webapp.getSwhObjectIcon(cookingTask.swhid.match(/swh:1:([a-z]+):/)[1]) %> mdi-fw"></i>
+ <%= cookingTask.bundle_type %>
</td>
<td class="vault-object-info" data-swhid="<%= cookingTask.swhid %>">
<b>id:</b> <a href="<%= browseUrl %>"><%= cookingTask.swhid %></a>
diff --git a/cypress/integration/vault.spec.js b/cypress/integration/vault.spec.js
--- a/cypress/integration/vault.spec.js
+++ b/cypress/integration/vault.spec.js
@@ -268,6 +268,10 @@
.should('have.text', this.directory)
.should('have.attr', 'href', browseDirectoryUrl);
+ cy.get(`#vault-task-${CSS.escape(this.directory)}`)
+ .invoke('attr', 'title')
+ .should('contain', 'the directory can be extracted');
+
cy.get(`#vault-task-${CSS.escape(this.directory)} .vault-dl-link button`)
.click();
@@ -352,6 +356,10 @@
.should('have.text', this.revision)
.should('have.attr', 'href', browseRevisionUrl);
+ cy.get(`#vault-task-${CSS.escape(this.revision)}`)
+ .invoke('attr', 'title')
+ .should('contain', 'the git repository can be imported');
+
cy.get(`#vault-task-${CSS.escape(this.revision)} .vault-dl-link button`)
.click();
diff --git a/swh/web/common/utils.py b/swh/web/common/utils.py
--- a/swh/web/common/utils.py
+++ b/swh/web/common/utils.py
@@ -34,14 +34,20 @@
"branch": "mdi mdi-source-branch",
"branches": "mdi mdi-source-branch",
"content": "mdi mdi-file-document",
+ "cnt": "mdi mdi-file-document",
"directory": "mdi mdi-folder",
+ "dir": "mdi mdi-folder",
"origin": "mdi mdi-source-repository",
+ "ori": "mdi mdi-source-repository",
"person": "mdi mdi-account",
"revisions history": "mdi mdi-history",
"release": "mdi mdi-tag",
+ "rel": "mdi mdi-tag",
"releases": "mdi mdi-tag",
"revision": "mdi mdi-rotate-90 mdi-source-commit",
+ "rev": "mdi mdi-rotate-90 mdi-source-commit",
"snapshot": "mdi mdi-camera",
+ "snp": "mdi mdi-camera",
"visits": "mdi mdi-calendar-month",
}
diff --git a/swh/web/templates/browse/vault-ui.html b/swh/web/templates/browse/vault-ui.html
--- a/swh/web/templates/browse/vault-ui.html
+++ b/swh/web/templates/browse/vault-ui.html
@@ -34,7 +34,7 @@
</div>
</th>
<th style="width: 300px">Origin</th>
- <th style="width: 100px">Object type</th>
+ <th style="width: 100px">Bundle type</th>
<th>Object info</th>
<th style="width: 250px">Cooking status</th>
<th style="width: 120px"></th>
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Jul 3 2025, 7:58 AM (10 w, 2 d ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
3224313
Attached To
D6175: vault-ui: Remove remaining references to object_type
Event Timeline
Log In to Comment