Class: UserConsent::Agreement::FormObject

Inherits:
Object
  • Object
show all
Includes:
ActiveModel::Model
Defined in:
app/models/user_consent/agreement/form_object.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Attribute Details

#marketing_policyObject

Returns the value of attribute marketing_policy.



6
7
8
# File 'app/models/user_consent/agreement/form_object.rb', line 6

def marketing_policy
  @marketing_policy
end

#privacy_policyObject

Returns the value of attribute privacy_policy.



6
7
8
# File 'app/models/user_consent/agreement/form_object.rb', line 6

def privacy_policy
  @privacy_policy
end

Class Method Details

.model_nameActiveModel::Name

Defining this method allows us to use some ActiveModel patterns. For example, forms will be identified as sign_in instead of session_sign_in_form_object.

Returns:

  • (ActiveModel::Name)


14
15
16
# File 'app/models/user_consent/agreement/form_object.rb', line 14

def self.model_name
  ActiveModel::Name.new(self, nil, 'Agreement')
end