From 8097e5483210fa8c9d6142f1d48e1caed6d7b7bb Mon Sep 17 00:00:00 2001 From: Claude Paroz Date: Sat, 4 Apr 2015 18:07:46 +0200 Subject: Fixed #23879 -- Allowed model migration skip based on feature/vendor Thanks Carl Meyer for the report and review, and Tim Graham for the review. --- docs/ref/models/options.txt | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) (limited to 'docs/ref') diff --git a/docs/ref/models/options.txt b/docs/ref/models/options.txt index 2f4f5aff71..f9a17721cf 100644 --- a/docs/ref/models/options.txt +++ b/docs/ref/models/options.txt @@ -283,6 +283,31 @@ Django quotes column and table names behind the scenes. If ``proxy = True``, a model which subclasses another model will be treated as a :ref:`proxy model `. +``required_db_features`` +------------------------ + +.. attribute:: Options.required_db_features + + .. versionadded:: 1.9 + + List of database features that the current connection should have so that + the model is considered during the migration phase. For example, if you set + this list to ``['gis_enabled']``, the model will only be synchronized on + GIS-enabled databases. It's also useful to skip some models when testing + with several database backends. + +``required_db_vendor`` +---------------------- + +.. attribute:: Options.required_db_vendor + + .. versionadded:: 1.9 + + Name of a supported database vendor that this model is specific to. Current + built-in vendor names are: ``sqlite``, ``postgresql``, ``mysql``, + ``oracle``. If this attribute is not empty and the current connection vendor + doesn't match it, the model will not be synchronized. + ``select_on_save`` ------------------ -- cgit v1.3