Skip to content

Commit

Permalink
moved all templates from tavern/templates to tavern/templates/tavern/…
Browse files Browse the repository at this point in the history
… and made necessary changes in the templates
  • Loading branch information
omkarvijay5 committed Sep 7, 2014
1 parent 4afa305 commit 5adb649
Show file tree
Hide file tree
Showing 11 changed files with 16 additions and 16 deletions.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{% extends "base.html" %}
{% extends "tavern/base.html" %}

{% block content %}
<h3>Add organizers</h3>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{% extends "base.html" %}
{% extends "tavern/base.html" %}
{% load guardian_tags %}

{% block content %}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{% extends "base.html" %}
{% extends "tavern/base.html" %}

{% block javascript %}
{{ form.media }}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{% extends "base.html" %}
{% extends "tavern/base.html" %}
{% load guardian_tags %}

{% block content %}
Expand Down Expand Up @@ -45,9 +45,9 @@ <h4 class="modal-title">Are you sure?</h4>
</div>
<button class="btn btn-danger" data-toggle="modal" data-target="#deleteGroupModal">Delete</button>
{% endif %}
{% include 'past_events.html' %}
{% include 'tavern/past_events.html' %}

{% include 'upcoming_events.html' %}
{% include 'tavern/upcoming_events.html' %}

{% endblock content %}

Expand Down
2 changes: 1 addition & 1 deletion tavern/templates/tavern/group_form.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{% extends "base.html" %}
{% extends "tavern/base.html" %}

{% block content %}

Expand Down
4 changes: 2 additions & 2 deletions tavern/templates/tavern/home.html
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ <h1>Groups</h1>
</div>

{% if past_events %}
{% include 'past_events.html' %}
{% include 'tavern/past_events.html' %}
{% endif %}

{% if events_rsvped %}
Expand Down Expand Up @@ -72,7 +72,7 @@ <h1>All Groups </h1>
{% endif %}

{% if upcoming_events %}
{% include 'upcoming_events.html' %}
{% include 'tavern/upcoming_events.html' %}
{% endif %}

{% endblock content %}
Expand Down
File renamed without changes.
File renamed without changes.
14 changes: 7 additions & 7 deletions tavern/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ def get_context_data(self, **kwargs):

class GroupDetail(UpcomingEventsMixin, DetailView):
""" Group details Page """
template_name = "group_details.html"
template_name = "tavern/group_details.html"
context_object_name = "group"
model = TavernGroup

Expand All @@ -126,7 +126,7 @@ def get_context_data(self, **kwargs):

class EventDetail(UpcomingEventsMixin, DetailView):
""" Give details about an event and its attendees"""
template_name = "event_details.html"
template_name = "tavern/event_details.html"
context_object_name = "event"
model = Event

Expand Down Expand Up @@ -160,7 +160,7 @@ class GroupCreate(LoginRequiredMixin, CreateView):
""" Create new group """
form_class = CreateGroupForm
model = TavernGroup
template_name = "group_form.html"
template_name = "tavern/group_form.html"

def form_valid(self, form):
form.instance.creator = self.request.user
Expand All @@ -171,7 +171,7 @@ class GroupUpdate(LoginRequiredMixin, PermissionRequiredMixin, UpdateView):
""" Updates a group """
model = TavernGroup
form_class = CreateGroupForm
template_name = 'group_form.html'
template_name = 'tavern/group_form.html'
permission_required = 'tavern.change_taverngroup'
render_403 = True
return_403 = True
Expand All @@ -188,7 +188,7 @@ def get_success_url(self, **kwargs):


class EditOrganizers(LoginRequiredMixin, PermissionRequiredMixin, SingleObjectMixin, MultiFormsView):
template_name = "edit_organizers.html"
template_name = "tavern/edit_organizers.html"
form_classes = {'add': AddOrganizerForm,
'remove': RemoveOrganizerForm
}
Expand Down Expand Up @@ -226,7 +226,7 @@ class EventCreate(LoginRequiredMixin, CreateView):
""" Creates new Event """
form_class = CreateEventForm
model = Event
template_name = "event_form.html"
template_name = "tavern/event_form.html"

def get_form_kwargs(self):
kwargs = super(EventCreate, self).get_form_kwargs()
Expand All @@ -242,7 +242,7 @@ class EventUpdate(LoginRequiredMixin, PermissionRequiredMixin, UpdateView):
""" Update an Event """
model = Event
form_class = UpdateEventForm
template_name = 'event_form.html'
template_name = 'tavern/event_form.html'
permission_required = 'tavern.change_event'
render_403 = True
return_403 = True
Expand Down

0 comments on commit 5adb649

Please sign in to comment.