Django

Code

Changeset 4392

Show
Ignore:
Timestamp:
01/22/07 20:01:20 (2 years ago)
Author:
adrian
Message:

Fixed #3346 -- Documented that search_fields Admin option can use related models. Thanks for the patch, Robert Myers and Gary Wilson

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • django/trunk/docs/model-api.txt

    r4309 r4392  
    14091409 
    14101410These fields should be some kind of text field, such as ``CharField`` or 
    1411 ``TextField``. 
     1411``TextField``. You can also perform a related lookup on a ``ForeignKey`` with  
     1412the lookup API "follow" notation:: 
     1413 
     1414    search_fields = ['foreign_key__related_fieldname'] 
    14121415 
    14131416When somebody does a search in the admin search box, Django splits the search