Move resource partial to a component

We're renaming it to ActiveResource in order to better differentiate it
from the DefaultResource component.
This commit is contained in:
taitus
2025-06-27 10:25:01 +02:00
committed by Javi Martín
parent 9b0675aa06
commit 1f97a996f8
7 changed files with 57 additions and 49 deletions

View File

@@ -1,5 +1,5 @@
class DashboardController < Dashboard::BaseController
helper_method :dashboard_action, :active_resources, :course
helper_method :dashboard_action, :course
before_action :set_done_and_pending_actions, only: [:recommended_actions, :progress]
before_action :authorize_dashboard, except: :publish
@@ -30,13 +30,6 @@ class DashboardController < Dashboard::BaseController
private
def active_resources
@active_resources ||= Dashboard::Action.active
.resources
.by_proposal(proposal)
.order(required_supports: :asc, day_offset: :asc)
end
def course
@course ||= Dashboard::Action.course_for(proposal)
end