def POST(self): """ Add new Activity """ form = self.form() if not form.validates(): activity = model.get_activity() return render.activity(activity, form) model.create_activity(form.d.phone_id, form.d.action, form.d.category, form.d.component, form.d.details) raise web.seeother('/activity/list')
def GET(self): activity = model.get_activity() return render.activity_list(activity)