Minor refactor: extract gateway order id to method

This will allow people to more easily override the order id passed
in to the payment gateway.  It will behave the same for existing
functionality.

I want to override this in one of our extensions, and this will allow me to do so without as much code duplication.