Mercurial > public > madeira
changeset 169:5ab9bd1b22b6
Merge.
author | Brian Neal <bgneal@gmail.com> |
---|---|
date | Thu, 02 Apr 2015 21:05:58 -0500 |
parents | 8a93b1f838f9 (current diff) 1b5b9be17764 (diff) |
children | a51e7d369472 |
files | |
diffstat | 7 files changed, 23 insertions(+), 17 deletions(-) [+] |
line wrap: on
line diff
--- a/band/models.py Thu Apr 02 21:04:08 2015 -0500 +++ b/band/models.py Thu Apr 02 21:05:58 2015 -0500 @@ -15,7 +15,7 @@ photo = models.ImageField(upload_to='images/bio/', blank=True) order = models.SmallIntegerField( help_text = "Controls order of display; lower numbers displayed first") - is_active = models.BooleanField() + is_active = models.BooleanField(default=True) start_date = models.DateField() end_date = models.DateField(blank=True, null=True, @@ -101,7 +101,7 @@ name = models.CharField(max_length=64) desc = models.TextField() price = models.DecimalField(max_digits=5, decimal_places=2) - in_stock = models.BooleanField() + in_stock = models.BooleanField(default=True) photo = models.ForeignKey(Photo) def __unicode__(self):
--- a/email_list/tests/test_models.py Thu Apr 02 21:04:08 2015 -0500 +++ b/email_list/tests/test_models.py Thu Apr 02 21:05:58 2015 -0500 @@ -21,8 +21,8 @@ self.assertTrue(sub.status == 'A') self.assertTrue(sub.is_active()) - self.failIf(sub.is_pending()) - self.failIf(sub.is_leaving()) + self.assertFalse(sub.is_pending()) + self.assertFalse(sub.is_leaving()) def test_set_pending(self): @@ -33,9 +33,9 @@ self.assertTrue(now - sub.status_date < datetime.timedelta(seconds=2)) self.assertTrue(sub.status == 'P') - self.failIf(sub.is_active()) + self.assertFalse(sub.is_active()) self.assertTrue(sub.is_pending()) - self.failIf(sub.is_leaving()) + self.assertFalse(sub.is_leaving()) self.assertTrue(len(sub.key) == sub.key_length) @@ -49,8 +49,8 @@ self.assertTrue(sub.status == 'A') self.assertTrue(sub.is_active()) - self.failIf(sub.is_pending()) - self.failIf(sub.is_leaving()) + self.assertFalse(sub.is_pending()) + self.assertFalse(sub.is_leaving()) def test_set_leaving(self): @@ -61,8 +61,8 @@ self.assertTrue(now - sub.status_date < datetime.timedelta(seconds=2)) self.assertTrue(sub.status == 'L') - self.failIf(sub.is_active()) - self.failIf(sub.is_pending()) + self.assertFalse(sub.is_active()) + self.assertFalse(sub.is_pending()) self.assertTrue(sub.is_leaving()) self.assertTrue(len(sub.key) == sub.key_length)
--- a/gigs/templatetags/gig_tags.py Thu Apr 02 21:04:08 2015 -0500 +++ b/gigs/templatetags/gig_tags.py Thu Apr 02 21:05:58 2015 -0500 @@ -15,7 +15,8 @@ @register.inclusion_tag('gigs/upcoming_gigs_tag.html') def upcoming_gigs(): - gigs = Gig.objects.filter(date__gte=datetime.date.today).select_related( + today = datetime.date.today() + gigs = Gig.objects.filter(date__gte=today).select_related( 'flyer', 'venue', 'venue__city', 'venue__city__state', 'venue__city__country').order_by('date')[:10]
--- a/madeira/apache/madeira.wsgi Thu Apr 02 21:04:08 2015 -0500 +++ b/madeira/apache/madeira.wsgi Thu Apr 02 21:05:58 2015 -0500 @@ -32,7 +32,7 @@ if not OFFLINE: os.environ['DJANGO_SETTINGS_MODULE'] = 'madeira.settings.production' - import django.core.handlers.wsgi - application = django.core.handlers.wsgi.WSGIHandler() + from django.core.wsgi import get_wsgi_application + application = get_wsgi_application() else: - application = offline_handler + application = offline_handler
--- a/madeira/settings/base.py Thu Apr 02 21:04:08 2015 -0500 +++ b/madeira/settings/base.py Thu Apr 02 21:05:58 2015 -0500 @@ -111,6 +111,9 @@ 'photologue', ] +# Turn off warning about test runner behavior change +SILENCED_SYSTEM_CHECKS = ['1_6.W001'] + ####################################################################### # Messages #######################################################################
--- a/madeira/templates/admin/base_site.html Thu Apr 02 21:04:08 2015 -0500 +++ b/madeira/templates/admin/base_site.html Thu Apr 02 21:05:58 2015 -0500 @@ -10,4 +10,8 @@ <h1 id="site-name">{% trans 'Madeira site administration' %}</h1> {% endblock %} -{% block nav-global %}<a href="{% url 'admin:email_list-admin_mail' %}" style="margin-left: 1.5em">Send mail to the mailing list</a>{% endblock %} +{% block nav-global %} +<div class="clear" style="margin: 1.5em 0 1.0em 1.5em"> +ยป <a href="{% url 'admin:email_list-admin_mail' %}">Send mail to the mailing list</a> +</div> +{% endblock %}