Skip to content

Commit

Permalink
Merge pull request #385 from will-moore/show_fileset_id
Browse files Browse the repository at this point in the history
Show fileset ID
  • Loading branch information
joshmoore authored Aug 6, 2022
2 parents 1523a77 + b757d16 commit 8eabad0
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -355,7 +355,7 @@
{% if not share %}
{% if image.showOriginalFilePaths %}
<!-- show original file paths -->
<button id="show_fs_files_btn" class="btn silver btn_fspath" title="Show file paths on server">
<button id="show_fs_files_btn" class="btn silver btn_fspath" title="Show Fileset ID and file paths on server">
<span></span>
</button>
{% endif %}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -149,11 +149,14 @@
var repo = data.repo,
client = data.client,
html = "";
$panel_title.html(repo.length + " Image file" + (repo.length>1 ? "s:" : ":"));
$panel_title.html("Fileset Info");

html += `<p>Fileset ID: <strong>${data.fileset.id}</strong></p>`

html += `<p>File count: <strong>${repo.length}</strong></p>`

if (importTransfer) {
html += "<p>Imported with <strong>--transfer="+ importTransfer;
html += "</strong></p><hr/>";
html += "<p>Imported with: <strong>--transfer="+ importTransfer + "</strong></p>";
}

html += "<p>Imported from:</p>";
Expand Down
7 changes: 6 additions & 1 deletion omeroweb/webgateway/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -2686,7 +2686,12 @@ def original_file_paths(request, iid, conn=None, **kwargs):
if image is None:
raise Http404
paths = image.getImportedImageFilePaths()
return {"repo": paths["server_paths"], "client": paths["client_paths"]}
fileset_id = image.fileset.id.val
return {
"repo": paths["server_paths"],
"client": paths["client_paths"],
"fileset": {"id": fileset_id},
}


@login_required()
Expand Down

0 comments on commit 8eabad0

Please sign in to comment.