Add currency_thousands_separator and currency_decimal_mark config options

This fixes an issue in #2632 where the incorrect decimal mark was being used
Fix issue where all payment method fields were shown on payment screen

Fixes #2785
Fixes #2813
Use separate databases depending on the value of ENV['TC_AGENT_NUMBER']
Set deleted_at timestamp in the past for product_properties_controller +
products_controller tests

This is because MySQL's time columns don't differentiate between events which happen in the same second. PostgreSQL and SQLite do.
Will now test sample using a chain of rake tasks

So that a) we can observe the complete output and b) we can actually debug it
Remove invalid duplicate line-items id in shared/_order_details.html.erb

This has now been moved to the <table> tag which contains both these elements.

Fixes #2836
Fix shipping instructions style.

Fixes #2821
[sample] Call reset_column_information within products

So that Variant#cost_currency is available when running rake db:migrate db:seed
spree_sample:load all at once
no need to check for table to exist before creating a callback on a model inside permalinks.rb
Throw an error if db:migrate runs with spree_sample:load

This is because running these two tasks at the same time produces an error:

http://ci.spreecommerce.com/viewLog.html?buildId=2490&buildTypeId=bt28&tab=buildLog#_focus=335
Add Spree::Config[:max_quantity]

This limits the amount of any one item that can be purchased in Spree.

Related to #2695

Fixes #2826
Making newly entered payments invalidate previously entered payments so the most recent payment is used by the gateway.

Fixes #2828
Use taxon name on taxons/show rather than its accurate_title

Fixes #2814
Factor product scopes to allow simple scopes to be added from an extension

Fixes #2608
Fixes styling issue where email is pulled left out of the info area.

Fixes #2850
Switch the mailers to be invoked using ids, not model objects. This makes it easier to support asynchronous mail jobs, as only simple ids need to be persisted.

Fixes #2808
Really use taxon name in taxons/show.html.erb

Really fixes #2814
Find visible select2-input element within promotion_adjustments_spec
Fix issue where, if using routing-filter, taxon autocomplete would break

Fixes #2248

This is due to the URL provided by spree.admin_search_taxons_url returning something like http://localhost:3000/admin/taxons?locale=en and then the code was appending '?ids=1' to the end of this, which is obviously an incorrect URL.

This new solution is more bulletproof.
Fixes #2788 allowing use of config.threadsafe!

Fixes #2852