Skip to content

Commit f4b6dac

Browse files
committed
Import telechat dates from the "telechat" table
- Legacy-Id: 3794
1 parent 47df26a commit f4b6dac

2 files changed

Lines changed: 22 additions & 2 deletions

File tree

ietf/iesg/models.py

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@
5252
# verbose_name = "Telechat Minute Text"
5353
# verbose_name_plural = "Telechat Minutes"
5454

55+
# this model is deprecated
5556
class TelechatDates(models.Model):
5657
date1 = models.DateField(primary_key=True, null=True, blank=True)
5758
date2 = models.DateField(null=True, blank=True)
@@ -126,6 +127,18 @@ class Meta:
126127
ordering = ['-telechat_date']
127128
verbose_name = "WG Action"
128129

130+
class Telechat(models.Model):
131+
telechat_id = models.IntegerField(primary_key=True)
132+
telechat_date = models.DateField(null=True, blank=True)
133+
minute_approved = models.IntegerField(null=True, blank=True)
134+
wg_news_txt = models.TextField(blank=True)
135+
iab_news_txt = models.TextField(blank=True)
136+
management_issue = models.TextField(blank=True)
137+
frozen = models.IntegerField(null=True, blank=True)
138+
mi_frozen = models.IntegerField(null=True, blank=True)
139+
class Meta:
140+
db_table = u'telechat'
141+
129142

130143
def next_telechat_date():
131144
dates = TelechatDate.objects.order_by("-date")

redesign/importing/import-groups.py

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,10 @@
2121
from redesign.importing.utils import old_person_to_person
2222
from ietf.idtracker.models import AreaGroup, IETFWG, Area, AreaGroup, Acronym, AreaWGURL, IRTF, ChairsHistory, Role, AreaDirector
2323
from ietf.liaisons.models import SDOs
24-
from ietf.iesg.models import TelechatDates, TelechatDate
24+
from ietf.iesg.models import TelechatDates, Telechat, TelechatDate
2525
import workflows.utils
2626

27-
# imports IETFWG, Area, AreaGroup, Acronym, IRTF, AreaWGURL, SDOs, TelechatDates
27+
# imports IETFWG, Area, AreaGroup, Acronym, IRTF, AreaWGURL, SDOs, TelechatDates, dates from Telechat
2828

2929
# also creates nomcom groups
3030

@@ -117,6 +117,13 @@
117117

118118
system = Person.objects.get(name="(System)")
119119

120+
for o in Telechat.objects.all().order_by("pk"):
121+
if o.pk <= 3:
122+
print "skipping phony Telechat", o.pk
123+
continue
124+
print "importing Telechat", o.pk, o.telechat_date
125+
TelechatDate.objects.get_or_create(date=o.telechat_date)
126+
120127
for o in TelechatDates.objects.all():
121128
print "importing TelechatDates"
122129
for x in range(1, 5):

0 commit comments

Comments
 (0)