Compare commits
2 Commits
2f14f45621
...
master
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c7c3c038a8 | ||
|
|
d1e4fb05b8 |
@@ -345,6 +345,18 @@ namespace Home.Controllers
|
||||
/// <returns></returns>
|
||||
[HttpPost, AllowAnonymous]
|
||||
public async Task<ApiResult> SendPhoneCodevefy(string phone, string key)
|
||||
{
|
||||
|
||||
return new ApiResult(ResultCode.C_SUCCESS, "验证码已发送到您的手机");
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 发送手机验证码
|
||||
/// </summary>
|
||||
/// <param name="request"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, AllowAnonymous]
|
||||
public async Task<ApiResult> SendPhonesCodevefy(string phone, string key)
|
||||
{
|
||||
key = $"{key}:{phone}";
|
||||
|
||||
|
||||
@@ -845,7 +845,7 @@
|
||||
},
|
||||
created: function () {
|
||||
this.order_info.account = this.randomString(2) + (Math.floor(Math.random() * 10000) + 1);
|
||||
this.order_info.password = (Math.floor(Math.random() * 1000) + 1);
|
||||
this.order_info.password = (Math.floor(Math.random() * 1000000) + 1);
|
||||
},
|
||||
methods: {
|
||||
randomString(len) {
|
||||
@@ -1077,8 +1077,8 @@
|
||||
alert('账号长度至少5位!');
|
||||
return;
|
||||
}
|
||||
if (this.order_info.password.length < 3 && this.hasNumAndChar(this.order_info.password)) {
|
||||
alert('密码长度至少3位!');
|
||||
if (this.order_info.password.length < 6 && this.hasNumAndChar(this.order_info.password)) {
|
||||
alert('密码长度至少6位!');
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
var name = $("#username").val()
|
||||
if(name == '') { alert('手机号不能为空'); return; }
|
||||
if (!timing(_self)) return;
|
||||
var url = '/User/SendPhoneCodevefy?key=FindUser_Code&phone=' + name;
|
||||
var url = '/User/SendPhonesCodevefy?key=FindUser_Code&phone=' + name;
|
||||
$.ajax({
|
||||
type: 'POST',
|
||||
url: url,
|
||||
|
||||
@@ -37,7 +37,7 @@
|
||||
var name = $("#username").val()
|
||||
if(name == '') { alert('手机号不能为空'); return; }
|
||||
if (!timing(_self)) return;
|
||||
var url = '/user/SendPhoneCodevefy?key=User_Code&phone=' + name;
|
||||
var url = '/user/SendPhonesCodevefy?key=User_Code&phone=' + name;
|
||||
$.ajax({
|
||||
type: 'POST',
|
||||
url: url,
|
||||
|
||||
@@ -610,7 +610,7 @@
|
||||
function getCode(_self) {
|
||||
if (!timing(_self)) return;
|
||||
var name = $("#username").val()
|
||||
var url = '/user/SendPhoneCodevefy?key=User_Code&phone=' + name;
|
||||
var url = '/user/SendPhonesCodevefy?key=User_Code&phone=' + name;
|
||||
var timerHandler;
|
||||
$.ajax({
|
||||
type: 'POST',
|
||||
@@ -624,7 +624,7 @@
|
||||
function getFindCode(_self) {
|
||||
if (!timing(_self)) return;
|
||||
var name = $("#fusername").val()
|
||||
var url = '/user/SendPhoneCodevefy?key=FindUser_Code&phone=' + name;
|
||||
var url = '/user/SendPhonesCodevefy?key=FindUser_Code&phone=' + name;
|
||||
$.ajax({
|
||||
type: 'POST',
|
||||
url: url,
|
||||
|
||||
@@ -1215,7 +1215,7 @@
|
||||
},
|
||||
created: function () {
|
||||
this.order_info.account = this.randomString(2) + (Math.floor(Math.random() * 10000) + 1);
|
||||
this.order_info.password = (Math.floor(Math.random() * 1000) + 1);
|
||||
this.order_info.password = (Math.floor(Math.random() * 1000000) + 1);
|
||||
},
|
||||
methods: {
|
||||
randomString(len) {
|
||||
@@ -1446,8 +1446,8 @@
|
||||
alert('账号长度至少5位!');
|
||||
return;
|
||||
}
|
||||
if (this.order_info.password.length < 3 && this.hasNumAndChar(this.order_info.password)) {
|
||||
alert('密码长度至少3位!');
|
||||
if (this.order_info.password.length < 6 && this.hasNumAndChar(this.order_info.password)) {
|
||||
alert('密码长度至少6位!');
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
@@ -431,7 +431,7 @@
|
||||
function getCode(_self) {
|
||||
if (!timing(_self)) return;
|
||||
var name = $("#username").val()
|
||||
var url = '/user/SendPhoneCodevefy?key=User_Code&phone=' + name;
|
||||
var url = '/user/SendPhonesCodevefy?key=User_Code&phone=' + name;
|
||||
$.ajax({
|
||||
type: 'POST',
|
||||
url: url,
|
||||
@@ -444,7 +444,7 @@
|
||||
function getFindCode(_self) {
|
||||
if (!timing(_self)) return;
|
||||
var name = $("#fusername").val()
|
||||
var url = '/user/SendPhoneCodevefy?key=FindUser_Code&phone=' + name;
|
||||
var url = '/user/SendPhonesCodevefy?key=FindUser_Code&phone=' + name;
|
||||
$.ajax({
|
||||
type: 'POST',
|
||||
url: url,
|
||||
|
||||
Reference in New Issue
Block a user