Sha256: c70c084fd618f12c249af70ed67b8a0245ed3b461219a2d01d6ee707743f4f9a

Contents?: true

Size: 429 Bytes

Versions: 1

Compression:

Stored size: 429 Bytes

Contents

class TwitterUserTimelinePortlet < Portlet

  # Mark this as 'true' to allow the portlet's template to be editable via the CMS admin UI.
  enable_template_editor true
     
  def render
    raise ArgumentError, "No Twitter Username was given" if self.username.blank?

    @items = Timeline.find_or_create_by_username(self.username).get_timeline(@portlet.limit)

    instance_eval(self.code) unless self.code.blank?
  end
    
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
bcms_twitter_module-1.1.3 app/portlets/twitter_user_timeline_portlet.rb