Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100755 375 lines (328 sloc) 15.645 kb
8414350 @billsaysthis multiline for details and notes fields
billsaysthis authored
1 import cgi
9b632dd @progrium initial commit -- basic form, rough listing
progrium authored
2 from google.appengine.ext import webapp, db
3 from google.appengine.ext.webapp import util, template
47a7f7a @progrium basic form validation, added end time, start of notifications, some fixe...
progrium authored
4 from google.appengine.api import urlfetch, memcache, users, mail
5
9b632dd @progrium initial commit -- basic form, rough listing
progrium authored
6 from django.utils import simplejson
fcf7602 @progrium working approval process and ical view of approved events
progrium authored
7 from django.template.defaultfilters import slugify
5cd04ac Fixed iCalendar-related imports, and added the end date to the
Matt Hancher authored
8 from icalendar import Calendar
b4ea292 Handler to bug pending events
Brian Klug authored
9 import logging, urllib, os
7bdb866 Let all members staff events.
Brian Klug authored
10 from pprint import pprint
b879063 @mdhancher Respect the local timezone (Pacific), and tidy up related imports.
mdhancher authored
11 from datetime import datetime, timedelta
fcf7602 @progrium working approval process and ical view of approved events
progrium authored
12
4d85afa @dustball Remove staffing requirement and make members more responsible
dustball authored
13 from models import Event, Feedback, ROOM_OPTIONS, PENDING_LIFETIME
219203b @dustball Cache better
dustball authored
14 from utils import username, human_username, set_cookie, local_today, is_phone_valid, UserRights, dojo
81a81e1 @progrium adding errors for form validation, full notifications, and minor edits t...
progrium authored
15 from notices import *
7742592 @progrium start of maintaining form state on errors
progrium authored
16
9f06c39 @casey Added RSS for upcoming events.
casey authored
17 import PyRSS2Gen
18
19 def event_path(event):
20 return '/event/%s-%s' % (event.key().id(), slugify(event.name))
21
219203b @dustball Cache better
dustball authored
22 class DomainCacheCron(webapp.RequestHandler):
23 def post(self):
24 noop = dojo('/groups/events',force=True)
25
26
f49797a @dustball Reminders 2.0
dustball authored
27 class ReminderCron(webapp.RequestHandler):
28 def post(self):
29 self.response.out.write("REMINDERS")
30 today = local_today()
31 # remind everyone 3 days in advance they need to show up
32 events = Event.all() \
33 .filter('status IN', ['approved']) \
34 .filter('reminded =', False) \
35 .filter('start_time <', today + timedelta(days=3))
36 for event in events:
37 self.response.out.write(event.name)
38 # only mail them if they created the event 2+ days ago
39 if event.created < today - timedelta(days=2):
40 schedule_reminder_email(event)
41 event.reminded = True
42 event.put()
43
44
e2b9558 @btubbs Fixes issue 4. Changed to jqueryUI datepicker. Replaced jquery
btubbs authored
45 class ExpireCron(webapp.RequestHandler):
47a7f7a @progrium basic form validation, added end time, start of notifications, some fixe...
progrium authored
46 def post(self):
47 # Expire events marked to expire today
b879063 @mdhancher Respect the local timezone (Pacific), and tidy up related imports.
mdhancher authored
48 today = local_today()
47a7f7a @progrium basic form validation, added end time, start of notifications, some fixe...
progrium authored
49 events = Event.all() \
50 .filter('status IN', ['pending', 'understaffed']) \
51 .filter('expired >=', today) \
52 .filter('expired <', today + timedelta(days=1))
53 for event in events:
54 event.expire()
55 notify_owner_expired(event)
f49797a @dustball Reminders 2.0
dustball authored
56
f1997e4 @christopherb Made misc style fixes
christopherb authored
57
47a7f7a @progrium basic form validation, added end time, start of notifications, some fixe...
progrium authored
58 class ExpireReminderCron(webapp.RequestHandler):
59 def post(self):
60 # Find events expiring in 10 days to warn owner
b879063 @mdhancher Respect the local timezone (Pacific), and tidy up related imports.
mdhancher authored
61 ten_days = local_today() + timedelta(days=10)
47a7f7a @progrium basic form validation, added end time, start of notifications, some fixe...
progrium authored
62 events = Event.all() \
63 .filter('status IN', ['pending', 'understaffed']) \
64 .filter('expired >=', ten_days) \
65 .filter('expired <', ten_days + timedelta(days=1))
66 for event in events:
67 notify_owner_expiring(event)
68
f1997e4 @christopherb Made misc style fixes
christopherb authored
69
fcf7602 @progrium working approval process and ical view of approved events
progrium authored
70 class EventsHandler(webapp.RequestHandler):
71 def get(self, format):
9f06c39 @casey Added RSS for upcoming events.
casey authored
72 events = Event.all().filter('status IN', ['approved', 'canceled']).order('start_time')
fcf7602 @progrium working approval process and ical view of approved events
progrium authored
73 if format == 'ics':
74 cal = Calendar()
75 for event in events:
76 cal.add_component(event.to_ical())
77 self.response.headers['content-type'] = 'text/calendar'
78 self.response.out.write(cal.as_string())
2e08a66 @progrium cleaning things up and adding json representations for jon
progrium authored
79 elif format == 'json':
80 self.response.headers['content-type'] = 'application/json'
a493a39 @progrium changing the json events list to the approved list
progrium authored
81 events = map(lambda x: x.to_dict(summarize=True), Event.get_approved_list())
2e08a66 @progrium cleaning things up and adding json representations for jon
progrium authored
82 self.response.out.write(simplejson.dumps(events))
9f06c39 @casey Added RSS for upcoming events.
casey authored
83 elif format =='rss':
84 url_base = 'http://' + self.request.headers.get('host', 'events.hackerdojo.com')
85 rss = PyRSS2Gen.RSS2(
86 title = "Hacker Dojo Events Feed",
87 link = url_base,
88 description = "Upcoming events at the Hacker Dojo in Mountain View, CA",
89 lastBuildDate = datetime.now(),
90 items = [PyRSS2Gen.RSSItem(
91 title = event.name,
92 link = url_base + event_path(event),
93 description = event.details,
94 guid = url_base + event_path(event),
95 pubDate = event.updated,
96 ) for event in events]
97 )
98
99 self.response.headers['content-type'] = 'application/xml'
100 self.response.out.write(rss.to_xml())
9b632dd @progrium initial commit -- basic form, rough listing
progrium authored
101
f1997e4 @christopherb Made misc style fixes
christopherb authored
102
ca8c7f2 @dustball Let edit events and refactor error handling
dustball authored
103 class EditHandler(webapp.RequestHandler):
104 def get(self, id):
105 event = Event.get_by_id(int(id))
106 user = users.get_current_user()
107 access_rights = UserRights(user, event)
108 if access_rights.can_edit:
109 logout_url = users.create_logout_url('/')
110 rooms = '\n'.join(event.rooms)
111 self.response.out.write(template.render('templates/edit.html', locals()))
112 else:
113 self.response.out.write("Access denied")
114
115 def post(self, id):
116 event = Event.get_by_id(int(id))
117 user = users.get_current_user()
118 access_rights = UserRights(user, event)
119 if access_rights.can_edit:
120 try:
121 if not self.request.get('estimated_size').isdigit():
122 raise ValueError('Estimated number of people must be a number')
123 if not int(self.request.get('estimated_size')) > 0:
124 raise ValueError('Estimated number of people must be greater then zero')
125 if ( self.request.get( 'contact_phone' ) and not is_phone_valid( self.request.get( 'contact_phone' ) ) ):
126 raise ValueError( 'Phone number does not appear to be valid' )
127 else:
128 event.name = self.request.get('name')
129 event.estimated_size = cgi.escape(self.request.get('estimated_size'))
130 event.contact_name = cgi.escape(self.request.get('contact_name'))
131 event.contact_phone = cgi.escape(self.request.get('contact_phone'))
132 event.details = cgi.escape(self.request.get('details'))
133 event.url = cgi.escape(self.request.get('url'))
134 event.fee = cgi.escape(self.request.get('fee'))
135 event.notes = cgi.escape(self.request.get('notes'))
136 event.rooms = self.request.get('rooms').strip().split("\n")
137 event.put()
9f06c39 @casey Added RSS for upcoming events.
casey authored
138 self.redirect(event_path(event))
ca8c7f2 @dustball Let edit events and refactor error handling
dustball authored
139 except Exception, e:
140 error = str(e)
141 self.response.out.write(template.render('templates/error.html', locals()))
142 else:
143 self.response.out.write("Access denied")
144
145
9b632dd @progrium initial commit -- basic form, rough listing
progrium authored
146 class EventHandler(webapp.RequestHandler):
147 def get(self, id):
148 event = Event.get_by_id(int(id))
2e08a66 @progrium cleaning things up and adding json representations for jon
progrium authored
149 if self.request.path.endswith('json'):
150 self.response.headers['content-type'] = 'application/json'
151 self.response.out.write(simplejson.dumps(event.to_dict()))
fcf7602 @progrium working approval process and ical view of approved events
progrium authored
152 else:
2e08a66 @progrium cleaning things up and adding json representations for jon
progrium authored
153 user = users.get_current_user()
154 if user:
766e87c @christopherb Added UserRights class.
christopherb authored
155 access_rights = UserRights(user, event)
2e08a66 @progrium cleaning things up and adding json representations for jon
progrium authored
156 logout_url = users.create_logout_url('/')
766e87c @christopherb Added UserRights class.
christopherb authored
157
2e08a66 @progrium cleaning things up and adding json representations for jon
progrium authored
158 else:
159 login_url = users.create_login_url('/')
7ebb2cd @christopherb Cleaned up the style of the files some. Mostly standardizing on single q...
christopherb authored
160 event.details = db.Text(event.details.replace('\n','<br/>'))
161 event.notes = db.Text(event.notes.replace('\n','<br/>'))
2e08a66 @progrium cleaning things up and adding json representations for jon
progrium authored
162 self.response.out.write(template.render('templates/event.html', locals()))
e2b9558 @btubbs Fixes issue 4. Changed to jqueryUI datepicker. Replaced jquery
btubbs authored
163
fcf7602 @progrium working approval process and ical view of approved events
progrium authored
164 def post(self, id):
165 event = Event.get_by_id(int(id))
166 user = users.get_current_user()
766e87c @christopherb Added UserRights class.
christopherb authored
167 access_rights = UserRights(user, event)
168
fcf7602 @progrium working approval process and ical view of approved events
progrium authored
169 state = self.request.get('state')
170 if state:
766e87c @christopherb Added UserRights class.
christopherb authored
171 if state.lower() == 'approve' and access_rights.can_approve:
fcf7602 @progrium working approval process and ical view of approved events
progrium authored
172 event.approve()
b84b533 @dustball Fix one more staff logic bomb
dustball authored
173 if state.lower() == 'staff' and access_rights.can_staff:
fcf7602 @progrium working approval process and ical view of approved events
progrium authored
174 event.add_staff(user)
766e87c @christopherb Added UserRights class.
christopherb authored
175 if state.lower() == 'unstaff' and access_rights.can_unstaff:
72849c2 @billsaysthis added unstaff event, including email notification if event becomes under...
billsaysthis authored
176 event.remove_staff(user)
766e87c @christopherb Added UserRights class.
christopherb authored
177 if state.lower() == 'cancel' and access_rights.can_cancel:
fcf7602 @progrium working approval process and ical view of approved events
progrium authored
178 event.cancel()
766e87c @christopherb Added UserRights class.
christopherb authored
179 if state.lower() == 'delete' and access_rights.is_admin:
a67ac50 @mdhancher Add a simple admin-only event delete and undelete.
mdhancher authored
180 event.delete()
766e87c @christopherb Added UserRights class.
christopherb authored
181 if state.lower() == 'undelete' and access_rights.is_admin:
a67ac50 @mdhancher Add a simple admin-only event delete and undelete.
mdhancher authored
182 event.undelete()
766e87c @christopherb Added UserRights class.
christopherb authored
183 if state.lower() == 'expire' and access_rights.is_admin:
47a7f7a @progrium basic form validation, added end time, start of notifications, some fixe...
progrium authored
184 event.expire()
185 if event.status == 'approved':
186 notify_owner_approved(event)
9f06c39 @casey Added RSS for upcoming events.
casey authored
187 self.redirect(event_path(event))
9b632dd @progrium initial commit -- basic form, rough listing
progrium authored
188
f1997e4 @christopherb Made misc style fixes
christopherb authored
189
9b632dd @progrium initial commit -- basic form, rough listing
progrium authored
190 class ApprovedHandler(webapp.RequestHandler):
191 def get(self):
192 user = users.get_current_user()
193 if user:
194 logout_url = users.create_logout_url('/')
195 else:
196 login_url = users.create_login_url('/')
b879063 @mdhancher Respect the local timezone (Pacific), and tidy up related imports.
mdhancher authored
197 today = local_today()
47a7f7a @progrium basic form validation, added end time, start of notifications, some fixe...
progrium authored
198 events = Event.get_approved_list()
9b632dd @progrium initial commit -- basic form, rough listing
progrium authored
199 tomorrow = today + timedelta(days=1)
d63161a Add widget mode
Brian Klug authored
200 whichbase = 'base.html'
201 if self.request.get('base'):
7ebb2cd @christopherb Cleaned up the style of the files some. Mostly standardizing on single q...
christopherb authored
202 whichbase = self.request.get('base') + '.html'
9b632dd @progrium initial commit -- basic form, rough listing
progrium authored
203 self.response.out.write(template.render('templates/approved.html', locals()))
204
f1997e4 @christopherb Made misc style fixes
christopherb authored
205
a82b43e @billsaysthis add myevents, pastevents code, refined list display on event page
billsaysthis authored
206 class MyEventsHandler(webapp.RequestHandler):
207 @util.login_required
208 def get(self):
209 user = users.get_current_user()
210 if user:
211 logout_url = users.create_logout_url('/')
212 else:
213 login_url = users.create_login_url('/')
214 events = Event.all().filter('member = ', user).order('start_time')
b879063 @mdhancher Respect the local timezone (Pacific), and tidy up related imports.
mdhancher authored
215 today = local_today()
a82b43e @billsaysthis add myevents, pastevents code, refined list display on event page
billsaysthis authored
216 tomorrow = today + timedelta(days=1)
217 self.response.out.write(template.render('templates/myevents.html', locals()))
218
f1997e4 @christopherb Made misc style fixes
christopherb authored
219
a82b43e @billsaysthis add myevents, pastevents code, refined list display on event page
billsaysthis authored
220 class PastHandler(webapp.RequestHandler):
221 def get(self):
222 user = users.get_current_user()
223 if user:
224 logout_url = users.create_logout_url('/')
225 else:
226 login_url = users.create_login_url('/')
b879063 @mdhancher Respect the local timezone (Pacific), and tidy up related imports.
mdhancher authored
227 today = local_today()
d75579f @progrium minor updates here and there to bills contributions.
progrium authored
228 events = Event.all().filter('start_time < ', today).order('-start_time')
a82b43e @billsaysthis add myevents, pastevents code, refined list display on event page
billsaysthis authored
229 self.response.out.write(template.render('templates/past.html', locals()))
230
f1997e4 @christopherb Made misc style fixes
christopherb authored
231
b4ea292 Handler to bug pending events
Brian Klug authored
232 class CronBugOwnersHandler(webapp.RequestHandler):
233 def get(self):
234 events = Event.get_pending_list()
235 for e in events:
236 bug_owner_pending(e)
237
f1997e4 @christopherb Made misc style fixes
christopherb authored
238
9b632dd @progrium initial commit -- basic form, rough listing
progrium authored
239 class PendingHandler(webapp.RequestHandler):
240 def get(self):
241 user = users.get_current_user()
242 if user:
243 logout_url = users.create_logout_url('/')
244 else:
245 login_url = users.create_login_url('/')
47a7f7a @progrium basic form validation, added end time, start of notifications, some fixe...
progrium authored
246 events = Event.get_pending_list()
b879063 @mdhancher Respect the local timezone (Pacific), and tidy up related imports.
mdhancher authored
247 today = local_today()
9b632dd @progrium initial commit -- basic form, rough listing
progrium authored
248 tomorrow = today + timedelta(days=1)
249 self.response.out.write(template.render('templates/pending.html', locals()))
250
f1997e4 @christopherb Made misc style fixes
christopherb authored
251
9b632dd @progrium initial commit -- basic form, rough listing
progrium authored
252 class NewHandler(webapp.RequestHandler):
fcf7602 @progrium working approval process and ical view of approved events
progrium authored
253 @util.login_required
9b632dd @progrium initial commit -- basic form, rough listing
progrium authored
254 def get(self):
255 user = users.get_current_user()
4d85afa @dustball Remove staffing requirement and make members more responsible
dustball authored
256 human = human_username(user)
9b632dd @progrium initial commit -- basic form, rough listing
progrium authored
257 if user:
258 logout_url = users.create_logout_url('/')
259 else:
260 login_url = users.create_login_url('/')
261 rooms = ROOM_OPTIONS
262 self.response.out.write(template.render('templates/new.html', locals()))
e2b9558 @btubbs Fixes issue 4. Changed to jqueryUI datepicker. Replaced jquery
btubbs authored
263
f1997e4 @christopherb Made misc style fixes
christopherb authored
264
9b632dd @progrium initial commit -- basic form, rough listing
progrium authored
265 def post(self):
266 user = users.get_current_user()
7742592 @progrium start of maintaining form state on errors
progrium authored
267 try:
7ebb2cd @christopherb Cleaned up the style of the files some. Mostly standardizing on single q...
christopherb authored
268 start_time = datetime.strptime('%s %s:%s %s' % (
7742592 @progrium start of maintaining form state on errors
progrium authored
269 self.request.get('date'),
270 self.request.get('start_time_hour'),
271 self.request.get('start_time_minute'),
7ebb2cd @christopherb Cleaned up the style of the files some. Mostly standardizing on single q...
christopherb authored
272 self.request.get('start_time_ampm')), '%m/%d/%Y %I:%M %p')
273 end_time = datetime.strptime('%s %s:%s %s' % (
7742592 @progrium start of maintaining form state on errors
progrium authored
274 self.request.get('date'),
275 self.request.get('end_time_hour'),
276 self.request.get('end_time_minute'),
7ebb2cd @christopherb Cleaned up the style of the files some. Mostly standardizing on single q...
christopherb authored
277 self.request.get('end_time_ampm')), '%m/%d/%Y %I:%M %p')
8615877 Fix validation for event size
Brian Klug authored
278 if not self.request.get('estimated_size').isdigit():
7ebb2cd @christopherb Cleaned up the style of the files some. Mostly standardizing on single q...
christopherb authored
279 raise ValueError('Estimated number of people must be a number')
8615877 Fix validation for event size
Brian Klug authored
280 if not int(self.request.get('estimated_size')) > 0:
7ebb2cd @christopherb Cleaned up the style of the files some. Mostly standardizing on single q...
christopherb authored
281 raise ValueError('Estimated number of people must be greater then zero')
7742592 @progrium start of maintaining form state on errors
progrium authored
282 if (end_time-start_time).days < 0:
7ebb2cd @christopherb Cleaned up the style of the files some. Mostly standardizing on single q...
christopherb authored
283 raise ValueError('End time must be after start time')
a244c65 @dustball Bug fixes
dustball authored
284 if ( self.request.get( 'contact_phone' ) and not is_phone_valid( self.request.get( 'contact_phone' ) ) ):
7ebb2cd @christopherb Cleaned up the style of the files some. Mostly standardizing on single q...
christopherb authored
285 raise ValueError( 'Phone number does not appear to be valid' )
7742592 @progrium start of maintaining form state on errors
progrium authored
286 else:
287 event = Event(
ca3c6dd Escaped additional fields that could be used for XSS
Christopher Biettchert authored
288 name = cgi.escape(self.request.get('name')),
7742592 @progrium start of maintaining form state on errors
progrium authored
289 start_time = start_time,
290 end_time = end_time,
ca3c6dd Escaped additional fields that could be used for XSS
Christopher Biettchert authored
291 type = cgi.escape(self.request.get('type')),
292 estimated_size = cgi.escape(self.request.get('estimated_size')),
293 contact_name = cgi.escape(self.request.get('contact_name')),
294 contact_phone = cgi.escape(self.request.get('contact_phone')),
8414350 @billsaysthis multiline for details and notes fields
billsaysthis authored
295 details = cgi.escape(self.request.get('details')),
ca3c6dd Escaped additional fields that could be used for XSS
Christopher Biettchert authored
296 url = cgi.escape(self.request.get('url')),
297 fee = cgi.escape(self.request.get('fee')),
8414350 @billsaysthis multiline for details and notes fields
billsaysthis authored
298 notes = cgi.escape(self.request.get('notes')),
7ebb2cd @christopherb Cleaned up the style of the files some. Mostly standardizing on single q...
christopherb authored
299 rooms = self.request.get_all('rooms'),
b879063 @mdhancher Respect the local timezone (Pacific), and tidy up related imports.
mdhancher authored
300 expired = local_today() + timedelta(days=PENDING_LIFETIME), # Set expected expiration date
7742592 @progrium start of maintaining form state on errors
progrium authored
301 )
302 event.put()
303 notify_owner_confirmation(event)
304 notify_new_event(event)
81a81e1 @progrium adding errors for form validation, full notifications, and minor edits t...
progrium authored
305 set_cookie(self.response.headers, 'formvalues', None)
7742592 @progrium start of maintaining form state on errors
progrium authored
306 self.redirect('/event/%s-%s' % (event.key().id(), slugify(event.name)))
81a81e1 @progrium adding errors for form validation, full notifications, and minor edits t...
progrium authored
307 except Exception, e:
308 message = str(e)
309 if 'match format' in message:
7ebb2cd @christopherb Cleaned up the style of the files some. Mostly standardizing on single q...
christopherb authored
310 message = 'Date is required.'
81a81e1 @progrium adding errors for form validation, full notifications, and minor edits t...
progrium authored
311 if message.startswith('Property'):
312 message = message[9:].replace('_', ' ').capitalize()
ca8c7f2 @dustball Let edit events and refactor error handling
dustball authored
313 # This is NOT a reliable way to handle erorrs
314 #set_cookie(self.response.headers, 'formerror', message)
315 #set_cookie(self.response.headers, 'formvalues', dict(self.request.POST))
316 #self.redirect('/new')
317 error = message
318 self.response.out.write(template.render('templates/error.html', locals()))
319
320
321
322
9b632dd @progrium initial commit -- basic form, rough listing
progrium authored
323
d2c3dc7 @billsaysthis moved app-specific js to separate file
billsaysthis authored
324
325 class FeedbackHandler(webapp.RequestHandler):
326 @util.login_required
7ebb2cd @christopherb Cleaned up the style of the files some. Mostly standardizing on single q...
christopherb authored
327 def get(self, id):
d2c3dc7 @billsaysthis moved app-specific js to separate file
billsaysthis authored
328 user = users.get_current_user()
7ebb2cd @christopherb Cleaned up the style of the files some. Mostly standardizing on single q...
christopherb authored
329 event = Event.get_by_id(int(id))
d2c3dc7 @billsaysthis moved app-specific js to separate file
billsaysthis authored
330 if user:
331 logout_url = users.create_logout_url('/')
332 else:
333 login_url = users.create_login_url('/')
334 self.response.out.write(template.render('templates/feedback.html', locals()))
335
7ebb2cd @christopherb Cleaned up the style of the files some. Mostly standardizing on single q...
christopherb authored
336 def post(self, id):
d2c3dc7 @billsaysthis moved app-specific js to separate file
billsaysthis authored
337 user = users.get_current_user()
7ebb2cd @christopherb Cleaned up the style of the files some. Mostly standardizing on single q...
christopherb authored
338 event = Event.get_by_id(int(id))
8c52522 @billsaysthis small tweak to how feedbacks displayed in event page
billsaysthis authored
339 try:
340 if self.request.get('rating'):
341 feedback = Feedback(
342 event = event,
343 rating = int(self.request.get('rating')),
ca3c6dd Escaped additional fields that could be used for XSS
Christopher Biettchert authored
344 comment = cgi.escape(self.request.get('comment')))
8c52522 @billsaysthis small tweak to how feedbacks displayed in event page
billsaysthis authored
345 feedback.put()
346 self.redirect('/event/%s-%s' % (event.key().id(), slugify(event.name)))
347 else:
7ebb2cd @christopherb Cleaned up the style of the files some. Mostly standardizing on single q...
christopherb authored
348 raise ValueError('Please select a rating')
8c52522 @billsaysthis small tweak to how feedbacks displayed in event page
billsaysthis authored
349 except Exception:
350 set_cookie(self.response.headers, 'formvalues', dict(self.request.POST))
7ebb2cd @christopherb Cleaned up the style of the files some. Mostly standardizing on single q...
christopherb authored
351 self.redirect('/feedback/new/' + id)
d2c3dc7 @billsaysthis moved app-specific js to separate file
billsaysthis authored
352
9b632dd @progrium initial commit -- basic form, rough listing
progrium authored
353 def main():
354 application = webapp.WSGIApplication([
355 ('/', ApprovedHandler),
fcf7602 @progrium working approval process and ical view of approved events
progrium authored
356 ('/events\.(.+)', EventsHandler),
d75579f @progrium minor updates here and there to bills contributions.
progrium authored
357 ('/past', PastHandler),
9b632dd @progrium initial commit -- basic form, rough listing
progrium authored
358 ('/pending', PendingHandler),
b4ea292 Handler to bug pending events
Brian Klug authored
359 ('/cronbugowners', CronBugOwnersHandler),
a82b43e @billsaysthis add myevents, pastevents code, refined list display on event page
billsaysthis authored
360 ('/myevents', MyEventsHandler),
9b632dd @progrium initial commit -- basic form, rough listing
progrium authored
361 ('/new', NewHandler),
ca8c7f2 @dustball Let edit events and refactor error handling
dustball authored
362 ('/edit/(\d+).*', EditHandler),
47a7f7a @progrium basic form validation, added end time, start of notifications, some fixe...
progrium authored
363 ('/event/(\d+).*', EventHandler),
2e08a66 @progrium cleaning things up and adding json representations for jon
progrium authored
364 ('/event/(\d+)\.json', EventHandler),
47a7f7a @progrium basic form validation, added end time, start of notifications, some fixe...
progrium authored
365 ('/expire', ExpireCron),
34d98f0 @billsaysthis moved feedback stuff to separate py file, small tweak to email notificat...
billsaysthis authored
366 ('/expiring', ExpireReminderCron),
219203b @dustball Cache better
dustball authored
367 ('/domaincache', DomainCacheCron),
f49797a @dustball Reminders 2.0
dustball authored
368 ('/reminder', ReminderCron),
d2c3dc7 @billsaysthis moved app-specific js to separate file
billsaysthis authored
369 ('/feedback/new/(\d+).*', FeedbackHandler) ],debug=True)
9b632dd @progrium initial commit -- basic form, rough listing
progrium authored
370 util.run_wsgi_app(application)
371
f1997e4 @christopherb Made misc style fixes
christopherb authored
372
9b632dd @progrium initial commit -- basic form, rough listing
progrium authored
373 if __name__ == '__main__':
374 main()
Something went wrong with that request. Please try again.