refactor sale form