Class: CompOrder

Inherits:
Order
  • Object
show all
Includes:
Unrefundable
Defined in:
app/models/orders/comp_order.rb

Instance Attribute Summary

Attributes inherited from Order

#per_item_processing_charge, #skip_actions, #skip_email

Class Method Summary collapse

Instance Method Summary collapse

Methods included from Unrefundable

#refundable_items

Methods inherited from Order

#<<, #action_details, #all_donations, #all_items, #all_tickets, #anonymous_purchase?, #artfully?, #assign_buyer_to_tickets, #assign_person, #assign_person_to_actions, #assignable?, #calculate_lifetime_value, #calculate_when_revenue_applies, #cash?, #check?, #contact_email, #create_donation_actions, #create_generic_action, #create_purchase_action, #credit?, #destroyable?, #discount_codes, #discounts_used, #donation_details, #donations, #editable?, #events, #exchangeable_items, #exchanges, #for_organization, #has_donation?, #has_membership?, #has_pass?, #has_single_donation?, #has_ticket?, #imported?, in_range, #is_fafs?, #items_that_used_pass, #location, membership_sale_search, #membership_types, #memberships, #non_exchanged_total, #nongift_amount, #num_tickets, #original_order, #originally_sold_at, #pass_codes, pass_sale_search, #passes, #payment, #process, #processor_class, #purchase_action_class, #record_exchange!, #refundable_items, #returnable_items, #revenue_applies_to_range, #service_fee, #settleable_donations, #show, #skip_confirmation_email?, #sum_donations, #ticket_details, #ticket_summary, #tickets, #time_zone, #to_comp!, #total, #total_discount, #total_with_service_fee, #transaction_id

Methods included from Ext::DelayedIndexing

included

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

Methods included from OhNoes::Destroy

#destroy, #destroyable?

Methods included from Ext::Integrations::Order

#fa_id, included

Constructor Details

#initializeCompOrder

Returns a new instance of CompOrder.



12
13
14
15
# File 'app/models/orders/comp_order.rb', line 12

def initialize
  super
  self.payment_method = ::CompPayment.payment_method
end

Class Method Details

.locationObject



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

def self.location
  "Artful.ly"
end

Instance Method Details

#action_classObject



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

def action_class
  CompAction
end

#sell_ticketsObject



17
18
19
20
21
# File 'app/models/orders/comp_order.rb', line 17

def sell_tickets
  all_tickets.each do |item|
    item.product.comp_to(self.person, self.created_at)
  end
end