Files
fizzy/app/controllers/prompts/cards_controller.rb
T
2025-06-19 13:00:26 +02:00

16 lines
333 B
Ruby

class Prompts::CardsController < ApplicationController
def index
@cards = if filter_param.present?
Current.user.accessible_cards.mentioning(filter_param)
else
Current.user.accessible_cards.latest.limit(10)
end
render layout: false
end
private
def filter_param
params[:filter]
end
end