Mercurial > public > bravenewsurf
changeset 30:4eaaf3809385
Merge with Reviews template changes.
author | Brian Neal <bgneal@gmail.com> |
---|---|
date | Fri, 04 Nov 2011 20:02:15 -0500 |
parents | 20dc7be59c85 (diff) ced908af601a (current diff) |
children | 9b62e4eef794 |
files | bns_website/templates/reviews/review_list.html |
diffstat | 3 files changed, 22 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/bns_website/reviews/models.py Fri Nov 04 19:26:48 2011 -0500 +++ b/bns_website/reviews/models.py Fri Nov 04 20:02:15 2011 -0500 @@ -10,7 +10,7 @@ This model represents all the info we store about each review. """ date = models.DateField(auto_now_add=True) - title = models.CharField(max_length=200, blank=True) + title = models.CharField(max_length=200) reviewer = models.CharField(max_length=200) review_site = models.CharField(max_length=200, blank=True) review_url = models.URLField(verify_exists=False, max_length=256, blank=True) @@ -18,6 +18,7 @@ class Meta: verbose_name_plural = "Reviews" + ordering = ['-date'] def __unicode__(self): return self.reviewer
--- a/bns_website/static/css/base.css Fri Nov 04 19:26:48 2011 -0500 +++ b/bns_website/static/css/base.css Fri Nov 04 20:02:15 2011 -0500 @@ -1,5 +1,5 @@ body { - padding-top: 40px + padding-top: 60px } .social-sharing { margin-top: 1.5em; @@ -12,3 +12,15 @@ display: inline-block; vertical-align: top; } + +/* +----------------------------------------------- +Reviews Styles +----------------------------------------------- + */ +.reviews ul { + list-style-type: none; +} +.reviews li { + margin-bottom: 30px; +}
--- a/bns_website/templates/reviews/review_list.html Fri Nov 04 19:26:48 2011 -0500 +++ b/bns_website/templates/reviews/review_list.html Fri Nov 04 20:02:15 2011 -0500 @@ -14,12 +14,15 @@ {% navbar 'reviews' %} <h1>Reviews</h1> +<div class="reviews"> <ul> {% for review in object_list %} - <li> - <cite>{{ review.review|safe }}</cite> - <br/><br/>- {{ review.reviewer }} - <a href="{{ review.review_url }}">{{ review.review_url }}</a> - </li> + <li> + <blockquote> + <p>{{ review.review|safe }}</p> + <small>{{ review.reviewer }} - <a href="{{ review.review_url }}">{{ review.review_url }}</a></small> + </blockquote> + </li> {% endfor %} </ul>