Removes a lot of logic out of the controller and into model per https://github.com/spree/spree/pull/4331