BACKWARD INCOMPATIBLE! This update requires the User and Group objects to have a FK to the Organization ID (not the name as we've been doing). Do not try using this until the db tables have been adjusted. In this update: swappabel model support, migration of some permission functions, AST-based importing to prevent circular imports, better method of specifying tables to preserve during flush (currently only permissions use this)
remaining references to 'whitelabel' removed from baph, replaced with auto-named organization relation.
Updates for new permission system
removed debug printing
removed unused (broken) imports
added unique key to Oauth Consumer model (InnoDB break if trying to set a FK to a non-indexed column)
Adjustments to permission system to handle composite keys during permission checks
Merge branch 'master' of github.com:dieselmachine/baph
permission updates (permission routing to parent objects, and other adjustments)
forgot this
added helper properties to base model

Conflicts:

	baph/db/models/base.py
removed some debug lines

Conflicts:

	baph/core/management/commands/shell.py
to_dict added to base Model (so we won't need to include Model in class declarations)
Merge remote-tracking branch 'dieselmachine/master' into develop