Changes between Initial Version and Version 1 of Ticket #22936


Ignore:
Timestamp:
Jul 2, 2014, 9:56:33 AM (10 years ago)
Author:
Tim Graham
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #22936

    • Property Triage Stage UnreviewedAccepted
  • Ticket #22936 – Description

    initial v1  
    55If a custom field needs to do different kind of preparation for some lookups (something that can't be done in get_[db_]prep_value(), it can always provide a lookup subclass that does the right thing for that field type. An example is [https://github.com/django/django/blob/master/django/db/models/fields/__init__.py#L1717 IntegerField and 'lt' and 'gte' lookups]. Providing custom subclasses might be laborious to do if there are a lot of different lookup types that need custom preparation. For that reason a hook for custom fields could still be useful.
    66
    7 Even if we want to left get_db_prep_lookup and get_prep_lookup hooks for custom fields, the base coding belongs into the lookups themselves. Currently the fields are doing work that clearly belongs to the lookup itself.
     7Even if we want to leave get_db_prep_lookup and get_prep_lookup hooks for custom fields, the base coding belongs into the lookups themselves. Currently the fields are doing work that clearly belongs to the lookup itself.
Back to Top