Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also compare across forks.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also compare across forks.
base fork: paulca/address_engine
base: master
...
head fork: TylerRick/address_engine
compare: master
Checking mergeability… Don’t worry, you can still create the pull request.
Commits on Aug 03, 2011
Tyler Rick Renamed firstname -> first_name, lastname -> last_name 09feb57
Tyler Rick Removed Address#order and Address#shipping_rules since they appear to be
unused, vestigial methods
6a65110
Tyler Rick Rearranged the field order in the CreateAddresses migration 968f1ff
Commits on Aug 04, 2011
Tyler Rick Changed message of validates_format_of :email
Made :phone not required (would be nice if it could be optional through
some config option)
9c312db
Tyler Rick Address: Added belongs_to :addressable, :polymorphic => true b56bd8f
Tyler Rick Shouldn't address be required? a9d91a9
Tyler Rick Then again, these validations should all be optional, so the app that's
using this engine can customize their Address model with the validations
they actually want.
d23aaeb
Tyler Rick Added single name field to replace first_name, last_name 0da6f9f
Tyler Rick Renamed state_province_region to province. (state_province_region is too
long and calling it both a state and a province and a region is redundant)

Renamed zip_postal_code to postal_code for the same reasons.
fada110
Commits on Aug 18, 2011
Tyler Rick Added country_name= method and made it smart enough to not use
Carmen::country_code(name) when name is blank since Carmen::country_code
currently has a bug where Carmen::country_code('') == 'AF'.

Added a similar workaround for this bug in country_name.
d38baa2
Tyler Rick Added Address#identical? b1c32ec
Commits on Aug 19, 2011
Tyler Rick Used 'bundle gem' command to generate a cleaner gemspec than Jeweler
provides. Reorganized things a bit.
654212e
Tyler Rick Added carmen as a dependency since it is used by the country_name method d7de4fd
Commits on Aug 21, 2011
Tyler Rick Added rspec e4c4a71
Tyler Rick Repurposed country column to be used for storing country *name* instead
of code. Added country_code2 column to store ISO 3166-1 alpha-2 codes
(and country_code3 for future expansion).

Now you can set the country either by using the country= writer (if you
want to use a country name as input) or the country_code= writer (if you
want to use a country code as input). It will automatically update the
other column for you and keep both of them up-to-date.

Added some special handling of UK countries, since Carmen doesn't
recognize 'England', etc. as countries but we want to allow those
country names to be stored since they are kind of an important part of
the address.

Rewrote parts and readable_parts (renamed to lines) to make more concise
and readable. Fixed problem with readable_parts where it added a comma
before postal code.

Added attribute_normalizer dependency and cleanlines normalizer for address.

Added active_record_ignored_attributes, which provides the same_as?
comparison method. (Removed the identical? method I had added
previously.)

Added fairly comprehensive suite of tests
fc41540
Tyler Rick Added has_address/has_addresses macro methods
Added tests for has_one/has_many associations
42ac250
Commits on Aug 24, 2011
Tyler Rick more work in progress e6ad306
Commits on Dec 09, 2011
Tyler Rick added empty? 1abba46
Commits on Nov 29, 2012
Tyler Rick Removed AddressEngine::Version constant because it was causing all Ac…
…tiveRecord

models to also have a Version constant defined in them due to the module being
included into ActiveRecord::Base. This meant that referencing Version from
within my User model caused it to reference this version number instead of (as
intended) referencing the class named Version.
6003b72
Commits on Jan 14, 2014
@TylerRick TylerRick Updated gems and got specs passing again 480847d
@TylerRick TylerRick Remove belongs_to :addressable from Address, as some apps may want to…
… define a belongs_to :address

instead (or separate belongs_to :physical_address and belongs_to :mailing_address).
aa0c32d
Something went wrong with that request. Please try again.