From ab6a4faebe8519d84a10db261cc5f55d23e97f15 Mon Sep 17 00:00:00 2001 From: guerler Date: Thu, 10 Feb 2022 17:59:06 -0500 Subject: [PATCH 01/95] Remove unused import of Set in schema --- lib/galaxy/schema/schema.py | 1 - 1 file changed, 1 deletion(-) diff --git a/lib/galaxy/schema/schema.py b/lib/galaxy/schema/schema.py index 3a22ddf5579..4e323256adb 100644 --- a/lib/galaxy/schema/schema.py +++ b/lib/galaxy/schema/schema.py @@ -9,7 +9,6 @@ from typing import ( Dict, List, Optional, - Set, Union, ) From ccbeecbe007476ebd565311daaa97db5a08e4d8e Mon Sep 17 00:00:00 2001 From: guerler Date: Thu, 10 Feb 2022 20:55:50 -0500 Subject: [PATCH 02/95] Restore infinite-scroller? Test performance of basic api --- client/src/components/History/History.vue | 16 +++++++--------- client/src/components/History/HistoryListing.vue | 2 +- 2 files changed, 8 insertions(+), 10 deletions(-) diff --git a/client/src/components/History/History.vue b/client/src/components/History/History.vue index 171165e7c7a..9cd84d80ee2 100644 --- a/client/src/components/History/History.vue +++ b/client/src/components/History/History.vue @@ -85,7 +85,6 @@ From 00e014255b20426f7dcdb8a814b743bbd51d0f13 Mon Sep 17 00:00:00 2001 From: guerler Date: Sun, 13 Feb 2022 01:43:57 -0500 Subject: [PATCH 09/95] Explicitly load STATES? --- .../History/ContentItem/DatasetCollection/DscMenu.vue | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/client/src/components/History/ContentItem/DatasetCollection/DscMenu.vue b/client/src/components/History/ContentItem/DatasetCollection/DscMenu.vue index b5cf70aedfe..11601a21278 100644 --- a/client/src/components/History/ContentItem/DatasetCollection/DscMenu.vue +++ b/client/src/components/History/ContentItem/DatasetCollection/DscMenu.vue @@ -41,7 +41,7 @@ diff --git a/client/src/components/History/History.vue b/client/src/components/History/History.vue index ceda769e779..ff53a086472 100644 --- a/client/src/components/History/History.vue +++ b/client/src/components/History/History.vue @@ -97,7 +97,7 @@ import ContentOperations from "./ContentOperations"; import ToolHelpModal from "./ToolHelpModal"; import HistoryMenu from "./HistoryMenu"; import HistoryListing from "./HistoryListing"; -import { ContentItem } from "./ContentItem"; +import ContentItem from "./ContentItem/ContentItem"; export default { components: { From bff644e256f15b6f05bb03b01c00cc3bdc970d24 Mon Sep 17 00:00:00 2001 From: guerler Date: Sun, 13 Feb 2022 02:26:21 -0500 Subject: [PATCH 12/95] Remove collection content item, use consolidated content item instead --- .../ContentItem/CollectionContentItem.js | 19 -------- .../History/ContentItem/ContentItem.vue | 46 +++++++++++-------- .../components/History/ContentItem/index.js | 8 ---- .../History/CurrentCollection/Panel.vue | 6 +-- client/src/components/History/README.md | 2 +- 5 files changed, 32 insertions(+), 49 deletions(-) delete mode 100644 client/src/components/History/ContentItem/CollectionContentItem.js delete mode 100644 client/src/components/History/ContentItem/index.js diff --git a/client/src/components/History/ContentItem/CollectionContentItem.js b/client/src/components/History/ContentItem/CollectionContentItem.js deleted file mode 100644 index f6a7f5132c7..00000000000 --- a/client/src/components/History/ContentItem/CollectionContentItem.js +++ /dev/null @@ -1,19 +0,0 @@ -import ContentItem from "./ContentItem"; - -export default { - mixins: [ContentItem], - - computed: { - contentItemComponent() { - const { element_type } = this.item; - switch (element_type) { - case "hda": - return "Subdataset"; - case "hdca": - return "Subcollection"; - default: - return "Placeholder"; - } - }, - }, -}; diff --git a/client/src/components/History/ContentItem/ContentItem.vue b/client/src/components/History/ContentItem/ContentItem.vue index 63c8dbdd483..15d7fe2d41f 100644 --- a/client/src/components/History/ContentItem/ContentItem.vue +++ b/client/src/components/History/ContentItem/ContentItem.vue @@ -26,6 +26,7 @@ * derived from the current component state rather than the data itself. */ +import "./styles.scss"; import Placeholder from "./Placeholder"; import Dataset from "./Dataset"; import DatasetCollection from "./DatasetCollection"; @@ -40,18 +41,30 @@ export default { Subdataset, Subcollection, }, - props: { item: { type: Object, required: true }, index: { type: Number, required: false, default: null }, rowKey: { type: [Number, String], required: false, default: "" }, writable: { type: Boolean, required: false, default: true }, }, - data: () => ({ suppressFocus: true, }), - + computed: { + loading() { + return !this.item; + }, + contentItemComponent() { + if (this.item.id === undefined) { + return "Placeholder"; + } + return this.historyContentItem(); + }, + }, + created() { + this.$root.$on("bv::dropdown::show", () => (this.suppressFocus = true)); + this.$root.$on("bv::dropdown::hide", () => (this.suppressFocus = false)); + }, methods: { setFocus(index) { if (this.suppressFocus) { @@ -63,16 +76,7 @@ export default { el.focus(); } }, - }, - - computed: { - loading() { - return !this.item; - }, - contentItemComponent() { - if (this.item.id === undefined) { - return "Placeholder"; - } + historyContentItem() { const { history_content_type } = this.item; switch (history_content_type) { case "dataset": @@ -83,11 +87,17 @@ export default { return "Placeholder"; } }, - }, - - created() { - this.$root.$on("bv::dropdown::show", () => (this.suppressFocus = true)); - this.$root.$on("bv::dropdown::hide", () => (this.suppressFocus = false)); + collectionContentItem() { + const { element_type } = this.item; + switch (element_type) { + case "hda": + return "Subdataset"; + case "hdca": + return "Subcollection"; + default: + return "Placeholder"; + } + }, }, }; diff --git a/client/src/components/History/ContentItem/index.js b/client/src/components/History/ContentItem/index.js deleted file mode 100644 index 994db0b74e9..00000000000 --- a/client/src/components/History/ContentItem/index.js +++ /dev/null @@ -1,8 +0,0 @@ -/** - * Scrolling components for history contents and collection contents. - */ - -import "./styles.scss"; - -export { default as ContentItem } from "./ContentItem"; -export { default as CollectionContentItem } from "./CollectionContentItem"; diff --git a/client/src/components/History/CurrentCollection/Panel.vue b/client/src/components/History/CurrentCollection/Panel.vue index a4c04898bdd..408dc75fbde 100644 --- a/client/src/components/History/CurrentCollection/Panel.vue +++ b/client/src/components/History/CurrentCollection/Panel.vue @@ -31,7 +31,7 @@ :payload="payload" @scroll="onScroll"> diff --git a/client/src/components/History/ContentItem/ContentItem.vue b/client/src/components/History/ContentItem/ContentItem.vue index 53a851761f7..5d6517cdc03 100644 --- a/client/src/components/History/ContentItem/ContentItem.vue +++ b/client/src/components/History/ContentItem/ContentItem.vue @@ -59,27 +59,17 @@ -
-

{{ name || "(Dataset Name)" }}

-
+ From 9433dbe4a936a58a82574036bd4ac6ec62d9d605 Mon Sep 17 00:00:00 2001 From: guerler Date: Tue, 15 Feb 2022 00:41:18 -0500 Subject: [PATCH 20/95] Modify props without overwriting root dictionary --- client/src/components/History/History.vue | 2 +- client/src/components/History/HistoryListing.vue | 14 ++++++++++++-- 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/client/src/components/History/History.vue b/client/src/components/History/History.vue index d90fe1ce7c6..cc6ce2b212f 100644 --- a/client/src/components/History/History.vue +++ b/client/src/components/History/History.vue @@ -1,5 +1,5 @@ @@ -89,6 +90,7 @@ From 0f2d4a43611f686450e536d09efb8eecb19b37a5 Mon Sep 17 00:00:00 2001 From: guerler Date: Tue, 15 Feb 2022 13:28:41 -0500 Subject: [PATCH 30/95] Fix option visibility in item contents, disable delete when data is purged --- .../History/ContentItem/ContentItem.vue | 46 +++++++++---------- 1 file changed, 23 insertions(+), 23 deletions(-) diff --git a/client/src/components/History/ContentItem/ContentItem.vue b/client/src/components/History/ContentItem/ContentItem.vue index 1b3167fa28a..a32ede0021b 100644 --- a/client/src/components/History/ContentItem/ContentItem.vue +++ b/client/src/components/History/ContentItem/ContentItem.vue @@ -14,25 +14,34 @@ - - - - + :disabled="item.purged" + @click.stop="$emit('undelete', item)"> + + + + + + + +
@@ -71,18 +80,9 @@ export default { writable: { type: Boolean, required: false, default: true }, }, computed: { - loading() { - return !this.item; - }, selectable() { return this.showSelection; }, - visible() { - return this.item.visible; - }, - deleted() { - return this.item.isDeleted && !this.item.purged; - }, clsState() { let state = ContentState[this.item.state] || ContentState[this.item.populated_state]; if (!state || this.selected) { From 6fde44a0c9c22184c803b2e15dfcdd42e544365b Mon Sep 17 00:00:00 2001 From: guerler Date: Tue, 15 Feb 2022 19:06:27 -0500 Subject: [PATCH 31/95] Force word wrapping in item content title --- client/src/components/History/ContentItem/ContentItem.vue | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/client/src/components/History/ContentItem/ContentItem.vue b/client/src/components/History/ContentItem/ContentItem.vue index a32ede0021b..e3c030d09e5 100644 --- a/client/src/components/History/ContentItem/ContentItem.vue +++ b/client/src/components/History/ContentItem/ContentItem.vue @@ -102,4 +102,9 @@ export default { .content-item:hover { filter: brightness(105%); } +.content-item { + .name { + word-wrap: break-word; + } +} From 1fb17d0c96230d4a85410fe88c63aa672b9db995 Mon Sep 17 00:00:00 2001 From: guerler Date: Tue, 15 Feb 2022 19:30:28 -0500 Subject: [PATCH 32/95] Add support to unhide and undelete datasets, place in history component for now --- .../components/History/ContentItem/ContentItem.vue | 2 +- client/src/components/History/History.vue | 14 ++++++++++++-- 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/client/src/components/History/ContentItem/ContentItem.vue b/client/src/components/History/ContentItem/ContentItem.vue index e3c030d09e5..3158a07267a 100644 --- a/client/src/components/History/ContentItem/ContentItem.vue +++ b/client/src/components/History/ContentItem/ContentItem.vue @@ -40,7 +40,7 @@ size="sm" variant="link" @click.stop="$emit('unhide', item)"> - +
diff --git a/client/src/components/History/History.vue b/client/src/components/History/History.vue index 2fb62f661b3..99ffc2de750 100644 --- a/client/src/components/History/History.vue +++ b/client/src/components/History/History.vue @@ -74,7 +74,9 @@ @viewCollection="$emit('viewCollection', item)" @display="onDisplay" @edit="onEdit" - @delete="onDelete" /> + @delete="onDelete" + @undelete="onUndelete" + @unhide="onUnhide" /> @@ -90,7 +92,7 @@ From 4ab25f2aac03c624d327c305d607415b06b3518c Mon Sep 17 00:00:00 2001 From: guerler Date: Tue, 15 Feb 2022 19:47:50 -0500 Subject: [PATCH 33/95] Add event handling differing between dataset from collections --- .../History/ContentItem/ContentItem.vue | 26 ++++++++++++++----- 1 file changed, 20 insertions(+), 6 deletions(-) diff --git a/client/src/components/History/ContentItem/ContentItem.vue b/client/src/components/History/ContentItem/ContentItem.vue index 3158a07267a..263fe5e06fd 100644 --- a/client/src/components/History/ContentItem/ContentItem.vue +++ b/client/src/components/History/ContentItem/ContentItem.vue @@ -1,9 +1,10 @@ diff --git a/client/src/components/History/History.vue b/client/src/components/History/History.vue index 11847375843..72322bd2bf6 100644 --- a/client/src/components/History/History.vue +++ b/client/src/components/History/History.vue @@ -68,11 +68,12 @@ :name="item.name" :state="item.state || item.populated_state" :expanded="isExpanded(item)" + :expandable="item.history_content_type == 'dataset'" :selected="isSelected(item)" :selectable="showSelection" @update:expanded="setExpanded(item, $event)" @update:selected="setSelected(item, $event)" - @viewCollection="$emit('viewCollection', item)" + @drilldown="$emit('viewCollection', item)" @display="onDisplay" @edit="onEdit" @delete="onDelete" From 52105f3502aa6738d928d326186411ce4e23d7a8 Mon Sep 17 00:00:00 2001 From: guerler Date: Tue, 15 Feb 2022 21:07:58 -0500 Subject: [PATCH 36/95] Parse state for history element items --- client/src/components/History/CurrentCollection/Panel.vue | 1 + 1 file changed, 1 insertion(+) diff --git a/client/src/components/History/CurrentCollection/Panel.vue b/client/src/components/History/CurrentCollection/Panel.vue index 44516101f69..89480af27d9 100644 --- a/client/src/components/History/CurrentCollection/Panel.vue +++ b/client/src/components/History/CurrentCollection/Panel.vue @@ -36,6 +36,7 @@ :id="item.element_index" :name="item.element_identifier" :expandable="item.element_type == 'hda'" + :state="item.object.state" :expanded="isExpanded(item)" :writeable="false" @update:expanded="setExpanded(item, $event)" From 6e49f326d7647f737b771c93647981bb1532083b Mon Sep 17 00:00:00 2001 From: guerler Date: Tue, 15 Feb 2022 21:49:51 -0500 Subject: [PATCH 37/95] Add edit support for collections --- client/src/components/History/ContentItem/ContentItem.vue | 8 +------- client/src/components/History/History.vue | 6 +++++- 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/client/src/components/History/ContentItem/ContentItem.vue b/client/src/components/History/ContentItem/ContentItem.vue index 60eccc654db..cd0fa455e72 100644 --- a/client/src/components/History/ContentItem/ContentItem.vue +++ b/client/src/components/History/ContentItem/ContentItem.vue @@ -12,13 +12,7 @@ @click.stop="$emit('display', item)"> - + Date: Tue, 15 Feb 2022 22:22:52 -0500 Subject: [PATCH 38/95] Prep content details wrapper --- .../History/ContentItem/ContentDetails.vue | 73 ++++++++----------- .../History/ContentItem/ContentItem.vue | 3 - 2 files changed, 31 insertions(+), 45 deletions(-) diff --git a/client/src/components/History/ContentItem/ContentDetails.vue b/client/src/components/History/ContentItem/ContentDetails.vue index 3fdab39d965..69822126d8c 100644 --- a/client/src/components/History/ContentItem/ContentDetails.vue +++ b/client/src/components/History/ContentItem/ContentDetails.vue @@ -1,57 +1,46 @@ diff --git a/client/src/components/History/ContentItem/ContentItem.vue b/client/src/components/History/ContentItem/ContentItem.vue index cd0fa455e72..f39f9dd7ef3 100644 --- a/client/src/components/History/ContentItem/ContentItem.vue +++ b/client/src/components/History/ContentItem/ContentItem.vue @@ -92,9 +92,6 @@ export default { } }, }, - created() { - console.log(this.item); - }, methods: { onClick() { if (this.expandable) { From 0d007d8bbee15a9a6af34d9c939a51d62c0a82de Mon Sep 17 00:00:00 2001 From: guerler Date: Tue, 15 Feb 2022 23:09:30 -0500 Subject: [PATCH 39/95] Add dataset details component --- .../History/ContentItem/ContentDetails.vue | 42 ++++++++++--------- .../History/ContentItem/ContentItem.vue | 2 +- 2 files changed, 24 insertions(+), 20 deletions(-) diff --git a/client/src/components/History/ContentItem/ContentDetails.vue b/client/src/components/History/ContentItem/ContentDetails.vue index 69822126d8c..e2e267baeb0 100644 --- a/client/src/components/History/ContentItem/ContentDetails.vue +++ b/client/src/components/History/ContentItem/ContentDetails.vue @@ -1,23 +1,25 @@ @@ -33,9 +35,11 @@ export default { item: { type: Object, required: true }, }, computed: { + dataset() { + return this.item.object || this.item; + }, dataUrl() { - //object.id and item.element_type == "hda" - const datasetId = this.item.id; + const datasetId = this.dataset.id; return `api/datasets/${datasetId}`; }, }, diff --git a/client/src/components/History/ContentItem/ContentItem.vue b/client/src/components/History/ContentItem/ContentItem.vue index f39f9dd7ef3..59d22e6804d 100644 --- a/client/src/components/History/ContentItem/ContentItem.vue +++ b/client/src/components/History/ContentItem/ContentItem.vue @@ -60,7 +60,7 @@
- + From a44dae9169c3fd7d0129f361d27ea64c7c3a1c75 Mon Sep 17 00:00:00 2001 From: guerler Date: Wed, 16 Feb 2022 08:06:30 -0500 Subject: [PATCH 40/95] Add item component template, required to continue development of scroller --- .../History/ContentItem/ContentActions.vue | 42 +++++++++++++++++++ .../History/ContentItem/ContentDetails.vue | 3 ++ .../History/ContentItem/ContentItem.vue | 2 +- .../src/components/History/HistoryListing.vue | 2 +- 4 files changed, 47 insertions(+), 2 deletions(-) create mode 100644 client/src/components/History/ContentItem/ContentActions.vue diff --git a/client/src/components/History/ContentItem/ContentActions.vue b/client/src/components/History/ContentItem/ContentActions.vue new file mode 100644 index 00000000000..4d3f5a07303 --- /dev/null +++ b/client/src/components/History/ContentItem/ContentActions.vue @@ -0,0 +1,42 @@ + + + diff --git a/client/src/components/History/ContentItem/ContentDetails.vue b/client/src/components/History/ContentItem/ContentDetails.vue index e2e267baeb0..1832015e41b 100644 --- a/client/src/components/History/ContentItem/ContentDetails.vue +++ b/client/src/components/History/ContentItem/ContentDetails.vue @@ -18,6 +18,7 @@ {{ result.misc_info }} +
             
         
@@ -26,9 +27,11 @@
 
 

From 547e728e882c173e5bc7f216d27eaff58497950c Mon Sep 17 00:00:00 2001
From: guerler 
Date: Wed, 16 Feb 2022 17:09:34 -0500
Subject: [PATCH 42/95] Explicitly specify conditions for now, to review and
 verify

---
 .../History/ContentItem/ContentItem.vue       | 46 +++++++++++++++++--
 1 file changed, 43 insertions(+), 3 deletions(-)

diff --git a/client/src/components/History/ContentItem/ContentItem.vue b/client/src/components/History/ContentItem/ContentItem.vue
index 1498885fef6..589797ba53a 100644
--- a/client/src/components/History/ContentItem/ContentItem.vue
+++ b/client/src/components/History/ContentItem/ContentItem.vue
@@ -4,15 +4,23 @@
             
- + @@ -83,6 +92,37 @@ export default { writeable: { type: Boolean, default: true }, }, computed: { + editButtonTitle() { + if (this.item.deleted) { + return "Undelete dataset to edit attributes"; + } + if (this.item.purged) { + return "Cannot edit attributes of datasets removed from disk"; + } + if (this.item.state == "upload" || this.item.state != "new") { + return "This dataset is not yet editable"; + } + return "Edit attributes"; + }, + displayButtonTitle() { + if (this.item.purged) { + return "Cannot display datasets removed from disk"; + } + if (this.item.state == "upload") { + return "This dataset must finish uploading before it can be viewed"; + } + if (this.item.state == "new") { + return "This dataset is not yet viewable"; + } + return "View data"; + }, + deleteButtonTitle() { + return this.item.purged + ? "Dataset has been permanently deleted" + : this.item.deleted + ? "Undelete" + : "Delete"; + }, clsStatus() { const status = ContentStatus[this.state]; if (!status || this.selected) { From b8ab967ecf5f2a6ec7b3a0467d4352161e73804c Mon Sep 17 00:00:00 2001 From: guerler Date: Wed, 16 Feb 2022 18:56:53 -0500 Subject: [PATCH 43/95] Remove content summary components --- .../History/ContentItem/ContentActions.vue | 121 +++++++++++++++++- .../History/ContentItem/ContentItem.vue | 4 +- .../History/ContentItem/ContentStatus.js | 71 +++++++--- .../ContentItem/Dataset/DatasetMenu.vue | 5 + .../History/ContentItem/Dataset/DatasetUI.vue | 4 +- .../ContentItem/Dataset/Summary/Discarded.vue | 5 - .../ContentItem/Dataset/Summary/Empty.vue | 5 - .../ContentItem/Dataset/Summary/Error.vue | 11 -- .../ContentItem/Dataset/Summary/New.vue | 5 - .../Dataset/Summary/NotViewable.vue | 5 - .../ContentItem/Dataset/Summary/Ok.vue | 18 --- .../ContentItem/Dataset/Summary/Paused.vue | 8 -- .../ContentItem/Dataset/Summary/Queued.vue | 5 - .../ContentItem/Dataset/Summary/Running.vue | 5 - .../Dataset/Summary/SettingMetadata.vue | 5 - .../ContentItem/Dataset/Summary/Unknown.vue | 3 - .../ContentItem/Dataset/Summary/Upload.vue | 5 - .../ContentItem/Dataset/Summary/index.vue | 53 -------- 18 files changed, 177 insertions(+), 161 deletions(-) delete mode 100644 client/src/components/History/ContentItem/Dataset/Summary/Discarded.vue delete mode 100644 client/src/components/History/ContentItem/Dataset/Summary/Empty.vue delete mode 100644 client/src/components/History/ContentItem/Dataset/Summary/Error.vue delete mode 100644 client/src/components/History/ContentItem/Dataset/Summary/New.vue delete mode 100644 client/src/components/History/ContentItem/Dataset/Summary/NotViewable.vue delete mode 100644 client/src/components/History/ContentItem/Dataset/Summary/Ok.vue delete mode 100644 client/src/components/History/ContentItem/Dataset/Summary/Paused.vue delete mode 100644 client/src/components/History/ContentItem/Dataset/Summary/Queued.vue delete mode 100644 client/src/components/History/ContentItem/Dataset/Summary/Running.vue delete mode 100644 client/src/components/History/ContentItem/Dataset/Summary/SettingMetadata.vue delete mode 100644 client/src/components/History/ContentItem/Dataset/Summary/Unknown.vue delete mode 100644 client/src/components/History/ContentItem/Dataset/Summary/Upload.vue delete mode 100644 client/src/components/History/ContentItem/Dataset/Summary/index.vue diff --git a/client/src/components/History/ContentItem/ContentActions.vue b/client/src/components/History/ContentItem/ContentActions.vue index 924eaa7b8c1..aadf3a2e55d 100644 --- a/client/src/components/History/ContentItem/ContentActions.vue +++ b/client/src/components/History/ContentItem/ContentActions.vue @@ -1,19 +1,84 @@ From 0706bbb39f68ffa47a02af5a1fdb56f34bbbff2a Mon Sep 17 00:00:00 2001 From: guerler Date: Wed, 16 Feb 2022 23:30:10 -0500 Subject: [PATCH 49/95] Use bug to indicate error, simplify transition between new and old history, avoid tutorial conflicts --- .../components/History/ContentItem/Dataset/DatasetActions.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/src/components/History/ContentItem/Dataset/DatasetActions.vue b/client/src/components/History/ContentItem/Dataset/DatasetActions.vue index c236885febc..07f7b5c509f 100644 --- a/client/src/components/History/ContentItem/Dataset/DatasetActions.vue +++ b/client/src/components/History/ContentItem/Dataset/DatasetActions.vue @@ -2,7 +2,7 @@
- + Date: Thu, 17 Feb 2022 00:39:13 -0500 Subject: [PATCH 50/95] Prep collections component --- .../History/ContentItem/ContentItem.vue | 14 +++++------ .../DatasetCollectionContents.vue | 3 +-- .../GenericContentItem/DatasetUIWrapper.vue | 3 +-- .../GenericHistoryContent.vue | 2 +- .../History/CurrentCollection/Description.vue | 4 +-- .../History/CurrentCollection/Details.vue | 6 ++--- .../History/CurrentCollection/Panel.vue | 25 ++++++++++--------- .../src/components/History/HistoryPanel.vue | 1 + 8 files changed, 28 insertions(+), 30 deletions(-) diff --git a/client/src/components/History/ContentItem/ContentItem.vue b/client/src/components/History/ContentItem/ContentItem.vue index 303b104c8ee..dda95d09997 100644 --- a/client/src/components/History/ContentItem/ContentItem.vue +++ b/client/src/components/History/ContentItem/ContentItem.vue @@ -4,8 +4,8 @@
-
-
+
-
+ @update="onUpdate">
- - From 96b4be0c0d7762f752d5172d22b3cd5e15720380 Mon Sep 17 00:00:00 2001 From: guerler Date: Thu, 17 Feb 2022 14:44:37 -0500 Subject: [PATCH 56/95] Revise collection navigation in history --- .../History/CurrentCollection/Navigation.vue | 44 +++++++------------ .../History/CurrentCollection/Panel.vue | 11 +++-- client/src/components/History/Layout.vue | 2 +- 3 files changed, 22 insertions(+), 35 deletions(-) diff --git a/client/src/components/History/CurrentCollection/Navigation.vue b/client/src/components/History/CurrentCollection/Navigation.vue index 8d0dd240d15..181756fb1ff 100644 --- a/client/src/components/History/CurrentCollection/Navigation.vue +++ b/client/src/components/History/CurrentCollection/Navigation.vue @@ -1,47 +1,35 @@ - - From 390fc83dadc43db8c01a291dc054ff7dcd58743e Mon Sep 17 00:00:00 2001 From: guerler Date: Thu, 17 Feb 2022 20:26:52 -0500 Subject: [PATCH 58/95] Disable visualizations for purged datasets, notice its equal to show downloads now --- .../components/History/ContentItem/Dataset/DatasetActions.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/src/components/History/ContentItem/Dataset/DatasetActions.vue b/client/src/components/History/ContentItem/Dataset/DatasetActions.vue index 07f7b5c509f..0e4fe18e5f0 100644 --- a/client/src/components/History/ContentItem/Dataset/DatasetActions.vue +++ b/client/src/components/History/ContentItem/Dataset/DatasetActions.vue @@ -103,7 +103,7 @@ export default { }, showVisualizations() { // TODO: Check hasViz, if visualizations are activated in the config - return this.item.state == "ok" || this.item.state == "failed_metadata"; + return !this.item.purged && ["ok", "failed_metadata", "error"].includes(this.item.state); }, }, methods: { From 8cbcfc0178aba95baf28e44bac6fa648d5320acc Mon Sep 17 00:00:00 2001 From: guerler Date: Thu, 17 Feb 2022 23:53:21 -0500 Subject: [PATCH 59/95] Use consistent naming, declare collection url as computed value --- .../History/ContentItem/ContentItem.vue | 55 ++++++++++--------- .../History/CurrentCollection/Details.vue | 8 +-- .../History/CurrentCollection/Panel.vue | 14 ++--- 3 files changed, 40 insertions(+), 37 deletions(-) diff --git a/client/src/components/History/ContentItem/ContentItem.vue b/client/src/components/History/ContentItem/ContentItem.vue index dda95d09997..3716ac861eb 100644 --- a/client/src/components/History/ContentItem/ContentItem.vue +++ b/client/src/components/History/ContentItem/ContentItem.vue @@ -5,7 +5,7 @@
@@ -39,7 +39,7 @@ title="Delete" size="sm" variant="link" - :disabled="item.purged" + :disabled="isUnavailable" @click.stop="$emit('delete', item)"> @@ -93,24 +93,14 @@ export default { writeable: { type: Boolean, default: true }, }, computed: { - icon() { - const stateIcon = CONTENTSTATE[this.state] && CONTENTSTATE[this.state].icon; - if (stateIcon) { - return `fa fa-${stateIcon}`; + clsStatus() { + const status = CONTENTSTATE[this.state] && CONTENTSTATE[this.state].status; + if (!status || this.selected) { + return "alert-info"; + } else { + return `alert-${status}`; } }, - editButtonTitle() { - if (this.item.deleted) { - return "Undelete dataset to edit attributes"; - } - if (this.item.purged) { - return "Cannot edit attributes of datasets removed from disk"; - } - if (this.state == "upload" || this.state != "new") { - return "This dataset is not yet editable"; - } - return "Edit attributes"; - }, displayButtonTitle() { if (this.item.purged) { return "Cannot display datasets removed from disk"; @@ -130,13 +120,26 @@ export default { ? "Undelete" : "Delete"; }, - clsStatus() { - const status = CONTENTSTATE[this.state] && CONTENTSTATE[this.state].status; - if (!status || this.selected) { - return "alert-info"; - } else { - return `alert-${status}`; + editButtonTitle() { + if (this.item.deleted) { + return "Undelete dataset to edit attributes"; } + if (this.item.purged) { + return "Cannot edit attributes of datasets removed from disk"; + } + if (this.state == "upload" || this.state != "new") { + return "This dataset is not yet editable"; + } + return "Edit attributes"; + }, + icon() { + const stateIcon = CONTENTSTATE[this.state] && CONTENTSTATE[this.state].icon; + if (stateIcon) { + return `fa fa-${stateIcon}`; + } + }, + isUnavailable() { + return this.item.purged || this.state == "upload" || this.state == "new"; }, }, methods: { diff --git a/client/src/components/History/CurrentCollection/Details.vue b/client/src/components/History/CurrentCollection/Details.vue index 0f991199bd2..ffd1a266c3c 100644 --- a/client/src/components/History/CurrentCollection/Details.vue +++ b/client/src/components/History/CurrentCollection/Details.vue @@ -27,10 +27,10 @@ 0; diff --git a/client/src/components/History/CurrentCollection/Panel.vue b/client/src/components/History/CurrentCollection/Panel.vue index 4254437e3c2..1f088d9ac4e 100644 --- a/client/src/components/History/CurrentCollection/Panel.vue +++ b/client/src/components/History/CurrentCollection/Panel.vue @@ -1,7 +1,7 @@ diff --git a/client/src/components/History/Content/GenericContentItem/DatasetCollectionUIWrapper.test.js b/client/src/components/History/Content/GenericContentItem/DatasetCollectionUIWrapper.test.js deleted file mode 100644 index 450fd39fe90..00000000000 --- a/client/src/components/History/Content/GenericContentItem/DatasetCollectionUIWrapper.test.js +++ /dev/null @@ -1,59 +0,0 @@ -import DatasetCollectionUIWrapper from "./DatasetCollectionUIWrapper"; -import DscUI from "components/History/ContentItem/DatasetCollection/DscUI"; -import { shallowMount } from "@vue/test-utils"; -import datasetCollectionRaw from "components/providers/test/json/DatasetCollection.json"; -import datasetCollectionContent from "components/providers/test/json/DatasetCollection.nested.json"; - -describe("DatasetUIWrapper.vue with Dataset", () => { - let wrapper; - let propsData; - let onHide; - let onUnhide; - let onDelete; - let onUndelete; - - beforeEach(async () => { - propsData = { - item: datasetCollectionRaw, - }; - onHide = jest.spyOn(DatasetCollectionUIWrapper.methods, "onHide").mockImplementation(); - onUnhide = jest.spyOn(DatasetCollectionUIWrapper.methods, "onUnhide").mockImplementation(); - onDelete = jest.spyOn(DatasetCollectionUIWrapper.methods, "onDelete").mockImplementation(); - onUndelete = jest.spyOn(DatasetCollectionUIWrapper.methods, "onUndelete").mockImplementation(); - wrapper = shallowMount(DatasetCollectionUIWrapper, { - propsData, - }); - }); - - it("loads DscUI component", async () => { - expect(wrapper.findComponent(DscUI).exists()).toBeTruthy(); - }); - - it("reacts to all emittted events", async () => { - expect(onHide).not.toHaveBeenCalled(); - expect(onUnhide).not.toHaveBeenCalled(); - expect(onDelete).not.toHaveBeenCalled(); - expect(onUndelete).not.toHaveBeenCalled(); - wrapper.findComponent(DscUI).vm.$emit("hide"); - expect(onHide).toHaveBeenCalled(); - wrapper.findComponent(DscUI).vm.$emit("unhide"); - expect(onUnhide).toHaveBeenCalled(); - wrapper.findComponent(DscUI).vm.$emit("delete"); - expect(onDelete).toHaveBeenCalled(); - wrapper.findComponent(DscUI).vm.$emit("undelete"); - expect(onUndelete).toHaveBeenCalled(); - }); - it("creates DatasetCollection", async () => { - const datasetCollection = wrapper.vm.datasetCollection; - expect(datasetCollection.collectionType).toBe("list of pairs"); - }); - it("manages collection expansion", async () => { - expect(wrapper.vm.expand).toBeFalsy(); - wrapper.findComponent(DscUI).vm.$emit("viewCollection", wrapper.vm.datasetCollection); - expect(wrapper.vm.expand).toBeTruthy(); - }); - it("build dsc from collection content", async () => { - await wrapper.setProps({ item: datasetCollectionContent }); - expect(wrapper.vm.datasetCollection.name).toBe(datasetCollectionContent.element_identifier); - }); -}); diff --git a/client/src/components/History/Content/GenericContentItem/DatasetCollectionUIWrapper.vue b/client/src/components/History/Content/GenericContentItem/DatasetCollectionUIWrapper.vue deleted file mode 100644 index 62c67eeb767..00000000000 --- a/client/src/components/History/Content/GenericContentItem/DatasetCollectionUIWrapper.vue +++ /dev/null @@ -1,71 +0,0 @@ - - diff --git a/client/src/components/History/Content/GenericContentItem/DatasetUIWrapper.test.js b/client/src/components/History/Content/GenericContentItem/DatasetUIWrapper.test.js deleted file mode 100644 index c5700394c5e..00000000000 --- a/client/src/components/History/Content/GenericContentItem/DatasetUIWrapper.test.js +++ /dev/null @@ -1,51 +0,0 @@ -import DatasetUIWrapper from "./DatasetUIWrapper"; -import DatasetUI from "components/History/ContentItem/Dataset/DatasetUI"; -import { shallowMount } from "@vue/test-utils"; -import raw from "components/providers/test/json/Dataset.json"; - -describe("DatasetUIWrapper.vue with Dataset", () => { - let wrapper; - let propsData; - let onDelete; - let onUnhide; - let onUndelete; - let updateDataset; - - beforeEach(async () => { - propsData = { - item: raw, - }; - onDelete = jest.spyOn(DatasetUIWrapper.methods, "onDelete").mockImplementation(); - onUnhide = jest.spyOn(DatasetUIWrapper.methods, "onUnhide").mockImplementation(); - onUndelete = jest.spyOn(DatasetUIWrapper.methods, "onUndelete").mockImplementation(); - updateDataset = jest.spyOn(DatasetUIWrapper.methods, "onUpdate").mockImplementation(); - wrapper = shallowMount(DatasetUIWrapper, { - propsData, - }); - }); - - it("loads DatasetUI component", async () => { - expect(wrapper.findComponent(DatasetUI).exists()).toBeTruthy(); - }); - - it("reacts to all emittted events", async () => { - expect(onDelete).not.toHaveBeenCalled(); - expect(onUnhide).not.toHaveBeenCalled(); - expect(onUndelete).not.toHaveBeenCalled(); - expect(updateDataset).not.toHaveBeenCalled(); - wrapper.findComponent(DatasetUI).vm.$emit("delete"); - expect(onDelete).toHaveBeenCalled(); - wrapper.findComponent(DatasetUI).vm.$emit("undelete"); - expect(onUndelete).toHaveBeenCalled(); - wrapper.findComponent(DatasetUI).vm.$emit("unhide"); - expect(onUnhide).toHaveBeenCalled(); - wrapper.findComponent(DatasetUI).vm.$emit("update"); - expect(updateDataset).toHaveBeenCalled(); - }); - it("handles element identifier", async () => { - expect(wrapper.vm.dataset.canEditName).toBeTruthy(); - await wrapper.setProps({ element_identifier: "a cool identifier" }); - expect(wrapper.vm.dataset.title).toBe("a cool identifier"); - expect(wrapper.vm.dataset.canEditName).toBeFalsy(); - }); -}); diff --git a/client/src/components/History/Content/GenericContentItem/DatasetUIWrapper.vue b/client/src/components/History/Content/GenericContentItem/DatasetUIWrapper.vue deleted file mode 100644 index bc195770945..00000000000 --- a/client/src/components/History/Content/GenericContentItem/DatasetUIWrapper.vue +++ /dev/null @@ -1,54 +0,0 @@ - - - diff --git a/client/src/components/History/Content/GenericContentItem/GenericHistoryContent.vue b/client/src/components/History/Content/GenericContentItem/GenericHistoryContent.vue deleted file mode 100644 index 3b32cb2d44d..00000000000 --- a/client/src/components/History/Content/GenericContentItem/GenericHistoryContent.vue +++ /dev/null @@ -1,34 +0,0 @@ - - - diff --git a/client/src/components/History/Content/GenericItem.vue b/client/src/components/History/Content/GenericItem.vue new file mode 100644 index 00000000000..074ab3e6288 --- /dev/null +++ b/client/src/components/History/Content/GenericItem.vue @@ -0,0 +1,72 @@ + + + diff --git a/client/src/components/JobInformation/JobOutputs.vue b/client/src/components/JobInformation/JobOutputs.vue index 83a48c96597..feba2eecd7b 100644 --- a/client/src/components/JobInformation/JobOutputs.vue +++ b/client/src/components/JobInformation/JobOutputs.vue @@ -14,7 +14,11 @@ {{ value[0].label || name }} - + @@ -23,11 +27,11 @@ diff --git a/client/src/components/History/Content/GenericItem.vue b/client/src/components/History/Content/GenericItem.vue index 363429b6e25..d5087fb8b6b 100644 --- a/client/src/components/History/Content/GenericItem.vue +++ b/client/src/components/History/Content/GenericItem.vue @@ -1,19 +1,25 @@ @@ -22,10 +28,12 @@ import LoadingSpan from "components/LoadingSpan"; import { DatasetProvider, DatasetCollectionProvider } from "components/providers"; import { deleteContent, updateContentFields } from "components/History/model/queries"; import ContentItem from "./ContentItem"; +import GenericElement from "./GenericElement"; export default { components: { ContentItem, + GenericElement, DatasetProvider, DatasetCollectionProvider, LoadingSpan, @@ -46,9 +54,6 @@ export default { expanded: false, }; }, - created() { - console.log(this.itemId); - }, computed: { providerComponent() { return this.itemSrc == "hda" ? "DatasetProvider" : "DatasetCollectionProvider"; diff --git a/lib/galaxy/selenium/navigation.yml b/lib/galaxy/selenium/navigation.yml index 543c262471a..c4b7581cf42 100644 --- a/lib/galaxy/selenium/navigation.yml +++ b/lib/galaxy/selenium/navigation.yml @@ -631,7 +631,7 @@ invocations: step_output_collection_toggle: '.workflow-invocation-state-component .invocation-steps-details [data-step="${order_index}"] .invocation-step-output-collection-details .name' step_output_collection_element_identifier: type: xpath - selector: '//span[@class="name"][text()="${element_identifier}"]' + selector: '//span[@class="content-title name"][text()="${element_identifier}"]' step_output_collection_element_datatype: '.workflow-invocation-state-component .invocation-steps-details [data-step="${order_index}"] .invocation-step-output-collection-details .datatype .value' step_job_details: '.workflow-invocation-state-component .invocation-steps-details [data-step="${order_index}"] .invocation-step-job-details' step_job_table: '.workflow-invocation-state-component .invocation-steps-details [data-step="${order_index}"] .invocation-step-job-details table' diff --git a/lib/galaxy_test/selenium/test_workflow_invocation_details.py b/lib/galaxy_test/selenium/test_workflow_invocation_details.py index 42e8c95580d..94e8423b2a2 100644 --- a/lib/galaxy_test/selenium/test_workflow_invocation_details.py +++ b/lib/galaxy_test/selenium/test_workflow_invocation_details.py @@ -73,5 +73,6 @@ class WorkflowInvocationDetailsTestCase(SeleniumTestCase): invocations.step_output_collection(order_index="1").wait_for_and_click() invocations.step_output_collection_toggle(order_index="1").wait_for_and_click() invocations.step_output_collection_element_identifier(element_identifier="forward").wait_for_and_click() + datatype = invocations.step_output_collection_element_datatype(order_index="1").wait_for_text() assert datatype == "txt" From 6653a42d149a96152f401038844b49f5047d2759 Mon Sep 17 00:00:00 2001 From: guerler Date: Sun, 27 Feb 2022 14:23:51 -0500 Subject: [PATCH 76/95] Adjust re-run test to revised dom layout of history content item --- .../components/History/Content/ContentItem.vue | 2 +- .../History/Content/Dataset/DatasetDetails.vue | 6 ++++-- .../CurrentCollection/CollectionNavigation.vue | 2 +- client/src/components/History/Layout/Details.vue | 2 +- client/src/entry/panels/history-panel.js | 2 +- client/src/mvc/history/history-view.js | 4 ++-- lib/galaxy/selenium/navigation.yml | 16 ++++++++-------- .../selenium/test_history_panel_collections.py | 4 +++- lib/galaxy_test/selenium/test_tool_form.py | 13 ++++++------- 9 files changed, 27 insertions(+), 24 deletions(-) diff --git a/client/src/components/History/Content/ContentItem.vue b/client/src/components/History/Content/ContentItem.vue index 7a4bd8e7f08..1f62270f580 100644 --- a/client/src/components/History/Content/ContentItem.vue +++ b/client/src/components/History/Content/ContentItem.vue @@ -77,7 +77,7 @@
- +
diff --git a/client/src/components/History/Content/Dataset/DatasetDetails.vue b/client/src/components/History/Content/Dataset/DatasetDetails.vue index 80e817947c4..d827676fb0d 100644 --- a/client/src/components/History/Content/Dataset/DatasetDetails.vue +++ b/client/src/components/History/Content/Dataset/DatasetDetails.vue @@ -1,5 +1,5 @@