Skip to content

Commit

Permalink
Added partners page
Browse files Browse the repository at this point in the history
Fix for issue #391
  • Loading branch information
Vijay committed Mar 4, 2017
1 parent 9604c75 commit 5a599bd
Show file tree
Hide file tree
Showing 5 changed files with 34 additions and 8 deletions.
Binary file added wye/static/img/supporter/fsmk.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions wye/templates/base.html
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@
<!-- <li><a href="/workshops_upcoming" class="{% if request.resolver_match.url_name == 'upcoming_workshops' %}active{% endif %}">Upcoming Workshops</a></li> -->

<li><a href="/faq" class="{% if request.resolver_match.url_name == 'faq' %}active{% endif %}">FAQ</a></li>
<li><a href="/supporter" class="{% if request.resolver_match.url_name == 'supporter' %}active{% endif %}">Partner</a></li>
</ul>
<ul class="nav navbar-nav navbar-right">
{% block loginindicator %}
Expand Down
18 changes: 18 additions & 0 deletions wye/templates/supporters.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{% extends "base.html" %}
{% load staticfiles %}
{% block title %}Partner | {{ block.super }}{% endblock %}

{% block header %}
<div class="banner push-2 text-center">
<h1 class="space-0">PARTNERS</h1>
</div>
{% endblock %}

{% block content %}
<div class="push-6-bottom">
<p> Community partner</p>
<a href="https://discuss.fsmk.org/" class="btn btn-theme btn-theme-secondary">
<img style="width:300px;" src="{% static 'img/supporter/fsmk.png' %}" alt="">
</a>
</div>
{% endblock %}
10 changes: 8 additions & 2 deletions wye/urls.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,10 @@
from django.views.generic.base import TemplateView

from wye.base.views import HomePageView
from wye.profiles.views import UserDashboard, contact, partner_view
from wye.profiles.views import (
UserDashboard,
contact,
partner_view)
from wye.organisations.views import activate_view
from wye.workshops.views import upcoming_workshops

Expand All @@ -21,12 +24,15 @@
name='contact'),
url(r'^partner/$', partner_view,
name='partner'),
url(r'^supporter/$', TemplateView.as_view(template_name='supporters.html',),
name='supporter'),
url(r'^thankyou/$', TemplateView.as_view(template_name='contact.html'),
name='thankyou'),
url(r'^workshops_info/$', TemplateView.as_view(
template_name='workshops_info.html',),
name='workshops_info'),
url(r'^workshops_upcoming/$', upcoming_workshops, name="upcoming_workshops"),
url(r'^workshops_upcoming/$',
upcoming_workshops, name="upcoming_workshops"),
url(r'^faq/$', TemplateView.as_view(template_name='faq.html',),
name='faq'),
url(r'^organisation/',
Expand Down
13 changes: 7 additions & 6 deletions wye/workshops/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
WorkshopLevel,
WorkshopStatus,
)
from wye.base.emailer_html import send_email_to_list
from wye.base.emailer_html import send_email_to_id
from wye.base.models import TimeAuditModel
from wye.organisations.models import Organisation
from wye.regions.models import Location
Expand Down Expand Up @@ -91,11 +91,12 @@ def save(self, force_insert=False, force_update=False, using=None):
text_body = loader.get_template(
'email_messages/workshop/create_workshop/message.txt').render(
context)
send_email_to_list(
subject,
body=email_body,
users_list=region_interested_member,
text_body=text_body)
for email_id in region_interested_member:
send_email_to_id(
subject,
body=email_body,
email_id=email_id,
text_body=text_body)

super(Workshop, self).save(force_insert, force_update, using)

Expand Down

0 comments on commit 5a599bd

Please sign in to comment.