Don't fail rest of multi-action queue when attempting to purge a collection.

Fixes https://github.com/galaxyproject/galaxy/issues/5117.
This commit is contained in:
John Chilton
2018-02-18 13:28:36 -05:00
parent c20b68a5dd
commit f6ac13568f
@@ -275,7 +275,12 @@ var HistoryViewEdit = _super.extend(
func: function() {
if (confirm(_l("This will permanently remove the data in your datasets. Are you sure?"))) {
var action = HDA_MODEL.HistoryDatasetAssociation.prototype.purge;
panel.getSelectedModels().ajaxQueue(action);
const historyContents = panel.getSelectedModels();
const selectedDatasets = historyContents.filter(
c =>
c.get("history_content_type") == "dataset"
)
historyContents.ajaxQueue(action, {}, selectedDatasets);
}
}
});