| | |
| | | string string1 = context.GetString("account"); |
| | | string string2 = context.GetString("password"); |
| | | string userName = context.GetString("userName"); |
| | | string userType = context.GetString("userType"); |
| | | string string3 = context.GetString("email"); |
| | | string string4 = context.GetString("mobile"); |
| | | int int2 = context.GetInt("emailFlag"); |
| | |
| | | if (string.IsNullOrEmpty(string2) || string2.Length < 6) |
| | | throw new ArgumentException("账户密码至少6位,请重新输入!"); |
| | | if (string.IsNullOrEmpty(userName)) |
| | | throw new ArgumentException("账号名称不能为空,请输入!"); |
| | | throw new ArgumentException("账户名称不能为空,请输入!"); |
| | | if (string.IsNullOrEmpty(userType)) |
| | | throw new ArgumentException("账户类型不能为空,请选择!"); |
| | | if (context.GetBoolean("isVerification")) |
| | | num = 1; |
| | | string string5 = context.GetString("clientIp"); |
| | |
| | | throw new ArgumentException("账户名称已经存在,请重新输入!"); |
| | | |
| | | sysUser.UserName = userName; |
| | | sysUser.UserType = string.IsNullOrEmpty(userType) ? 0 : int.Parse(userType); |
| | | sysUser.CreateTime = DateTime.Now; |
| | | if (int1 > 0) |
| | | { |
| | |
| | | context.CheckRight("1041", FailedOperation.PromptOnly); |
| | | if (this._Dao.Exists(string1)) |
| | | throw new ArgumentException("账户已经存在,请重新输入!"); |
| | | |
| | | this._Dao.Add(sysUser); |
| | | } |
| | | return new JsonPageResult(true, (object) "账户保存成功!"); |