def createaccount(): form = AccountForm.RegisterForm() formLogin = AccountForm.LoginForm() if request.method =='GET': return render_template('createaccount.html',form=form,formLogin=formLogin) if request.method =='POST': if request.form.get('login', None) == 'Login' : return AccountController.authenticatePopUpLogin(formLogin,'index') return AccountController.createuser(form=form, formLogin=formLogin)
def index(): formLogin = AccountForm.LoginForm() if request.method == "GET": return render_template("index.html", formLogin=formLogin) if request.method == "POST": if request.form.get("login", None) == "Login": return AccountController.authenticatePopUpLogin(formLogin, "index")
def index(): formLogin = AccountForm.LoginForm() if request.method == 'GET' : return render_template('index.html',formLogin=formLogin) if request.method == 'POST' : if request.form.get('login', None) == 'Login' : return AccountController.authenticatePopUpLogin(formLogin,'index')
def checkout(): """ To address user pop up login , we have to pass formLogin to each page """ formLogin = AccountForm.LoginForm() if request.method == "GET": return render_template("checkout.html", formLogin=formLogin) if request.method == "POST": if request.form.get("login", None) == "Login": return AccountController.authenticatePopUpLogin(formLogin, "checkout")
def checkout(): """ To address user pop up login , we have to pass formLogin to each page """ formLogin = AccountForm.LoginForm() if request.method == 'GET' : return render_template('checkout.html',formLogin=formLogin) if request.method == 'POST' : if request.form.get('login', None) == 'Login' : return AccountController.authenticatePopUpLogin(formLogin,'checkout')
def createaccount(): form = AccountForm.RegisterForm() formLogin = AccountForm.LoginForm() if request.method == "GET": return render_template("createaccount.html", form=form, formLogin=formLogin) if request.method == "POST": if request.form.get("login", None) == "Login": return AccountController.authenticatePopUpLogin(formLogin, "index") return AccountController.createuser(form=form, formLogin=formLogin)