Sha256: 2fe97050f30e3aea1179630c55538779b96ca56ffec04eeea1aced9c7aea6ba5

Contents?: true

Size: 505 Bytes

Versions: 111

Compression:

Stored size: 505 Bytes

Contents

module Phcmemberspro
	class Directory::Catlist < ActiveRecord::Base

		# Account Scope
		def self.scoped_to(account)
		    where(:account_id => account.id)
		end

		# Model Relationship
		belongs_to :category, class_name: 'Directory::Category'
		belongs_to :listing, class_name: 'Members::Listing'

		# Validation for Form Fields (More of a Self-Check)
		validates :listing_id,
			presence: true

		# Validation for Form Fields (More of a Self-Check)
		validates :category_id,
			presence: true

	end
end

Version data entries

111 entries across 111 versions & 1 rubygems

Version Path
phcmemberspro-4.10.6 app/models/phcmemberspro/directory/catlist.rb
phcmemberspro-4.10.5 app/models/phcmemberspro/directory/catlist.rb
phcmemberspro-4.10.4 app/models/phcmemberspro/directory/catlist.rb
phcmemberspro-4.10.3 app/models/phcmemberspro/directory/catlist.rb
phcmemberspro-4.10.2 app/models/phcmemberspro/directory/catlist.rb
phcmemberspro-4.10.1 app/models/phcmemberspro/directory/catlist.rb
phcmemberspro-4.10.0 app/models/phcmemberspro/directory/catlist.rb
phcmemberspro-4.9.9 app/models/phcmemberspro/directory/catlist.rb
phcmemberspro-4.9.8 app/models/phcmemberspro/directory/catlist.rb
phcmemberspro-4.9.7 app/models/phcmemberspro/directory/catlist.rb
phcmemberspro-4.9.6 app/models/phcmemberspro/directory/catlist.rb
phcmemberspro-4.9.5 app/models/phcmemberspro/directory/catlist.rb
phcmemberspro-4.9.4 app/models/phcmemberspro/directory/catlist.rb
phcmemberspro-4.9.3 app/models/phcmemberspro/directory/catlist.rb
phcmemberspro-4.9.2 app/models/phcmemberspro/directory/catlist.rb
phcmemberspro-4.9.1 app/models/phcmemberspro/directory/catlist.rb
phcmemberspro-4.9.0 app/models/phcmemberspro/directory/catlist.rb
phcmemberspro-4.8.9 app/models/phcmemberspro/directory/catlist.rb
phcmemberspro-4.8.8 app/models/phcmemberspro/directory/catlist.rb
phcmemberspro-4.8.7 app/models/phcmemberspro/directory/catlist.rb