From f8213a1a2a1a4696f2f6bfc2db50782fce194c78 Mon Sep 17 00:00:00 2001 From: ibuler Date: Thu, 17 Dec 2015 11:05:43 +0800 Subject: [PATCH] user update password null --- juser/views.py | 3 --- templates/juser/change_info.html | 6 ------ 2 files changed, 9 deletions(-) diff --git a/juser/views.py b/juser/views.py index f5351599e..ed2c11f2a 100644 --- a/juser/views.py +++ b/juser/views.py @@ -425,9 +425,6 @@ def change_info(request): if '' in [name, email]: error = '不能为空' - if len(password) < 6: - error = '密码须大于6位' - if not error: User.objects.filter(id=user_id).update(name=name, email=email) if len(password) > 0: diff --git a/templates/juser/change_info.html b/templates/juser/change_info.html index 0191fdc19..d2960340d 100644 --- a/templates/juser/change_info.html +++ b/templates/juser/change_info.html @@ -93,12 +93,6 @@ $('#userForm').validator({ }, fields: { - "password": { - rule: "length[6~50];check_pass", - tip: "输入密码", - ok: "", - msg: {required: "必须填写!"} - }, "name": { rule: "required", tip: "姓名",