Skip to Content Skip to Search
Methods
A
D
T
Included Modules

Instance Public methods

action()

# File app/models/analytics/view.rb, line 38
def action
  "view"
end

action_family()

# File app/models/analytics/view.rb, line 42
def action_family
  "traffic"
end

details()

# File app/models/analytics/view.rb, line 24
def details
  (super.presence || {}).transform_keys do |key|
    key.to_s.humanize
  end
end

title()

# File app/models/analytics/view.rb, line 30
def title
  if content_page?
    "Viewed page #{content&.path || "[deleted]"}"
  elsif content_file?
    "Viewed content #{content&.name || "[deleted]"}"
  end
end