Sha256: 15bf92063e1b94a85da6014a5e70c95d56f7470592c775c0367333df8ab37b5c

Contents?: true

Size: 751 Bytes

Versions: 13

Compression:

Stored size: 751 Bytes

Contents

# frozen_string_literal: true

# http://www.atomenabled.org/developers/syndication/
items  = controller.controller_name
item   = items.singularize
assets = controller.instance_variable_get("@#{items}")

atom_feed do |feed|
  feed.title t(:activities)
  feed.updated @activities.max_by(&:created_at).try(:created_at)
  feed.generator "Fat Free CRM v#{FatFreeCRM::VERSION::STRING}"
  feed.author do |author|
    author.name  current_user.full_name
    author.email current_user.email
  end

  @activities.each do |activity|
    feed.entry(activity, url: '') do |entry|
      entry.title activity_title(activity)

      entry.author do |author|
        author.name activity.user.try(:full_name) || I18n.t('version.anonymous')
      end
    end
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
fat_free_crm-0.22.1 app/views/home/index.atom.builder
fat_free_crm-0.22.0 app/views/home/index.atom.builder
fat_free_crm-0.21.0 app/views/home/index.atom.builder
fat_free_crm-0.20.1 app/views/home/index.atom.builder
fat_free_crm-0.20.0 app/views/home/index.atom.builder
fat_free_crm-0.19.2 app/views/home/index.atom.builder
fat_free_crm-0.19.0 app/views/home/index.atom.builder
fat_free_crm-0.18.2 app/views/home/index.atom.builder
fat_free_crm-0.17.3 app/views/home/index.atom.builder
fat_free_crm-0.18.1 app/views/home/index.atom.builder
fat_free_crm-0.18.0 app/views/home/index.atom.builder
fat_free_crm-0.17.2 app/views/home/index.atom.builder
fat_free_crm-0.17.1 app/views/home/index.atom.builder