Individual.vue 4.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185
  1. <template>
  2. <section class="indi-ctnr">
  3. <mt-header title="个人认证">
  4. <span @click='$router.go(-1);' slot="left">
  5. <
  6. </span>
  7. </mt-header>
  8. <section class="indi-box">
  9. <div class="info-box" v-show="!showResult">
  10. <div class="info">
  11. <mt-field label="姓名" placeholder="请输入真是姓名" v-model="user.name">
  12. </mt-field>
  13. <mt-field label="身份证" placeholder="请输入身份证号码" type="num" v-model="user.idCard">
  14. </mt-field>
  15. <mt-field label="银行卡号" placeholder="请输入银行卡号" type="num" v-model="user.bankNum">
  16. </mt-field>
  17. <mt-field label="预留手机" placeholder="请输入银行预留手机号码" type="tel" v-model="user.phone">
  18. </mt-field>
  19. <mt-field label="验证码" placeholder="请输入验证码" type="num" v-model="user.authCode">
  20. <button :class="{getCode:true,countDown:!canCount}" @click="countDown">{{btnValue}}</button>
  21. </mt-field>
  22. </div>
  23. <div class="sum-box" @click="submite">提交</div>
  24. </div>
  25. <div class="res-box" v-show="showResult">
  26. <div class="resultInfo">
  27. <img src="../assets/img/我的-头像.png" />
  28. <p>{{user.name}}</p>
  29. <span>{{user.phone}}</span>
  30. </div>
  31. </div>
  32. </section>
  33. </section>
  34. </template>
  35. <script type="text/javascript">
  36. export default{
  37. data(){
  38. return{
  39. showResult:false,
  40. canCount:true,
  41. btnValue:"获取验证码",
  42. user:{
  43. name: "",
  44. idCard: "",
  45. bankNum: "",
  46. phone: "",
  47. authCode: "",
  48. }
  49. }
  50. },methods:{
  51. submite: function() {
  52. if(this.user.name==""||this.user.phone==""){
  53. alert("请输入姓名和手机号");
  54. }else{
  55. this.showResult=true;
  56. }
  57. },
  58. countDown: function() {
  59. if(!this.canCount){
  60. return;
  61. }else{
  62. this.canCount=false;
  63. var num = 60;
  64. this.btnValue = num+"s";
  65. var timer = setInterval(()=>{
  66. num--;
  67. this.btnValue = num+"s";
  68. if(num==0){
  69. clearInterval(timer);
  70. this.btnValue = "获取验证码";
  71. this.canCount = true;
  72. }
  73. },1000);
  74. }
  75. }
  76. }
  77. }
  78. </script>
  79. <style scoped>
  80. .indi-ctnr{
  81. position: absolute;
  82. left: 0;
  83. right: 0;
  84. top: 0;
  85. bottom: 0;
  86. background: #60c0ff;
  87. .mint-header{
  88. height: 1.49333333rem;
  89. font-size: .45333333rem;
  90. background-color: #60c0ff;
  91. span{
  92. display: block;
  93. font-size: 0.533049rem;
  94. margin-left: 0.066631rem;
  95. }
  96. }
  97. .indi-box{
  98. margin-top: 1.066098rem;
  99. height: calc(100% - 2.558635rem);
  100. background-color: #E8EFF5;
  101. .info-box{
  102. position: relative;
  103. top: -1.066098rem;
  104. width: 8.795309rem;
  105. margin: 0 auto;
  106. .info{
  107. border-radius: 0.266525rem;
  108. overflow: hidden;
  109. box-shadow: 0 3px 21px 5px rgba(96, 192, 255, 0.35);
  110. div.mint-cell-wrapper{
  111. font-size: 0.373134rem !impotant;
  112. }
  113. .getCode{
  114. width: 2.66666667rem;
  115. height: .90666667rem;
  116. border-radius: .45333333rem;
  117. border: .02666667rem solid #60c0ff;
  118. background-color: #fff;
  119. color: #60c0ff;
  120. font-size: .37333333rem;
  121. }
  122. }
  123. .sum-box{
  124. width: 8.8rem;
  125. height: 1.06666667rem;
  126. display: block;
  127. margin: .53333333rem auto 0;
  128. background-color: #60c0ff;
  129. box-shadow: 0px .04rem .28rem .06666667rem rgba(96, 192, 255, .35);
  130. border-radius: .53333333rem;
  131. line-height: 1.06666667rem;
  132. color: #fff;
  133. font-size: .4rem;
  134. }
  135. }
  136. .res-box{
  137. position: relative;
  138. top: -1.066098rem;
  139. width: 8.795309rem;
  140. height: 14.1258rem;
  141. margin: 0 auto;
  142. background-color: #fff;
  143. border-radius: 10px;
  144. box-shadow: 0 .04rem .28rem .06666667rem rgba(96, 192, 255, .35);
  145. padding-top: 3.73333333rem;
  146. img{
  147. width: 2.66666667rem;
  148. display: block;
  149. margin: 0 auto .4rem;
  150. }
  151. p{
  152. color: #1491e2;
  153. font-size: .48rem;
  154. line-height: 1rem;
  155. }
  156. span{
  157. color: #1491e2;
  158. font-size: .42666667rem;
  159. }
  160. }
  161. }
  162. }
  163. .mint-cell{
  164. min-height: 1.1rem;
  165. }
  166. .mint-cell-wrapper{
  167. padding: 0 .29333333rem;
  168. font-size: 0.373134rem !impotant;
  169. }
  170. .mint-field .mint-cell-title{
  171. width: 1.53333333rem;
  172. margin-right: .46666667rem;
  173. }
  174. .mint-field-core{
  175. color: #808080;
  176. font-size: .32rem;
  177. height: 0.8rem;
  178. }
  179. a:hover{
  180. text-decoration: none;
  181. }
  182. </style>