Some refactoring of sales order to change how effective date works and fix mixin implementation.