Sha256: 9fdf45b55bcad16a6f3fe1cbe2717eb11d66cf728da3d181a278386145d37f76
Contents?: true
Size: 956 Bytes
Versions: 22
Compression:
Stored size: 956 Bytes
Contents
module MuckRakerFeedsHelper def add_feed(parent = nil) render :partial => 'parts/add_feed', :locals => {:parent => parent} end def new_feed_path_with_parent(parent, options = {}) if parent feeds_path(make_parent_params(parent).merge(options)) else feeds_path(options) end end def feed_contributor_link(feed) if feed.contributor_id.nil? admin = Feed.find_by_login('admin') 'unknown' else link_to feed.contributor.display_name, user_path(feed.contributor_id) end end def sort_feeds_link(current_order, current_asc, new_order, admin = false) if admin == true admin_feeds_url(:order => new_order, :asc => (current_order == new_order && (current_asc == 'true' || current_asc == nil)) ? 'false' : 'true') else feeds_url(:order => new_order, :asc => (current_order == new_order && (current_asc == 'true' || current_asc == nil)) ? 'false' : 'true') end end end
Version data entries
22 entries across 22 versions & 1 rubygems