def update(request): no = request.session['authuser']['no'] name = request.POST['name'] password = request.POST['password'] gender = request.POST['gender'] models.update(no, name, password, gender) request.session['authuser'] = {'no': no, 'name': name} return HttpResponseRedirect('/user/updateform')
def update(request): name = request.POST['name'] password = request.POST['password'] gender = request.POST['gender'] no = request.session['authuser']['no'] userModels.update(name, password, gender, no) request.session['authuser'] = {'no': no, 'name': name} return HttpResponseRedirect('/main')
def update(request): no = request.session['authuser']['no'] name = request.POST['name'] email = request.POST['email'] password = request.POST['password'] gender = request.POST['gender'] usermodels.update(name, email, password, gender, no) result = usermodels.fetchone(email, password) request.session['authuser']['name'] = name return render(request, 'user/update.html')
def update(request): no = request.session['authuser']['no'] name = request.POST['name'] password = request.POST['password'] gender = request.POST['gender'] if request.POST['password'] is not '': password = request.POST['password'] models.update(no, name, password, gender) request.session['authuser'] = {'no': no, 'name': name} return HttpResponseRedirect('/user/updateform?result=success') else: return HttpResponseRedirect('/user/updateform?result=fail')
def update(request): del request.session['temp'] # if request.POST['password'] is not '': # password = request.POST['password'] authuser = request.session['authuser'] no = authuser['no'] name = request.POST['name'] password = request.POST['password'] gender = request.POST['gender'] models.update(name, password, gender, no) request.session['authuser']['name'] = name return HttpResponseRedirect('/user/updatesuccess')
def test_usermodels_update(): result = usermodels.update('감자깡2', '*****@*****.**', '1234', 'male', 9)