Make key access consistently symbols
Dont blow existing code using Order#build_from_api

Avoid errors after d496f6e08147742c3f8b2dfdea6d97e3f44b97e6. The
adjustments hash was accessed using strings as keys. eg. a["amount"]
Bump rabl to 0.9.3
Add apply_promo_code endpoint

This commit adds the necessary logic to apply a promo code to an order against the API. The RESTful contract was structured in a way to be identical with the eventual API endpoint in Spree master, as implemented in this commit.

https://github.com/spree/spree/commit/72a5b74c47af975fc3492580415a4cdc2dc02c0c

Fixes #4258
set default for api config require_authentication back to true.

skip filters on frontend for coupon_code bypass the require_authentication setting on backend specs.

Signed-off-by: Peter Berkenbosch <peter@pero-ict.nl>

Fixes #4165
typo on spec_helper template for extensions

Fixes #4247
using completed_at rather than created_at for more accurate sales total report

Fixes #4205
Ensure that a deleted product can still be viewed in the admin backend

Conflicts:
	core/app/models/spree/price.rb
	core/app/models/spree/variant.rb
[backend] Fix fields used in reports_spec test
Fix a couple of Order#is_risky bugs

Fixes #4261
Fixes #4260
[api] Specify key for products collection in products/index.v1.rabl, otherwise it is 'spree_products'
[api] apply_coupon_code endpoint requires order_token due to #4165
Use key :stock_items for stock items returned in big_variant, otherwise this uses 'spree_stock_items'
Move report order criteria view to backend + fix translations
make sure the options are actually created.

Fixes #4271
Fixes #4273
[api] Do not run milliseconds precision on MySQL because MySQL does not do milliseconds
[backend] Fix issue where credit card payments were not transitioning

Fixes #4276
Fixes #4277
allow stock location state translation

Fixes #4823
add missing admin products submenu translations

this does not change nothing on en locale (tab() helper has fallback values) but it's good as reference for other locales. Makes sense?

Fixes #4284
In memory sort of variant.options_text

Assume that the option_values -> option_types have been eager loaded via joins/includes and simply sort in memory. Removing the explicit query removes N queries for products/show in the api where N = number of variants that belong to the product. This should allow us to fully take advantage of the API optimization made here:

https://github.com/spree/spree/commit/30597b2aa7a1f47b5e636750baf7c100f0cc42b2

Fixes #4294