#2059 closed enhancement (duplicate)
attempting to edit_inline an object with a unique field yields TypeError
| Reported by: | Owned by: | Adrian Holovaty | |
|---|---|---|---|
| Component: | Core (Management commands) | Version: | new-admin |
| Severity: | trivial | Keywords: | edit_inline unique TypeError |
| Cc: | Triage Stage: | Unreviewed | |
| Has patch: | no | Needs documentation: | no |
| Needs tests: | no | Patch needs improvement: | no |
| Easy pickings: | no | UI/UX: | no |
Description
from django.db import models
class Address(models.Model):
street1 = models.CharField(maxlength=50)
def str(self):
return self.street1
class Admin:
search_fields = street1
class Dog(models.Model):
address = models.ForeignKey(Address,edit_inline=models.TABULAR)
# use the following line and it works fine
# name = models.CharField(maxlength=20,core=True)
# use the following line with SVN update revision code 3045 to get the following exception
name = models.CharField(maxlength=20,unique=True,core=True)
# Exception Value: Cannot resolve keyword 'name' into field
# Exception Location: /usr/lib/python2.4/site-packages/django/db/models/query.py in lookup_inner, line 800
def str(self):
return self.name
# May (or may not) relate to ticket # 565
Change History (4)
comment:1 by , 19 years ago
| Component: | Admin interface → django-admin.py |
|---|---|
| milestone: | → Version 0.93 |
| priority: | normal → low |
| Severity: | normal → trivial |
| Type: | defect → enhancement |
| Version: | SVN → new-admin |
comment:2 by , 19 years ago
| milestone: | Version 0.93 → Version 1.0 |
|---|
comment:3 by , 19 years ago
| Resolution: | → duplicate |
|---|---|
| Status: | new → closed |
This is a duplicate of #565
0.93 has come and gone.