Module: AMEE::Rails::InstanceMethods
- Defined in:
- lib/amee/rails.rb
Instance Method Summary collapse
Instance Method Details
#amee_connection ⇒ Object
91 92 93 94 |
# File 'lib/amee/rails.rb', line 91 def amee_connection # Should be overridden by code which doesn't use the global AMEE connection AMEE::Rails.connection end |
#amee_create ⇒ Object
73 74 75 76 77 |
# File 'lib/amee/rails.rb', line 73 def amee_create # Create profile profile = AMEE::Profile::Profile.create(amee_connection) self.amee_profile = profile.uid end |
#amee_destroy ⇒ Object
84 85 86 87 88 89 |
# File 'lib/amee/rails.rb', line 84 def amee_destroy # Delete profile AMEE::Profile::Profile.delete(amee_connection, amee_profile) rescue puts "Couldn't remove profile #{amee_profile}" end |
#amee_save ⇒ Object
79 80 81 82 |
# File 'lib/amee/rails.rb', line 79 def amee_save # This is only here to be overridden return true end |