Ejemplo n.º 1
0
def member_edit():
    """
    """
    form = MemberForm()
    if form.validate_on_submit():
        member = Member(firstname = form.firstname.data,
                    lastname = form.lastname.data,
                    location = form.location.data,
                    user = users.get_current_user())
        member.put()
        flash('Member saved on database.')
        return redirect(url_for('member_list'))
    return render_template('members/edit.html', form=form)