Permalink
Browse files

Let all members staff events.

  • Loading branch information...
1 parent f221d48 commit 7bdb866af20057b1dd913f632f0498864c36c72a Brian Klug committed Jun 23, 2010
Showing with 4 additions and 4 deletions.
  1. +3 −3 main.py
  2. +1 −1 templates/event.html
View
@@ -6,7 +6,7 @@
from django.template.defaultfilters import slugify
from icalendar import Calendar
import logging, urllib
-
+from pprint import pprint
from datetime import datetime, timedelta
from models import Event, Feedback, ROOM_OPTIONS, GUESTS_PER_STAFF, PENDING_LIFETIME
@@ -52,7 +52,7 @@ def get(self, id):
user = users.get_current_user()
if user:
is_admin = username(user) in dojo('/groups/events')
- is_staff = username(user) in dojo('/groups/staff')
+ is_staff = True
can_approve = (event.status in ['pending'] and is_admin)
can_staff = (event.status in ['pending', 'understaffed', 'approved'] and is_staff and not user in event.staff)
logout_url = users.create_logout_url('/')
@@ -64,7 +64,7 @@ def post(self, id):
event = Event.get_by_id(int(id))
user = users.get_current_user()
is_admin = username(user) in dojo('/groups/events')
- is_staff = username(user) in dojo('/groups/staff')
+ is_staff = True
state = self.request.get('state')
if state:
if state.lower() == 'approve' and is_admin:
View
@@ -22,7 +22,7 @@
{% if not event.is_staffed %}<p>
<span style="color: red; font-weight: bold">This event is currently understaffed.</span><br/>
- Due to this size of the event, at least {{ event.staff_needed }} Dojo staff member{{ event.staff_needed|pluralize }} must volunteer to staff it. It will not appear on the public calendar until {% if not event.is_approved %}it has been approved and {% endif %}enough staff volunteer.
+ Due to this size of the event, at least {{ event.staff_needed }} more Dojo member{{ event.staff_needed|pluralize }} must volunteer to staff it. It will not appear on the public calendar until {% if not event.is_approved %}it has been approved and {% endif %}enough people volunteer.
</p>{% else %}{% if not event.is_approved %}<p>
<span style="color: red; font-weight: bold">This event is not yet visible.</span><br/>
This event will not appear on the public calendar until it has been approved. If this does not happen soon, contact <a href="email:events@hackerdojo.com">events@hackerdojo.com</a> for assistance.

0 comments on commit 7bdb866

Please sign in to comment.