core.paginator.Page.has_next()

Page.has_next() [source] Returns True if there’s a next page.

core.paginator.Page.end_index()

Page.end_index() [source] Returns the 1-based index of the last object on the page, relative to all of the objects in the paginator’s list. For example, when paginating a list of 5 objects with 2 objects per page, the second page’s end_index() would return 4.

core.paginator.Page

class Page(object_list, number, paginator) [source] A page acts like a sequence of Page.object_list when using len() or iterating it directly.

core.management.LabelCommand.handle_label()

LabelCommand.handle_label(label, **options) Perform the command’s actions for label, which will be the string as given on the command line.

core.management.LabelCommand

class LabelCommand A management command which takes one or more arbitrary arguments (labels) on the command line, and does something with each of them. Rather than implementing handle(), subclasses must implement handle_label(), which will be called once for each label.

core.management.call_command()

django.core.management.call_command(name, *args, **options) To call a management command from code use call_command.

core.management.BaseCommand.style

BaseCommand.style An instance attribute that helps create colored output when writing to stdout or stderr. For example: self.stdout.write(self.style.SUCCESS('...')) See Syntax coloring to learn how to modify the color palette and to see the available styles (use uppercased versions of the “roles” described in that section). If you pass the --no-color option when running your command, all self.style() calls will return the original string uncolored.

core.management.BaseCommand.requires_system_checks

BaseCommand.requires_system_checks A boolean; if True, the entire Django project will be checked for potential problems prior to executing the command. Default value is True.

core.management.BaseCommand.requires_migrations_checks

BaseCommand.requires_migrations_checks New in Django 1.10. A boolean; if True, the command prints a warning if the set of migrations on disk don’t match the migrations in the database. A warning doesn’t prevent the command from executing. Default value is False.

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.