index.vue 3.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182
  1. <template>
  2. <div class="login">
  3. <img src="../../common/assets/image/logobig.png" alt="" class="logobig" />
  4. <div class="title">请选择您的身份</div>
  5. <div class="title1">方便我们为您提供更准确的服务</div>
  6. <div class="choose">
  7. <div
  8. @click="chooseIdentity(1)"
  9. :class="isSelect === 1 ? 'select isselect' : 'select'"
  10. >
  11. <div><img class="headerImg" src="./sj.png" alt="" /></div>
  12. <div class="name">我是司机</div>
  13. <div class="huan"><van-icon name="success" /></div>
  14. </div>
  15. <div
  16. @click="chooseIdentity(2)"
  17. :class="isSelect === 2 ? 'select isselect' : 'select'"
  18. class="select"
  19. style="margin-top: 20px"
  20. >
  21. <div><img class="headerImg" src="./qy.png" alt="" /></div>
  22. <div class="name">我是企业</div>
  23. <div class="huan"><van-icon name="success" /></div>
  24. </div>
  25. </div>
  26. <div class="btnbox">
  27. <van-button class="btn" @click="goLogin">去登陆</van-button>
  28. </div>
  29. </div>
  30. </template>
  31. <script>
  32. export default {
  33. data() {
  34. return {
  35. loginForm: {},
  36. isSelect: 1,
  37. };
  38. },
  39. mounted() {},
  40. methods: {
  41. chooseIdentity(e) {
  42. this.isSelect = e;
  43. },
  44. goLogin() {
  45. if (this.isSelect == 1) {
  46. uni.navigateTo({
  47. url: "/pages/login/login",
  48. });
  49. }
  50. if (this.isSelect == 2) {
  51. uni.navigateTo({
  52. url: "/pages/subPackages/phoneRegister/index",
  53. });
  54. }
  55. },
  56. },
  57. };
  58. </script>
  59. <style lang="scss">
  60. .login {
  61. background: white;
  62. height: 100%;
  63. overflow: hidden;
  64. .logTit {
  65. width: 80vw;
  66. left: 10vw;
  67. top: 45vw;
  68. display: flex;
  69. flex-direction: column;
  70. justify-content: center;
  71. align-items: center;
  72. position: absolute;
  73. z-index: 1;
  74. color: rgba(51, 51, 51, 1);
  75. font-size: 4vw;
  76. p {
  77. color: rgba(102, 102, 102, 1);
  78. font-size: 4vw;
  79. margin-top: 0.5vw;
  80. }
  81. .titletxt {
  82. font-size: 48rpx;
  83. font-family: Taipei Sans TC Beta-Bold, Taipei Sans TC Beta;
  84. font-weight: bold;
  85. color: #333333;
  86. }
  87. .titletxt2 {
  88. font-size: 32rpx;
  89. font-family: PingFang SC-Regular, PingFang SC;
  90. font-weight: 400;
  91. color: #666666;
  92. }
  93. }
  94. .logobig {
  95. width: 100vw;
  96. height: 100vh;
  97. position: absolute;
  98. left: 0;
  99. z-index: 0;
  100. }
  101. .title {
  102. font-weight: bold;
  103. font-size: 52rpx;
  104. color: #222222;
  105. position: absolute;
  106. top: 342px;
  107. left: 52px;
  108. }
  109. .title1 {
  110. position: absolute;
  111. top: 381px;
  112. left: 52px;
  113. font-weight: 400;
  114. font-size: 28rpx;
  115. color: #666666;
  116. }
  117. .huan {
  118. width: 40rpx;
  119. height: 40rpx;
  120. border: 4rpx solid #c0c2c3;
  121. background: #ffffff;
  122. color: #c0c2c3;
  123. border-radius: 50%;
  124. text-align: center;
  125. line-height: 40rpx;
  126. }
  127. .choose {
  128. position: absolute;
  129. top: 800rpx;
  130. width: 100%;
  131. .headerImg {
  132. height: 88rpx;
  133. width: 88rpx;
  134. }
  135. .select {
  136. margin: auto;
  137. display: flex;
  138. align-items: center;
  139. justify-content: space-between;
  140. width: 654rpx;
  141. height: 128rpx;
  142. background: #ffffff;
  143. border-radius: 16rpx 16rpx 16rpx 16rpx;
  144. padding: 20rpx 32rpx;
  145. box-sizing: border-box;
  146. }
  147. .name {
  148. margin-right: 160px;
  149. }
  150. }
  151. .isselect {
  152. border: 2rpx solid #8a0554;
  153. .huan {
  154. background: rgba(138, 5, 84, 1);
  155. color: white;
  156. }
  157. }
  158. .btnbox {
  159. position: absolute;
  160. bottom: 170rpx;
  161. width: 100%;
  162. display: flex;
  163. justify-content: center;
  164. .btn {
  165. button {
  166. width: 594rpx;
  167. height: 96rpx;
  168. background: #8a0554;
  169. border-radius: 48rpx 48rpx 48rpx 48rpx;
  170. text-align: center;
  171. line-height: 96rpx;
  172. color: white;
  173. }
  174. text-align: center;
  175. }
  176. }
  177. }
  178. </style>