Opened 12 years ago

Closed 12 years ago

Last modified 12 years ago

#19887 closed Cleanup/optimization (fixed)

ModelAdmin.fields and ModelAdmin.fieldset not very detailed documented

Reported by: Patrick Strasser <patrick@…> Owned by: Zbigniew Siciarz
Component: Documentation Version: dev
Severity: Normal Keywords:
Cc: Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

ModelAdmin.fields and ModelAdmin.fieldset are not very detailed documented compared to ModelAdmin.display_list. It is not clear if only fields or callables too can be used, and how to do so. In fact, callables need to be in readonly_fields, which is quite logical after you found out, but no hint is given in the documentation.

This could be presented in comparison to the "list" display properties, where you have to state so if you want to make fields editable.

Maybe noteworth is some hint about callables that you want to make writable. I guess in that case a custom Field would be the Right Thing (?).

Change History (7)

comment:1 by Carl Meyer, 12 years ago

Triage Stage: UnreviewedAccepted
Type: UncategorizedNew feature

I've noticed this omission before; I think it would be reasonable for the fields/fieldsets documentation to make some note of what non-fields are allowed and under what circumstances.

comment:2 by Zbigniew Siciarz, 12 years ago

Owner: changed from nobody to Zbigniew Siciarz
Status: newassigned

comment:3 by Zbigniew Siciarz, 12 years ago

Version: 1.4master

comment:4 by Zbigniew Siciarz, 12 years ago

Has patch: set
Type: New featureCleanup/optimization

comment:5 by Tim Graham <timograham@…>, 12 years ago

Resolution: fixed
Status: assignedclosed

In 722683f508566cf06bcc85f9f1810c3cde80344c:

Fixed #19887 - Noted when callables may be used in ModelAdmin.fields and ModelAdmin.fieldset.

Thanks Patrick Strasser for the suggestion and Zbigniew Siciarz for the patch.

comment:6 by Tim Graham <timograham@…>, 12 years ago

In 89fb1836a8e6115317a08c43dceee985377535fb:

[1.5.x] Fixed #19887 - Noted when callables may be used in ModelAdmin.fields and ModelAdmin.fieldset.

Thanks Patrick Strasser for the suggestion and Zbigniew Siciarz for the patch.

Backport of 722683f508 from master.

comment:7 by Patrick Strasser <patrick@…>, 12 years ago

Wow, now I'm impressed by the fast reaction!

Thanks, and keep up the fine work!

Note: See TracTickets for help on using tickets.
Back to Top