This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# _job | |
<div> | |
<%= fields_for :job do | f | | |
<%= render :partial => 'waypoints/waypoint', :locals => {:job_form => f} %> | |
</div> | |
-------------------------------- | |
# _waypoint |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Address < ActiveRecord::Base | |
ADDRESS_TYPES = %w(Office Postal Shipping) | |
default_scope order('created_at DESC') | |
scope :active, where(active: true) | |
validates_inclusion_of :address_type, in: ADDRESS_TYPES, message: "must be one of #{ADDRESS_TYPES.to_sentence(last_word_connector: ' or ')}" | |
belongs_to :source, polymorphic: true |
NewerOlder