Changes between Initial Version and Version 5 of Ticket #34402


Ignore:
Timestamp:
Mar 14, 2023, 9:55:03 AM (21 months ago)
Author:
Pavel Pančocha
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #34402

    • Property Triage Stage UnreviewedAccepted
    • Property Summary Admin searchfields for inherited modelAdmin search_fields crashes for inherited model and __iexact lookup.
  • Ticket #34402 – Description

    initial v5  
    2828}}}
    2929
    30 Guess what? The "id" variant works ok and the "pk" fails with
     30Guess what? The "id" variant works ok and the "pk" fails with `Related Field got invalid lookup: iexact`
    3131
    3232Why? Because in `construct_search` ([[https://github.com/django/django/blob/4b1bfea2846f66f504265cec46ee1fe94ee9c98b/django/contrib/admin/options.py#L1123|See Git]]) it's transformed to `pk__iexact__icontains` as it found out that the `pk` is `payer_ptr` which is FK.
Back to Top