Merge lp:~daker/loco-team-portal/fix.706742 into lp:loco-team-portal

Proposed by Adnane Belmadiaf
Status: Merged
Approved by: Adnane Belmadiaf
Approved revision: 643
Merged at revision: 641
Proposed branch: lp:~daker/loco-team-portal/fix.706742
Merge into: lp:loco-team-portal
Diff against target: 43 lines (+9/-5)
2 files modified
loco_directory/meetings/forms.py (+8/-4)
loco_directory/meetings/models.py (+1/-1)
To merge this branch: bzr merge lp:~daker/loco-team-portal/fix.706742
Reviewer Review Type Date Requested Status
LoCo Team Portal Developers Pending
Review via email: mp+158829@code.launchpad.net

Commit message

Fixed bug 706742, props svwilliams

To post a comment you must log in.
642. By Adnane Belmadiaf

Reverted a stupid ctrl+v

643. By Adnane Belmadiaf

Fixed the help text

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'loco_directory/meetings/forms.py'
--- loco_directory/meetings/forms.py 2013-02-17 01:44:52 +0000
+++ loco_directory/meetings/forms.py 2013-04-14 23:41:24 +0000
@@ -67,8 +67,9 @@
67 'channel',67 'channel',
68 'minutes',68 'minutes',
69 'chair',69 'chair',
70 'logs'
70 )71 )
71 exclude = ('teams', 'date_created', 'logs')72 exclude = ('teams', 'date_created')
7273
73 def __init__(self, teams=None, *args, **kargs):74 def __init__(self, teams=None, *args, **kargs):
74 super(TeamMeetingForm, self).__init__(*args, **kargs)75 super(TeamMeetingForm, self).__init__(*args, **kargs)
@@ -107,9 +108,12 @@
107108
108 def save(self):109 def save(self):
109 start_date = self.cleaned_data['date_begin']110 start_date = self.cleaned_data['date_begin']
110 self.instance.logs = 'http://irclogs.ubuntu.com/%(date)s/%(channel)s.html#t%(time)s' % {'date': start_date.strftime('%Y/%m/%d'),111 if self.instance.logs is None or "http://irclogs.ubuntu.com" in self.instance.logs:
111 'channel': urllib.quote(u'%s' % self.cleaned_data['channel'].encode('ascii', 'ignore')),112 self.instance.logs = 'http://irclogs.ubuntu.com/%(date)s/%(channel)s.html#t%(time)s' % {
112 'time': start_date.strftime('%H:%M')}113 'date': start_date.strftime('%Y/%m/%d'),
114 'channel': urllib.quote(u'%s' % self.cleaned_data['channel'].encode('ascii', 'ignore')),
115 'time': start_date.strftime('%H:%M')
116 }
113 return super(TeamMeetingForm, self).save()117 return super(TeamMeetingForm, self).save()
114118
115119
116120
=== modified file 'loco_directory/meetings/models.py'
--- loco_directory/meetings/models.py 2012-12-12 23:47:58 +0000
+++ loco_directory/meetings/models.py 2013-04-14 23:41:24 +0000
@@ -17,7 +17,7 @@
17 date_begin = models.DateTimeField(help_text=_('Local date and time that the meeting starts'), verbose_name=_('Begins'), db_index=True)17 date_begin = models.DateTimeField(help_text=_('Local date and time that the meeting starts'), verbose_name=_('Begins'), db_index=True)
18 date_end = models.DateTimeField(help_text=_('Local date and time that the meeting ends'), verbose_name=_('Ends'), db_index=True)18 date_end = models.DateTimeField(help_text=_('Local date and time that the meeting ends'), verbose_name=_('Ends'), db_index=True)
19 channel = models.CharField(max_length=150, verbose_name=_('Meeting Channel'), help_text=_('Channel that the meeting will be held in. Ex. #ubuntu-us-fl'), null=True)19 channel = models.CharField(max_length=150, verbose_name=_('Meeting Channel'), help_text=_('Channel that the meeting will be held in. Ex. #ubuntu-us-fl'), null=True)
20 logs = models.URLField(verbose_name=_('Meeting Log'), help_text=_('After the meeting, add a link to the meeting log'), max_length=200, verify_exists=False, blank=True, null=True)20 logs = models.URLField(verbose_name=_('Meeting Log'), help_text=_('After the meeting, add a link to the meeting log (leave blank to use the built-in irclog.ubuntu.com'), max_length=200, verify_exists=False, blank=True, null=True)
21 minutes = models.URLField(verbose_name=_('Meeting Minutes'), help_text=_('After the meeting, add a link to the meeting minutes'), max_length=200, verify_exists=False, blank=True, null=True)21 minutes = models.URLField(verbose_name=_('Meeting Minutes'), help_text=_('After the meeting, add a link to the meeting minutes'), max_length=200, verify_exists=False, blank=True, null=True)
22 date_created = models.DateTimeField(help_text=_('the date and time when the event was created'), default=datetime.datetime.now(), db_index=True)22 date_created = models.DateTimeField(help_text=_('the date and time when the event was created'), default=datetime.datetime.now(), db_index=True)
23 chair = models.ForeignKey(UserProfile, verbose_name=_('Meeting Chair'), blank=True, null=True)23 chair = models.ForeignKey(UserProfile, verbose_name=_('Meeting Chair'), blank=True, null=True)

Subscribers

People subscribed via source and target branches