联系方式修改
This commit is contained in:
@@ -330,14 +330,27 @@ namespace Home.Controllers
|
||||
/// </summary>
|
||||
/// <param name="request"></param>
|
||||
/// <returns></returns>
|
||||
[HttpGet, AllowAnonymous]
|
||||
public async Task<ApiResult> SendPhoneCode(string phone,string key)
|
||||
// [HttpGet, AllowAnonymous]
|
||||
// public async Task<ApiResult> SendPhoneCode(string phone,string key)
|
||||
// {
|
||||
// return new ApiResult(ResultCode.C_SUCCESS, "验证码已发送到您的手机");
|
||||
// }
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 发送手机验证码
|
||||
/// </summary>
|
||||
/// <param name="request"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, AllowAnonymous]
|
||||
public async Task<ApiResult> SendPhoneCodevefy(string phone,string key)
|
||||
{
|
||||
key = $"{key}:{phone}";
|
||||
|
||||
if (key.StartsWith("User_Code:") &&m_UserService.Exist(m => m.LoginCode == phone || m.Phone == phone))
|
||||
{
|
||||
return new ApiResult(ResultCode.C_ALREADY_EXISTS_ERROR, "该手机号已经注册了");
|
||||
return new ApiResult(ResultCode.C_ALREADY_EXISTS_ERROR, "该手机号已经被注册了");
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user