浏览代码

修改注册默认信息

chenjunkai 6 年之前
父节点
当前提交
012f75234f
共有 1 个文件被更改,包括 4 次插入0 次删除
  1. 4 0
      Controller/UserController.py

+ 4 - 0
Controller/UserController.py

@@ -668,6 +668,8 @@ class v2registerView(TemplateView):
             return response.json(101)
         try:
             users = Device_User.objects.create(
+                username=phone,
+                NickName=phone,
                 phone=phone,
                 password=make_password(password),
                 userID=CommonService.getUserID(μs=False, setOTAID=True),
@@ -732,6 +734,8 @@ class v2registerView(TemplateView):
             return response.json(103)
         try:
             users = Device_User.objects.create(
+                username=email,
+                NickName=email,
                 userEmail=email,
                 password=make_password(password),
                 userID=CommonService.getUserID(μs=False, setOTAID=True),