#35542: BoundField's label and help_text and renderer should be properties not
class members
-------------------------------------+-------------------------------------
               Reporter:             |          Owner:  Christophe Henry
  Christophe Henry                   |
                   Type:             |         Status:  assigned
  Uncategorized                      |
              Component:  Forms      |        Version:  5.0
               Severity:  Normal     |       Keywords:
           Triage Stage:             |      Has patch:  1
  Unreviewed                         |
    Needs documentation:  0          |    Needs tests:  0
Patch needs improvement:  0          |  Easy pickings:  0
                  UI/UX:  0          |
-------------------------------------+-------------------------------------
 `BoundField` exposes
 [https://github.com/django/django/blob/main/django/forms/boundfield.py#L23
 label]
 [https://github.com/django/django/blob/main/django/forms/boundfield.py#L27
 help_text] and
 [https://github.com/django/django/blob/main/django/forms/boundfield.py#L28
 renderer], all of them are copies of underlying members of `Field` and
 `Form`.

 This is a bit misleanding since you can modify `Field`s member in `Form`'s
 `__init__` [https://docs.djangoproject.com/en/5.0/ref/forms/fields
 /#fields-which-handle-relationships like documented here] but any
 modification of `help_text`, `label` or `renderer` after
 `super().__init__` won't be reflected on the bound which can leand to
 incomprehensible behavior  in templates
-- 
Ticket URL: <https://code.djangoproject.com/ticket/35542>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107019035a87941-7616b385-fbbd-4d31-9f8e-fbc0e9247147-000000%40eu-central-1.amazonses.com.

Reply via email to