This repository has been archived by the owner on Jan 31, 2018. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[bug 1232435] Fixes based on Mike's comments
* switches the counter out for has_any boolean * changes the email subject to make it easier to read * use render_to_string * add data migration to create needed mailing list
- Loading branch information
Showing
5 changed files
with
52 additions
and
26 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
# -*- coding: utf-8 -*- | ||
from __future__ import unicode_literals | ||
|
||
from django.db import migrations, models | ||
|
||
|
||
def add_heartbeat_health(apps, schema_editor): | ||
MailingList = apps.get_model('mailinglist', 'MailingList') | ||
ml = MailingList.objects.create(name='heartbeat_health') | ||
ml.save() | ||
|
||
|
||
def remove_heartbeat_health(apps, schema_editor): | ||
MailingList = apps.get_model('mailinglist', 'MailingList') | ||
MailingList.objects.filter(name='heartbeat_health').delete() | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
dependencies = [ | ||
('heartbeat', '0010_auto_20150806_0712'), | ||
('mailinglist', '0001_initial'), | ||
] | ||
|
||
operations = [ | ||
migrations.RunPython(add_heartbeat_health, remove_heartbeat_health), | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters