class Decidim::Debates::DebatesType

Public Instance Methods

debate(**args) click to toggle source
# File lib/decidim/api/debates_type.rb, line 21
def debate(**args)
  Debate.where(component: object).find_by(id: args[:id])
end
debates() click to toggle source
# File lib/decidim/api/debates_type.rb, line 13
def debates
  Debate.where(component: object).includes(:component)
end