Page Menu
Home
Software Heritage
Search
Configure Global Search
Log In
Files
F7066267
D6190.id22426.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
4 KB
Subscribers
None
D6190.id22426.diff
View Options
diff --git a/swh/web/templates/includes/show-metadata.html b/swh/web/templates/includes/show-metadata.html
--- a/swh/web/templates/includes/show-metadata.html
+++ b/swh/web/templates/includes/show-metadata.html
@@ -12,7 +12,7 @@
<button id="swh-metadata-toggler" class="btn btn-default btn-sm swh-popover-toggler"
data-toggle="popover" data-popover-content="#swh-metadata-popover">
<i class="mdi mdi-table mdi-fw" aria-hidden="true"></i>
- Show metadata
+ Show intrinsic metadata
</button>
<div id="swh-metadata-popover" style="display:none;">
@@ -24,6 +24,25 @@
{% endif %}
+{% if user.is_staff %}
+ {% if swhids_info %}
+ <div class="btn-group">
+ <button class="btn btn-default btn-sm dropdown-toggle" type="button" data-toggle="dropdown">
+ <i class="mdi mdi-table mdi-fw" aria-hidden="true"></i>
+ Browse extrinsic metadata
+ </button>
+ <div class="dropdown-menu swh-extrinsic-metadata-menu">
+ {% for swhid_info in swhids_info %}
+ <a href="{% url 'api-1-raw-extrinsic-metadata-swhid-authorities' swhid_info.swhid %}" class="dropdown-item" role="button">
+ <i class="{{ swh_object_icons|key_value:swhid_info.object_type }} mdi-fw" aria-hidden="true"></i>
+ {{swhid_info.object_type}}
+ </a>
+ {% endfor %}
+ </div>
+ </div>
+ {% endif %}
+{% endif %}
+
<script>
swh.webapp.setBrowsedSwhObjectMetadata({{ swh_object_metadata|jsonify }})
</script>
diff --git a/swh/web/templates/includes/vault-create-tasks.html b/swh/web/templates/includes/vault-create-tasks.html
--- a/swh/web/templates/includes/vault-create-tasks.html
+++ b/swh/web/templates/includes/vault-create-tasks.html
@@ -9,29 +9,32 @@
{% if vault_cooking %}
{% if user.is_staff %}
- <button class="btn btn-default btn-sm dropdown-toggle swh-vault-download" type="button" data-toggle="dropdown">
- <i class="mdi mdi-download mdi-fw" aria-hidden="true"></i>
- Download
- </button>
- <div class="dropdown-menu swh-vault-menu">
- {% if vault_cooking.directory_context %}
- <button class="dropdown-item" type="button" tabindex="-1" onclick="swh.vault.vaultRequest('directory', '{{ vault_cooking.directory_swhid }}')">
- <i class="{{ swh_object_icons.directory }} mdi-fw" aria-hidden="true"></i>
- as tarball
- </button>
- {% endif %}
- {% if vault_cooking.revision_context %}
- <button class="dropdown-item" type="button" tabindex="-1" onclick="swh.vault.vaultRequest('revision', '{{ vault_cooking.revision_swhid }}')">
- <i class="{{ swh_object_icons.revision }} mdi-fw" aria-hidden="true"></i>
- as git
- </button>
- {% endif %}
- </div>
- {% else %}
- <button class="btn btn-default btn-sm swh-vault-download" type="button" onclick="swh.vault.vaultRequest('directory', '{{ vault_cooking.directory_swhid }}')">
- <i class="mdi mdi-download mdi-fw" aria-hidden="true"></i>
- Download
- </button>
+ <div class="btn-group">
+ <button class="btn btn-default btn-sm dropdown-toggle swh-vault-download" type="button" data-toggle="dropdown">
+ <i class="mdi mdi-download mdi-fw" aria-hidden="true"></i>
+ Download
+ </button>
+ <div class="btn-group">
+ <div class="dropdown-menu swh-vault-menu">
+ {% if vault_cooking.directory_context %}
+ <button class="dropdown-item" type="button" tabindex="-1" onclick="swh.vault.vaultRequest('directory', '{{ vault_cooking.directory_swhid }}')">
+ <i class="{{ swh_object_icons.directory }} mdi-fw" aria-hidden="true"></i>
+ as tarball
+ </button>
+ {% endif %}
+ {% if vault_cooking.revision_context %}
+ <button class="dropdown-item" type="button" tabindex="-1" onclick="swh.vault.vaultRequest('revision', '{{ vault_cooking.revision_swhid }}')">
+ <i class="{{ swh_object_icons.revision }} mdi-fw" aria-hidden="true"></i>
+ as git
+ </button>
+ {% endif %}
+ </div>
+ </div>
+ {% else %}
+ <button class="btn btn-default btn-sm swh-vault-download" type="button" onclick="swh.vault.vaultRequest('directory', '{{ vault_cooking.directory_swhid }}')">
+ <i class="mdi mdi-download mdi-fw" aria-hidden="true"></i>
+ Download
+ </button>
{% endif %}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Nov 5 2024, 4:22 AM (8 w, 4 d ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
3225745
Attached To
D6190: Add link to extrinsic metadata API from the browse view
Event Timeline
Log In to Comment