Sha256: 3eea9776881ef5d421ac614d6720497ea6c92476c1a2791d19acd1d2671da9ed

Contents?: true

Size: 587 Bytes

Versions: 1

Compression:

Stored size: 587 Bytes

Contents

module PhcdevworksTutorials
  class Command::Item < ApplicationRecord

    # Paper Trail Initialize
    has_paper_trail :class_name => 'PhcdevworksTutorials::CommandItemVersions'

    # Image Upload
    has_one_attached :command_item_image

    # Relationships
    belongs_to :user, class_name: "PhcdevworksAccounts::User"
    belongs_to :post, class_name: "Command::Post"
    has_many :categories, class_name: "Tutorial::Category", :through => :post
    belongs_to :optimization, class_name: "PhcdevworksCoreModules::Marketing::Optimization", optional: true

  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
phcdevworks_tutorials-12.2.0 app/models/phcdevworks_tutorials/command/item.rb