Sha256: 54d270564080a05be74b7e06d2e574c9d37255dbab943226be729643b24366a9
Contents?: true
Size: 647 Bytes
Versions: 8
Compression:
Stored size: 647 Bytes
Contents
module Landable module Traffic class PageView < ActiveRecord::Base include Landable::TableName self.record_timestamps = false belongs_to :visit lookup_for :mime_type, class_name: MimeType lookup_for :http_method, class_name: HTTPMethod lookup_for :path, class_name: Path lookup_for :query_string, class_name: QueryString before_create :set_page_revision protected def set_page_revision page = Landable::Page.where(path: path).select(:published_revision_id).first self.page_revision_id = page.try(:published_revision_id) end end end end
Version data entries
8 entries across 8 versions & 1 rubygems