X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/4f4f6f5fe9367d5cd6c57070fd8a223efc87cb21..74fec3cd8284eae4829dad2c287588d52c621c4b:/apps/workbench/app/controllers/work_unit_templates_controller.rb diff --git a/apps/workbench/app/controllers/work_unit_templates_controller.rb b/apps/workbench/app/controllers/work_unit_templates_controller.rb index fe53ac403c..0376590a55 100644 --- a/apps/workbench/app/controllers/work_unit_templates_controller.rb +++ b/apps/workbench/app/controllers/work_unit_templates_controller.rb @@ -1,3 +1,7 @@ +# Copyright (C) The Arvados Authors. All rights reserved. +# +# SPDX-License-Identifier: AGPL-3.0 + class WorkUnitTemplatesController < ApplicationController def find_objects_for_index return if !params[:partial] @@ -8,12 +12,12 @@ class WorkUnitTemplatesController < ApplicationController # get next page of pipeline_templates if PipelineTemplate.api_exists?(:index) filters = @filters + [["uuid", "is_a", ["arvados#pipelineTemplate"]]] - pipelines = PipelineTemplate.limit(@limit).order(["created_at desc"]).filter(filters) + pipelines = PipelineTemplate.limit(@limit).with_count("none").order(["created_at desc"]).filter(filters) end # get next page of workflows filters = @filters + [["uuid", "is_a", ["arvados#workflow"]]] - workflows = Workflow.limit(@limit).order(["created_at desc"]).filter(filters) + workflows = Workflow.limit(@limit).order(["created_at desc"]).with_count("none").filter(filters) @objects = (pipelines.to_a + workflows.to_a).sort_by(&:created_at).reverse.first(@limit)