login.vue 3.93 KB

<template>
	<div class="content">
		<div class="ebg">
			<img src="@/assets/images/common/login-bg.png">
		</div>
		<div class="top-space"></div>
		<div class="box">
			<!-- 帐密登陆 -->
			<div v-if="type == 1" class="login">
				<div class="login-tit"> {{$t('login.title')}} </div>
				<div class="login-nav">
					<div @click="onLoginTypeHandler(1)" class="login-nav-tit text-r pointer active">{{$t('login.loginType1')}}</div>
					<div class="login-nav-v-line">|</div>
					<div @click="onLoginTypeHandler(2)" class="login-nav-tit pointer">{{$t('login.loginType2')}}</div>
				</div>
				<div class="gird-g form">
					<div class="pure-u-1 form-item">
						<div class="label">
							<img src="@/assets/images/login/icon-login-user.png"> {{$t('login.account')}}
						</div>
						<div class="ipt-wrap">
							<input :placeholder="$t('login.accountPlaceholder')" class="ipt" type="text">
						</div>
					</div>
					<div class="pure-u-1 form-item">
						<div class="label">
							<img src="@/assets/images/login/icon-login-password.png"> {{$t('login.password')}}
						</div>
						<div class="ipt-wrap">
							<input :placeholder="$t('login.passwordPlaceholder')" class="ipt" type="text">
						</div>
					</div>
					<div class="pure-u-1 form-item">
						<div class="ipt-wrap">
							<input :placeholder="$t('login.verifyPlaceholder')" class="ipt ipt-verify" type="text">
							<div class="ipt verify-btn pointer">5136</div>
						</div>
					</div>
				</div>
				<div class="login-protocol">
					<img @click="onCheckHandler()" class="check pointer" src="@/assets/images/login/login-check.png"> {{$t('login.agree')}}
					<span @click="onProtocolHandler()" class="protocol pointer">{{$t('login.protocol')}}</span>
				</div>
				<div @click="onSubmitHandler()" class="login-submit pointer">{{$t('login.login')}}</div>
				<div class="login-func">
					<div @click="onRegisterHandler()" class="login-func-btn pointer">{{$t('login.register')}}</div>
					<div @click="onForgetHandler()" class="login-func-btn pointer">{{$t('login.forget')}}</div>
				</div>
			</div>

			<!-- OTP登陆 -->
			<div v-if="type == 2" class="login">
				<div class="login-tit"> {{$t('login.title')}}</div>
				<div class="login-nav">
					<div @click="onLoginTypeHandler(1)" class="login-nav-tit text-r pointer"> {{$t('login.loginType1')}}</div>
					<div class="login-nav-v-line">|</div>
					<div @click="onLoginTypeHandler(2)" class="login-nav-tit pointer active"> {{$t('login.loginType2')}}</div>
				</div>
				<div class="gird-g form">
					<div class="pure-u-1 form-item">
						<div class="label">
							<img src="@/assets/images/login/icon-login-phone.png"> {{$t('login.mobile')}}
						</div>
						<div class="ipt-wrap">
							<input :placeholder="$t('login.mobilePlaceholder')" class="ipt" type="text">
						</div>
					</div>
					<div class="pure-u-1 form-item">
						<div class="label">
							<img src="@/assets/images/login/icon-login-message.png"> {{$t('login.verifyCode')}}
						</div>
						<div class="ipt-wrap">
							<div class="ipt ipt2">
								<input :placeholder="$t('login.verifyCodePlaceholder')" class="ipt-code" type="text">
								<div class="veri-btn pointer"> {{$t('login.verifyCodeGet')}}</div>
							</div>
						</div>
					</div>
				</div>
				<div class="login-protocol">
					<img @click="onCheckHandler()" class="check pointer" src="@/assets/images/login/login-check.png"> {{$t('login.agree')}}
					<span @click="onProtocolHandler()" class="protocol pointer">{{$t('login.protocol')}}</span>
				</div>
				<div @click="onSubmitHandler()" class="login-submit pointer">{{$t('login.login')}}</div>
				<div class="login-func">
					<div @click="onRegisterHandler()" class="login-func-btn pointer">{{$t('login.register')}}</div>
					<div @click="onForgetHandler()" class="login-func-btn pointer">{{$t('login.forget')}}</div>
				</div>
			</div>
		</div>
	</div>
</template>

<script src="./login.js"></script>
<style lang="scss" scoped>
@import "./login.scss";
</style>