modify order.rb and contract.rb