Skip to content

Commit e379df0

Browse files
committed
Removed the obsolete field Group._ad, and added a migration for the change.
- Legacy-Id: 9147
1 parent e9fcce9 commit e379df0

3 files changed

Lines changed: 24 additions & 3 deletions

File tree

ietf/group/admin.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ class GroupAdmin(admin.ModelAdmin):
2626
list_filter = ["type", "state", "time"]
2727
search_fields = ["acronym", "name"]
2828
ordering = ["name"]
29-
raw_id_fields = ["charter", "parent", "_ad"]
29+
raw_id_fields = ["charter", "parent"]
3030
inlines = [RoleInline, GroupURLInline]
3131
prepopulated_fields = {"acronym": ("name", )}
3232

@@ -107,7 +107,7 @@ class GroupHistoryAdmin(admin.ModelAdmin):
107107
list_filter = ["type"]
108108
search_fields = ["acronym", "name"]
109109
ordering = ["name"]
110-
raw_id_fields = ["group", "parent", "_ad"]
110+
raw_id_fields = ["group", "parent"]
111111

112112
admin.site.register(GroupHistory, GroupHistoryAdmin)
113113

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
# -*- coding: utf-8 -*-
2+
from __future__ import unicode_literals
3+
4+
from django.db import models, migrations
5+
6+
7+
class Migration(migrations.Migration):
8+
9+
dependencies = [
10+
('group', '0002_auto_20150208_1012'),
11+
]
12+
13+
operations = [
14+
migrations.RemoveField(
15+
model_name='group',
16+
name='ad',
17+
),
18+
migrations.RemoveField(
19+
model_name='grouphistory',
20+
name='ad',
21+
),
22+
]

ietf/group/models.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@ class GroupInfo(models.Model):
1818
type = models.ForeignKey(GroupTypeName, null=True)
1919
parent = models.ForeignKey('Group', blank=True, null=True)
2020
description = models.TextField(blank=True)
21-
_ad = models.ForeignKey(Person, verbose_name="AD", blank=True, null=True, db_column="ad_id")
2221
list_email = models.CharField(max_length=64, blank=True)
2322
list_subscribe = models.CharField(max_length=255, blank=True)
2423
list_archive = models.CharField(max_length=255, blank=True)

0 commit comments

Comments
 (0)