Opened 10 years ago
Closed 10 years ago
#25449 closed Cleanup/optimization (fixed)
django.contrib.gis.admin is missing @register
| Reported by: | Manel Clos | Owned by: | nobody |
|---|---|---|---|
| Component: | GIS | Version: | 1.8 |
| Severity: | Normal | Keywords: | |
| Cc: | Triage Stage: | Unreviewed | |
| Has patch: | no | Needs documentation: | no |
| Needs tests: | no | Patch needs improvement: | no |
| Easy pickings: | yes | UI/UX: | no |
Description
This code:
from django.contrib.gis import admin
@admin.register(MyModel)
class MyModelAdmin(....)
...
Produces: AttributeError: 'module' object has no attribute 'register'
Plain admin works ok:
from django.contrib import admin
@admin.register(MyModel)
class MyModelAdmin(....)
...
Change History (1)
comment:1 by , 10 years ago
| Resolution: | → fixed |
|---|---|
| Status: | new → closed |
| Type: | Uncategorized → Cleanup/optimization |
Note:
See TracTickets
for help on using tickets.
Fixed in cc3d2fa73102e8ee29c401438bd849eea725198a (for Django 1.9).