Prepare for order coupon editing, fix order history for immutable orders