test.TransactionTestCase.available_apps

TransactionTestCase.available_apps Warning This attribute is a private API. It may be changed or removed without a deprecation period in the future, for instance to accommodate changes in application loading. It’s used to optimize Django’s own test suite, which contains hundreds of models but no relations between models in different applications. By default, available_apps is set to None. After each test, Django calls flush to reset the database state. This empties all tables and emits the

core.management.BaseCommand.output_transaction

BaseCommand.output_transaction A boolean indicating whether the command outputs SQL statements; if True, the output will automatically be wrapped with BEGIN; and COMMIT;. Default value is False.

http.HttpRequest.method

HttpRequest.method A string representing the HTTP method used in the request. This is guaranteed to be uppercase. Example: if request.method == 'GET': do_something() elif request.method == 'POST': do_something_else()

http.HttpRequest.site

HttpRequest.site From the CurrentSiteMiddleware: An instance of Site or RequestSite as returned by get_current_site() representing the current site.

gis.db.models.functions.Scale

class Scale(expression, x, y, z=0.0, **extra) Availability: PostGIS, SpatiaLite Accepts a single geographic field or expression and returns a geometry with scaled coordinates by multiplying them with the x, y, and optionally z parameters.

db.models.SET_DEFAULT

SET_DEFAULT [source] Set the ForeignKey to its default value; a default for the ForeignKey must be set.

auth.hashers.make_password()

make_password(password, salt=None, hasher='default') [source] Creates a hashed password in the format used by this application. It takes one mandatory argument: the password in plain-text. Optionally, you can provide a salt and a hashing algorithm to use, if you don’t want to use the defaults (first entry of PASSWORD_HASHERS setting). See Included hashers for the algorithm name of each hasher. If the password argument is None, an unusable password is returned (a one that will be never accept

http.HttpRequest.resolver_match

HttpRequest.resolver_match An instance of ResolverMatch representing the resolved URL. This attribute is only set after URL resolving took place, which means it’s available in all views but not in middleware which are executed before URL resolving takes place (you can use it in process_view() though).

gis.geos.fromstr()

fromstr(string, srid=None) Parameters: string (string) – string that contains spatial data srid (int) – spatial reference identifier Return type: a GEOSGeometry corresponding to the spatial data in the string fromstr(string, srid) is equivalent to GEOSGeometry(string, srid). Example: >>> from django.contrib.gis.geos import fromstr >>> pnt = fromstr('POINT(-90.5 29.5)', srid=4326)

forms.models.modelformset_factory()

modelformset_factory(model, form=ModelForm, formfield_callback=None, formset=BaseModelFormSet, extra=1, can_delete=False, can_order=False, max_num=None, fields=None, exclude=None, widgets=None, validate_max=False, localized_fields=None, labels=None, help_texts=None, error_messages=None, min_num=None, validate_min=False, field_classes=None) [source] Returns a FormSet class for the given model class. Arguments model, form, fields, exclude, formfield_callback, widgets, localized_fields, labels,