Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update contrib.admin.options.ModelAdmin #2422

Merged
merged 1 commit into from
Dec 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions django-stubs/contrib/admin/options.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,7 @@ class ModelAdmin(BaseModelAdmin[_ModelT]):
def log_addition(self, request: HttpRequest, obj: _ModelT, message: Any) -> LogEntry: ...
def log_change(self, request: HttpRequest, obj: _ModelT, message: Any) -> LogEntry: ...
def log_deletion(self, request: HttpRequest, obj: _ModelT, object_repr: str) -> LogEntry: ...
def log_deletions(self, request: HttpRequest, queryset: QuerySet[_ModelT]) -> list[LogEntry] | LogEntry: ...
def action_checkbox(self, obj: _ModelT) -> SafeString: ...
def get_actions(self, request: HttpRequest) -> dict[str, tuple[Callable[..., str], str, str] | None]: ...
def get_action_choices(
Expand Down
3 changes: 0 additions & 3 deletions scripts/stubtest/allowlist_todo_django51.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,9 @@
# Only discrepancies that appeared after Django 5.0 -> 5.1 update.
# Unsorted: there are real problems and things we can really ignore:

django.contrib.admin.ModelAdmin.log_deletions
django.contrib.admin.helpers.Fieldset.is_collapsible
django.contrib.admin.helpers.InlineAdminFormSet.is_collapsible
django.contrib.admin.models.LogEntryManager.log_actions
django.contrib.admin.options.ModelAdmin.log_deletions
django.contrib.auth.base_user.BaseUserManager.make_random_password
django.contrib.auth.checks.check_middleware
django.contrib.auth.forms.AdminPasswordChangeForm.clean_password2
Expand All @@ -25,7 +23,6 @@ django.contrib.auth.models.BaseUserManager.make_random_password
django.contrib.contenttypes.fields.GenericForeignKey.cache_name
django.contrib.contenttypes.fields.GenericForeignKey.get_attname_column
django.contrib.contenttypes.models.ContentType.get_object_for_this_type
django.contrib.gis.admin.ModelAdmin.log_deletions
django.contrib.gis.db.backends.mysql.operations.MySQLOperations.collect
django.contrib.gis.db.models.CharField.slice_expression
django.contrib.gis.db.models.CheckConstraint.__init__
Expand Down
Loading