Changes between Version 1 and Version 2 of Ticket #2259, comment 29
- Timestamp:
- Nov 6, 2013, 4:53:06 AM (11 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #2259, comment 29
v1 v2 1 The proposed solution works for ModelAdmin forms, however it doesn't work with InlineModelAdmin as `get_readonly_fields` is passed the parent object, not the object regarding the InlineModelAdmin. Discussing with akaariair the solution could be found by setting `editable=models.EDITABLE_ON_INSERT`, using a fastened deprecation, as the default for primary key fields. 1 The proposed solution works for ModelAdmin forms, however it doesn't work with InlineModelAdmin as `get_readonly_fields` is passed the parent object, not the object regarding the InlineModelAdmin. Discussing with akaariair the solution could be found by setting `editable=models.EDITABLE_ON_INSERT`, using a fastened deprecation, as the default for primary key fields. However I'm not familiar with the inner workings of modelform factories and cannot own this ticket.