|
@@ -1,37 +1,39 @@
|
|
<template>
|
|
<template>
|
|
<div class="contentBo">
|
|
<div class="contentBo">
|
|
<Banner></Banner>
|
|
<Banner></Banner>
|
|
- <div class="reg-container">
|
|
|
|
- <h3>账号注册</h3>
|
|
|
|
- <div class="box">
|
|
|
|
- <div class="progress">
|
|
|
|
- <span class="apply">申请注册</span>
|
|
|
|
|
|
+ <div class="login-img fl"><img src="../../images/loginImg.png"/></div>
|
|
|
|
+ <div :class="['reg-container', { 'box2': !flag}]">
|
|
|
|
+ <!-- <h3>账号注册</h3> -->
|
|
|
|
+ <div :class="['box', { 'box2': !flag}]">
|
|
|
|
+ <!-- <div class="progress"> -->
|
|
|
|
+ <!-- <span class="apply">申请注册</span> -->
|
|
<!-- <span class="plan"></span> -->
|
|
<!-- <span class="plan"></span> -->
|
|
- <span :class="['plan plan_bg1',{'plan_bg2':complete}]"></span>
|
|
|
|
|
|
+ <!-- <span :class="['plan plan_bg1',{'plan_bg2':complete}]"></span> -->
|
|
<!-- <span class="finished">完成</span> -->
|
|
<!-- <span class="finished">完成</span> -->
|
|
- <span :class="['finished',{'apply':complete}]">完成</span>
|
|
|
|
- </div>
|
|
|
|
|
|
+ <!-- <span :class="['finished',{'apply':complete}]">完成</span> -->
|
|
|
|
+
|
|
|
|
+ <!-- </div> -->
|
|
|
|
+ <div v-if="flag" class="title-box clearfix"> <h3 class="login-title fl">注册</h3> <h4 class="num fr" @click="toLogin">登录</h4></div>
|
|
|
|
+ <div v-else class="title-box clearfix"> <h3 class="login-title fl">其他信息</h3> <h4 class="num fr num2">2/2</h4></div>
|
|
<form>
|
|
<form>
|
|
<div class="main" v-if="flag">
|
|
<div class="main" v-if="flag">
|
|
- <p>手机号</p>
|
|
|
|
|
|
+ <!-- <p>手机号</p> -->
|
|
<input type="tel" name="" v-model="phone" maxlength="11" @input="handleTelInput"
|
|
<input type="tel" name="" v-model="phone" maxlength="11" @input="handleTelInput"
|
|
- @blur="checkPhone">
|
|
|
|
- <p>密码</p>
|
|
|
|
- <input type="password" name="" v-model="psw" minlength="6" maxlength="16" @blur="checkPsw">
|
|
|
|
- <p>联系人</p>
|
|
|
|
- <!-- <input type="text" name="" v-model="contact" @input="handleContInput"> -->
|
|
|
|
- <input type="text" name="" v-model="contact" maxlength="10" @blur="handleContInput">
|
|
|
|
|
|
+ @blur="checkPhone" placeholder="请输入用户名或手机号">
|
|
|
|
+ <!-- <p>密码</p> -->
|
|
|
|
+ <input type="password" name="" v-model="psw" minlength="6" maxlength="16" @blur="checkPsw" placeholder="请输入密码">
|
|
|
|
+
|
|
<div class="yanzm">
|
|
<div class="yanzm">
|
|
- <p>图形验证码</p>
|
|
|
|
|
|
+ <!-- <p>图形验证码</p> -->
|
|
<input type="text" name="" v-model="picCode" @blur="checkImgCode" maxlength="4">
|
|
<input type="text" name="" v-model="picCode" @blur="checkImgCode" maxlength="4">
|
|
<img :src='"data:image/png;base64,"+imgCode' @click="refreshCode">
|
|
<img :src='"data:image/png;base64,"+imgCode' @click="refreshCode">
|
|
</div>
|
|
</div>
|
|
<div class="yanzm">
|
|
<div class="yanzm">
|
|
- <p>短信验证码</p>
|
|
|
|
|
|
+ <!-- <p>短信验证码</p> -->
|
|
<!-- <input type="text" name="" v-model="msgCode" maxlength="6" @input="handleMsg"> -->
|
|
<!-- <input type="text" name="" v-model="msgCode" maxlength="6" @input="handleMsg"> -->
|
|
<input type="text" name="" v-model="msgCode" maxlength="6" @blur="cheeckMsgCode">
|
|
<input type="text" name="" v-model="msgCode" maxlength="6" @blur="cheeckMsgCode">
|
|
- <div v-if="timerFlag" type="primary" class="getMsg disabled">{{time + 's后重新发送'}}</div>
|
|
|
|
- <div v-else class="getMsg" @click="getMsgCode">点击获取验证码</div>
|
|
|
|
|
|
+ <div v-if="timerFlag" type="primary" class="getMsg disabled">{{ '再次发送('+ time+')'}}</div>
|
|
|
|
+ <div v-else class="getMsg" @click="getMsgCode">获取验证码</div>
|
|
|
|
|
|
</div>
|
|
</div>
|
|
<!-- <span class="tips" v-show="imgCodeErr">图形验证码错误</span> -->
|
|
<!-- <span class="tips" v-show="imgCodeErr">图形验证码错误</span> -->
|
|
@@ -42,16 +44,20 @@
|
|
</div>
|
|
</div>
|
|
|
|
|
|
<div class="main" v-else>
|
|
<div class="main" v-else>
|
|
- <p>联系邮箱</p>
|
|
|
|
- <input type="email" name="" v-model="email" @blur="checkEmail">
|
|
|
|
- <p>机构名称</p>
|
|
|
|
- <input type="text" name="" v-model="agencyName" maxlength="20">
|
|
|
|
|
|
+ <!-- <p>联系邮箱</p> -->
|
|
|
|
+ <input type="email" name="" v-model="email" @blur="checkEmail" placeholder="请输入联系邮箱">
|
|
|
|
+ <!-- <p>机构名称</p> -->
|
|
|
|
+ <input type="text" name="" v-model="agencyName" maxlength="20" placeholder="请输入机构名称">
|
|
|
|
+ <!-- <p>联系人</p> -->
|
|
|
|
+ <!-- <input type="text" name="" v-model="contact" @input="handleContInput"> -->
|
|
|
|
+ <input type="text" name="" v-model="contact" maxlength="10" @blur="handleContInput" placeholder="请输入联系人">
|
|
<div class="next" v-if="submitCor">立即注册</div>
|
|
<div class="next" v-if="submitCor">立即注册</div>
|
|
<div class="next nextCor" @click="submit" v-else>立即注册</div>
|
|
<div class="next nextCor" @click="submit" v-else>立即注册</div>
|
|
</div>
|
|
</div>
|
|
</form>
|
|
</form>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
+ <copy-right-info></copy-right-info>
|
|
</div>
|
|
</div>
|
|
</template>
|
|
</template>
|
|
<script>
|
|
<script>
|
|
@@ -61,7 +67,7 @@
|
|
import '@components/register/register.less';
|
|
import '@components/register/register.less';
|
|
import Banner from '@components/common/Banner.vue';
|
|
import Banner from '@components/common/Banner.vue';
|
|
import md5 from 'js-md5'
|
|
import md5 from 'js-md5'
|
|
-
|
|
|
|
|
|
+ import copyRightInfo from '../common/CopyRightInfo.vue';
|
|
export default {
|
|
export default {
|
|
name: 'Register',
|
|
name: 'Register',
|
|
data() {
|
|
data() {
|
|
@@ -100,6 +106,11 @@
|
|
window.clearInterval(this.msgCodeTimer);
|
|
window.clearInterval(this.msgCodeTimer);
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
|
|
+ toLogin() {
|
|
|
|
+ this.$router.push({
|
|
|
|
+ path: '/'
|
|
|
|
+ });
|
|
|
|
+ },
|
|
CalcuMD5(password){
|
|
CalcuMD5(password){
|
|
// password = password.toUpperCase();
|
|
// password = password.toUpperCase();
|
|
password = md5(password);
|
|
password = md5(password);
|
|
@@ -220,6 +231,7 @@
|
|
},
|
|
},
|
|
getMsgCode() {//获取短信验证码
|
|
getMsgCode() {//获取短信验证码
|
|
//手机号、密码、联系人、图形验证码不为空且符合规则且图形验证码正确--shenq10.26
|
|
//手机号、密码、联系人、图形验证码不为空且符合规则且图形验证码正确--shenq10.26
|
|
|
|
+ console.log('sadad')
|
|
if(!this.phone.trim() && !this.phoneRg){
|
|
if(!this.phone.trim() && !this.phoneRg){
|
|
this.imgCodeErr = true;
|
|
this.imgCodeErr = true;
|
|
this.codeErrText = "手机号不能为空";
|
|
this.codeErrText = "手机号不能为空";
|
|
@@ -230,9 +242,6 @@
|
|
}else if(!this.psw.trim()){
|
|
}else if(!this.psw.trim()){
|
|
this.imgCodeErr = true;
|
|
this.imgCodeErr = true;
|
|
this.codeErrText = "密码不能为空";
|
|
this.codeErrText = "密码不能为空";
|
|
- }else if(!this.contact.trim()){
|
|
|
|
- this.imgCodeErr = true;
|
|
|
|
- this.codeErrText = "联系人不能为空";
|
|
|
|
}else if(!this.picCode.trim()){
|
|
}else if(!this.picCode.trim()){
|
|
this.imgCodeErr = true;
|
|
this.imgCodeErr = true;
|
|
this.codeErrText = "图形验证码不能为空";
|
|
this.codeErrText = "图形验证码不能为空";
|
|
@@ -412,13 +421,13 @@
|
|
watch: {
|
|
watch: {
|
|
nextButton: {
|
|
nextButton: {
|
|
handler: function (val) {//所有数据不为空,且手机格式正确、图形验证码正确
|
|
handler: function (val) {//所有数据不为空,且手机格式正确、图形验证码正确
|
|
- if (val.phone.trim() && val.psw.trim() && val.contact.trim() && val.picCode.trim() && val.msgCode.trim() && !val.imgCodeErr) {
|
|
|
|
|
|
+ if (val.phone.trim() && val.psw.trim() && val.picCode.trim() && val.msgCode.trim() && !val.imgCodeErr) {
|
|
this.changCor = false;
|
|
this.changCor = false;
|
|
} else {
|
|
} else {
|
|
this.changCor = true;
|
|
this.changCor = true;
|
|
}
|
|
}
|
|
|
|
|
|
- if (val.email.trim() && val.agencyName.trim()) {
|
|
|
|
|
|
+ if (val.email.trim() && val.agencyName.trim() && val.contact.trim()) {
|
|
this.submitCor = false;
|
|
this.submitCor = false;
|
|
this.complete = true;//完成
|
|
this.complete = true;//完成
|
|
} else {
|
|
} else {
|
|
@@ -430,7 +439,8 @@
|
|
},
|
|
},
|
|
filters: {},
|
|
filters: {},
|
|
components: {
|
|
components: {
|
|
- Banner
|
|
|
|
|
|
+ Banner,
|
|
|
|
+ copyRightInfo
|
|
},
|
|
},
|
|
}
|
|
}
|
|
</script>
|
|
</script>
|