flask_boost/project/application/controllers/account.py
def signup():
    """Signup"""
    form = SignupForm()
    if form.validate_on_submit():
        params = form.data.copy()
        params.pop('repassword')
        user = User(**params)
        db.session.add(user)
        db.session.commit()
        signin_user(user)
        return redirect(url_for('site.index'))
    return render_template('account/signup/signup.html', form=form)
def signup():
    """Signup"""
    form = SignupForm()
    if form.validate_on_submit():
        params = form.data.copy()
        params.pop('repassword')
        user = User(**params)
        db.session.add(user)
        db.session.commit()
        signin_user(user)
        return redirect(url_for('site.index'))
    return render_template('account/signup/signup.html', form=form)
def signup ( ) : form = SignupForm ( ) if form . validate_on_submit ( ) : params = form . data . copy ( ) params . pop ( 'repassword' ) user = User ( * * params ) db . session . add ( user ) db . session . commit ( ) signin_user ( user ) return redirect ( url_for ( 'site.index' ) ) return render_template ( 'account/signup/signup.html' , form = form )
Signup
Signup