Commit 1723e1be authored by 黄奎's avatar 黄奎

11

parent 3cb323f3
...@@ -73,8 +73,6 @@ ...@@ -73,8 +73,6 @@
radios.forEach(radio => { radios.forEach(radio => {
radio.addEventListener('click', function() { radio.addEventListener('click', function() {
x.ScoreNum = radio.value x.ScoreNum = radio.value
// 当单选按钮被点击时,输出它的值
// console.log('Selected value:', radio.value);
}); });
}); });
}) })
......
...@@ -420,8 +420,6 @@ ...@@ -420,8 +420,6 @@
display: flex; display: flex;
flex-direction: column; flex-direction: column;
flex: 1; flex: 1;
/* overflow: hidden;
overflow-y: auto; */
padding-bottom: 20px; padding-bottom: 20px;
} }
......
<!DOCTYPE html> <!DOCTYPE html>
<html lang="en"> <html lang="en">
<head>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, user-scalable=no, target-densitydpi=device-dpi" /> <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, user-scalable=no, target-densitydpi=device-dpi" />
<meta name="screen-orientation"content="portrait"></meta> <meta name="screen-orientation" content="portrait">
<meta name="x5-orientation"content="portrait"></meta> </meta>
<meta name="x5-orientation" content="portrait">
</meta>
<link rel="shortcut icon" href="../../images/favicon.ico" type="image/x-icon" /> <link rel="shortcut icon" href="../../images/favicon.ico" type="image/x-icon" />
<link rel="stylesheet" href="../../css/cssReset.css"> <link rel="stylesheet" href="../../css/cssReset.css">
<link rel="stylesheet" href="../../css/bts/bootstrap.min.css"> <link rel="stylesheet" href="../../css/bts/bootstrap.min.css">
<title>验证</title> <title>验证</title>
</head> </head>
<body>
<body>
<div class="login_content" id="login_content"> <div class="login_content" id="login_content">
<div class="login_button" id="login_button"> <div class="login_button" id="login_button">
<button onclick="changeLoginType(1)">手机号验证</button> <button onclick="changeLoginType(1)">手机号验证</button>
<button onclick="changeLoginType(2)">护照号验证</button> <button onclick="changeLoginType(2)">护照号验证</button>
</div> </div>
</div> </div>
<!-- <div class="login_phone" id="login_phone">
<div class="loginForm">
<div class="loginFormT">
<div><img class="logo" src="../../images/phone.png" alt=""></div>
<input type="phone" class="form-control" id="loginFormT" autocomplete="new-password"
placeholder="请输入手机号码"
onblur="activeFun(1)">
</div>
<button onclick="guestLogin()" class="loginB" id="loginB">确认</button>
<div class="loginBackBox">
<img class="BackImg" onclick="goBack()" src="../../images/login/login_arrowleft.png" />
</div>
</div>
</div> -->
<div class="Passport_phone" id="login_phone"> <div class="Passport_phone" id="login_phone">
<div class="PassportForm"> <div class="PassportForm">
<h3>身份确认</h3> <h3>身份确认</h3>
<input type="phone" class="form-control" id="loginFormT" autocomplete="new-password" <input type="phone" class="form-control" id="loginFormT" autocomplete="new-password" placeholder="请输入手机号码" onblur="activeFun(1)">
placeholder="请输入手机号码"
onblur="activeFun(1)">
<button onclick="guestLogin()" class="PassportB" id="loginB">确认</button> <button onclick="guestLogin()" class="PassportB" id="loginB">确认</button>
<div class="loginBackBox"> <div class="loginBackBox">
<img class="BackImg" onclick="goBack()" src="../../images/login/login_arrowleft.png" /> <img class="BackImg" onclick="goBack()" src="../../images/login/login_arrowleft.png" />
</div> </div>
</div> </div>
</div> </div>
<div class="Passport_phone" id="Passport_phone"> <div class="Passport_phone" id="Passport_phone">
<div class="PassportForm"> <div class="PassportForm">
<h3>身份确认</h3> <h3>身份确认</h3>
<input type="phone" class="form-control" id="PassportFormT" autocomplete="new-password" <input type="phone" class="form-control" id="PassportFormT" autocomplete="new-password" placeholder="请输入护照号" onblur="activeFun(2)">
placeholder="请输入护照号"
onblur="activeFun(2)">
<button onclick="guestLogin()" class="PassportB" id="PassportB">确认</button> <button onclick="guestLogin()" class="PassportB" id="PassportB">确认</button>
<div class="loginBackBox"> <div class="loginBackBox">
<img class="BackImg" onclick="goBack()" src="../../images/login/login_arrowleft.png" /> <img class="BackImg" onclick="goBack()" src="../../images/login/login_arrowleft.png" />
...@@ -80,19 +58,22 @@ ...@@ -80,19 +58,22 @@
$('#login_content').show() $('#login_content').show()
$('#login_phone').hide() $('#login_phone').hide()
$('#Passport_phone').hide() $('#Passport_phone').hide()
function goBack() { function goBack() {
$('#login_content').show() $('#login_content').show()
$('#login_phone').hide() $('#login_phone').hide()
$('#Passport_phone').hide() $('#Passport_phone').hide()
} }
function changeLoginType(type){
function changeLoginType(type) {
$('#login_content').hide() $('#login_content').hide()
if(type==1) $('#login_phone').show() if (type == 1) $('#login_phone').show()
if(type==2) $('#Passport_phone').show() if (type == 2) $('#Passport_phone').show()
msg.type = type msg.type = type
} }
function guestLogin(){
if(msg.type==1){ function guestLogin() {
if (msg.type == 1) {
let phone = $(`#loginFormT`).val() let phone = $(`#loginFormT`).val()
let obj = $(`#loginB`) let obj = $(`#loginB`)
//电话验证 //电话验证
...@@ -102,16 +83,16 @@ ...@@ -102,16 +83,16 @@
} }
msg.guestMobile = phone msg.guestMobile = phone
} }
if(msg.type==2){ if (msg.type == 2) {
let Passport = $(`#PassportFormT`).val() let Passport = $(`#PassportFormT`).val()
let objPassport = $(`#PassportB`) // let objPassport = $(`#PassportB`)
//电话验证 // //电话验证
if (!IsNumEn.test(Passport)) { // if (!IsNumEn.test(Passport)) {
objPassport.attr('disabled', true); // objPassport.attr('disabled', true);
return layer.msg('请输入有效的护照号!'); // return layer.msg('请输入有效的护照号!');
}else { // } else {
objPassport.attr('disabled', false); // objPassport.attr('disabled', false);
} // }
msg.guestMobile = Passport msg.guestMobile = Passport
} }
...@@ -120,73 +101,79 @@ ...@@ -120,73 +101,79 @@
url: `${getApiUrl().urlPost}`, url: `${getApiUrl().urlPost}`,
contentType: "application/json", contentType: "application/json",
data: getAjaxData("miniProgram_price_GetGuestByPhone_V2", msg), data: getAjaxData("miniProgram_price_GetGuestByPhone_V2", msg),
async: false,//使用同步的方式,true为异步方式 async: false, //使用同步的方式,true为异步方式
success: function (res) { success: function(res) {
if (res.resultCode === 1) { if (res.resultCode === 1) {
var tempData = res.data var tempData = res.data
if(tempData&&tempData.length>0){ if (tempData && tempData.length > 0) {
var datas = { var datas = {
TCID: msg.TCID, TCID: msg.TCID,
GuestId:tempData[0].Id, GuestId: tempData[0].Id,
SurName: tempData[0].SurName?tempData[0].SurName:'', SurName: tempData[0].SurName ? tempData[0].SurName : '',
Sex:tempData[0].Sex, Sex: tempData[0].Sex,
OrderId:tempData[0].OrderId, OrderId: tempData[0].OrderId,
} }
if(msg.type==1) window.location.href='MobileVerification.html?TCID='+datas.TCID+'&GuestId='+datas.GuestId+'&SurName='+datas.SurName+'&Sex='+datas.Sex+'&OrderId='+datas.OrderId+'&phone='+msg.guestMobile if (msg.type == 1) window.location.href = 'MobileVerification.html?TCID=' + datas.TCID + '&GuestId=' + datas
if(msg.type==2) window.location.href='guestSign.html?TCID='+datas.TCID+'&GuestId='+datas.GuestId+'&SurName='+datas.SurName+'&Sex='+datas.Sex+'&OrderId='+datas.OrderId+'&phone='+msg.guestMobile .GuestId + '&SurName=' + datas.SurName + '&Sex=' + datas.Sex + '&OrderId=' + datas.OrderId + '&phone=' +
msg.guestMobile
if (msg.type == 2) window.location.href = 'guestSign.html?TCID=' + datas.TCID + '&GuestId=' + datas.GuestId +
'&SurName=' + datas.SurName + '&Sex=' + datas.Sex + '&OrderId=' + datas.OrderId + '&phone=' + msg.guestMobile
} }
} else { } else {
layer.msg(res.message) layer.msg(res.message)
} }
}, },
error: function (message) { error: function(message) {
alert("提交失败" + JSON.stringify(message)); alert("提交失败" + JSON.stringify(message));
} }
}); });
} }
function activeFun(type) { function activeFun(type) {
if(type==1){ if (type == 1) {
let phone = $(`#loginFormT`).val() let phone = $(`#loginFormT`).val()
let obj = $(`#loginB`) let obj = $(`#loginB`)
//电话验证 //电话验证
if (!phoneReg.test(phone)) { if (!phoneReg.test(phone)) {
obj.attr('disabled', true); obj.attr('disabled', true);
return layer.msg('请输入有效的手机号码!'); return layer.msg('请输入有效的手机号码!');
}else { } else {
obj.attr('disabled', false); obj.attr('disabled', false);
} }
} }
if(type==2){ if (type == 2) {
let Passport = $(`#PassportFormT`).val() // let Passport = $(`#PassportFormT`).val()
let objPassport = $(`#PassportB`) // let objPassport = $(`#PassportB`)
//电话验证 // //电话验证
if (!IsNumEn.test(Passport)) { // if (!IsNumEn.test(Passport)) {
objPassport.attr('disabled', true); // objPassport.attr('disabled', true);
return layer.msg('请输入有效的护照号!'); // return layer.msg('请输入有效的护照号!');
}else { // } else {
objPassport.attr('disabled', false); // objPassport.attr('disabled', false);
} // }
} }
} }
</script> </script>
</body> </body>
<style> <style>
.login_content{ .login_content {
height: 100%; height: 100%;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
align-items: center; align-items: center;
justify-content: center; justify-content: center;
} }
.login_button{
.login_button {
width: 100%; width: 100%;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
align-items: center; align-items: center;
padding: 0 10%; padding: 0 10%;
} }
.login_button button{
.login_button button {
width: 100%; width: 100%;
height: 40px; height: 40px;
margin-bottom: 20px; margin-bottom: 20px;
...@@ -194,35 +181,41 @@ ...@@ -194,35 +181,41 @@
background-color: #419EFD; background-color: #419EFD;
color: #fff; color: #fff;
border-radius: 5px; border-radius: 5px;
} }
.login_button button:last-child{
.login_button button:last-child {
background-color: #67C239; background-color: #67C239;
} }
.login_phone{
.login_phone {
padding: 0 10%; padding: 0 10%;
height: 100%; height: 100%;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
align-items: center; align-items: center;
justify-content: center; justify-content: center;
} }
.loginForm{
.loginForm {
height: 100%; height: 100%;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
justify-content: center; justify-content: center;
align-items: center; align-items: center;
} }
.loginFormT{
.loginFormT {
width: 100%; width: 100%;
display: flex; display: flex;
flex-direction: row; flex-direction: row;
} }
.logo{
.logo {
width: auto; width: auto;
margin-right: 15px; margin-right: 15px;
} }
.loginB{
.loginB {
margin-top: 20px; margin-top: 20px;
width: 100%; width: 100%;
height: 40px; height: 40px;
...@@ -230,17 +223,20 @@ ...@@ -230,17 +223,20 @@
background-color: #419EFD; background-color: #419EFD;
border-radius: 5px; border-radius: 5px;
color: #fff; color: #fff;
} }
.loginForm input{
.loginForm input {
flex: 1; flex: 1;
/* box-shadow: 0 0 0px rgba(74, 144, 226, 0.5) !important; */ /* box-shadow: 0 0 0px rgba(74, 144, 226, 0.5) !important; */
border-bottom: 1px solid #F6F6F6 ; border-bottom: 1px solid #F6F6F6;
} }
.loginForm input:focus{
.loginForm input:focus {
border: 1px solid #76c9fa; border: 1px solid #76c9fa;
outline: none; outline: none;
} }
.loginBackBox{
.loginBackBox {
position: fixed; position: fixed;
left: 0; left: 0;
top: 0; top: 0;
...@@ -248,36 +244,41 @@ ...@@ -248,36 +244,41 @@
background: #fff; background: #fff;
padding: 20px 20px 10px 20px; padding: 20px 20px 10px 20px;
z-index: 2; z-index: 2;
} }
.BackImg{
.BackImg {
width: 10px; width: 10px;
} }
.Passport_phone{
.Passport_phone {
height: 100%; height: 100%;
overflow: hidden; overflow: hidden;
padding: 0 10%; padding: 0 10%;
} }
.PassportForm{
.PassportForm {
margin-top: 50px; margin-top: 50px;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
} }
.PassportForm input{
.PassportForm input {
margin-top: 20px; margin-top: 20px;
} }
.PassportForm input:focus{
.PassportForm input:focus {
border: 1px solid #76c9fa; border: 1px solid #76c9fa;
outline: none; outline: none;
} }
.PassportB{
.PassportB {
border: 0; border: 0;
height: 40px; height: 40px;
margin-top: 20px; margin-top: 20px;
border-radius: 5px; border-radius: 5px;
background-color: #EE4554; background-color: #EE4554;
color: #fff; color: #fff;
} }
</style>
</style>
</html> </html>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment