Sha256: 87b9b3852cfbba86d67a4ff3927d90fcdaae7c1f581cbac81d03e607a002b88c

Contents?: true

Size: 686 Bytes

Versions: 4

Compression:

Stored size: 686 Bytes

Contents

module Phcmemberspro
	class Members::Contact < ActiveRecord::Base

		# Mount PHCEngine
		belongs_to :user, :class_name => "Phcengine::User"

		# Model Relationships
		belongs_to :main, class_name: 'Members::Main'

		# Validation for Form Fields
		validates :mccontactname,
			presence: true,
			length: { minimum: 3 }

		validates :mccompanyname,
			presence: true,
			length: { minimum: 2 }

		validates :mccity,
			presence: true,
			length: { minimum: 3 }

		validates :mcprovince,
			presence: true,
			length: { minimum: 2 }
			
		validates :mccountry,
			presence: true,
			length: { minimum: 2 }

		validates :mcpostalcode,
			presence: true,
			length: { minimum: 6 }

	end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
phcmemberspro-1.6.5 app/models/phcmemberspro/members/contact.rb
phcmemberspro-1.6.3 app/models/phcmemberspro/members/contact.rb
phcmemberspro-1.6.1 app/models/phcmemberspro/members/contact.rb
phcmemberspro-1.6.0 app/models/phcmemberspro/members/contact.rb