Added many assocations, and custom queries.
Added lost and failed orders.
bugfixes for associations
Finished order infrastructure, and cleaned bugs