I added a new validator to oscar.core.validators that validates
absolute and relative URL and checks if the URL already exists. We
use this functionality when creating flatpages in the dashboard to
check if the URL can be used.
The validation includes *two* calls to ExtendedURLValidator to
validate the URL in the first run and then check if it already
exists in the second. This might not be the most efficient way
of handling it. The reason to do it that way is that it reduces
the amount of code that has to be replicated.
more updates to the ExtendedURLValidator, missing the '/' is bad. Explicitly set APPEND_SLASH to True in test settings so that it's clear that we expect it to be on
Clean up the management command. Wrap the handle call in try and except with a custom error log catcher which sends to stderr steam and supresses the exception.
Wrote a bunch of tests that work around the CatalogueImportException being thrown from the util.py classes
Massive set of changes to the util classes - moved the file checks out to their own class, added a csv reader class, added flush capabilities to flush out the product and stock models before importing, added a mapper to map the csv content against a "model.field" map - this is only very early stages and is currently not finished
Tests for running file checks, but not tests against csv or mapping functionality yet.
Added some basic price/tax calculation methods to the core stock record.
This seems to be a simpler and better place for the price calculation at
the moment. We could introduce a calculator object at some point to
separate the responsibilities.