Class: RollingMembershipType

Inherits:
MembershipType show all
Defined in:
app/models/rolling_membership_type.rb

Constant Summary

Constants included from Ext::Integrations::ServiceFee

Ext::Integrations::ServiceFee::SERVICE_FEE

Instance Method Summary collapse

Methods inherited from MembershipType

#allow_multiple_memberships?, #create_list_segment, in_play, #membershipize, #price_for

Methods included from ArtfullyOseHelper

#amount_and_nongift, #bootstrapped_type, #build_action_path, #build_order_location, #channel_checkbox, #channel_text, #check_mark, #clean_full_error_messages, #contextual_menu, #credit_card_message, #date_field_tag, #datetime_field_tag, #events_to_options, #fully_qualified_asset_path, #get_selected_class, #icon_link_to, #icon_tag, #link_to_add_fields, #link_to_remove_fields, #nav_dropdown, #number_as_cents, #number_to_dollars, #pluralize_word, #refund_header, #select_event_for_sales_search, #select_membership_type_for_sales_search, #select_pass_type_for_sales_search, #select_show_for_sales_search, #sorted_us_state_abbreviations, #sorted_us_state_names, #thanks_message, #ticket_seller_name, #time_ago_sentence, #time_zone_description, #us_states, #verb_for_save, #widget_script, #with_kit

Methods included from LinkHelper

#active?, #active_link_to, #active_section, #calendar_active_link_to, #in_section, #in_section?, #in_sub_section

Instance Method Details

#ends_atObject



8
9
10
# File 'app/models/rolling_membership_type.rb', line 8

def ends_at
  self.duration.nil? ? nil : DateTime.now + (self.duration.send(self.period.downcase))
end

#starts_atObject



4
5
6
# File 'app/models/rolling_membership_type.rb', line 4

def starts_at
  DateTime.now
end