This allows updating code in both places, if necessary. Getting Django
1.5 support would be painful otherwise. This also removes the circular
dependency of django-oscar-testsupport on Oscar.
The requirements were merged. The imports were updated
accordingly. Unused imports in the touched files were removed. No
further changes.
This makes it more efficient to load offers now that we can't simply use
the date filters to exlucde unavailable offers.
The is_active field has been reworked to depend on the
get_max_applications method.
The save method of ConditionalOffer now auto-sets status.
Fixes #403
This allows the total discount of an offer to be capped. It's a
slightly odd mechanism as the offer only becomes inactive once the cap
is exceeded, and it's possible that it is exceeded by a lot.
However, it's still a useful construct for managing offers.
Required several schema changes:
* Add num_applications to offer model to track number of times an offer
has been applied within an order.
* Add max_global_applications to offer model to set a limit on how many times an offer
can be used.
* Add frequency to order discount to provide insight into how many times
an offer was applied for a particular order.
Structure of dashboard changes to talk about offer 'availability'
instead of assuming a start- and end-date.