loginV2.vue 4.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212
  1. <template>
  2. <view class="container">
  3. <view class="main-container">
  4. <view class="logo"></view>
  5. <view class="main-img"></view>
  6. <view class="phone-number">13588888888</view>
  7. <view class="agreement">
  8. <view class="check-box" @click="checked = !checked">
  9. <image src="@/static/images/jobApplicant/check.svg" v-if="checked" mode="scaleToFill" />
  10. <image src="@/static/images/jobApplicant/border.svg" v-else mode="scaleToFill" />
  11. </view>
  12. <view class="content">
  13. 已阅读并同意<navigator url="/my/setting/xieyi">《亿职赞用户协议》</navigator>
  14. 和<navigator url="/my/setting/mimi">《隐私协议》</navigator>,允许亿职赞统一管理本人账号信息
  15. </view>
  16. </view>
  17. <u-button class="login-btn" shape="circle" :hairline="false" @click="login">一键登录</u-button>
  18. <view class="other-login">
  19. <view class="other-type">
  20. <view class="icon"></view>
  21. <view class="text">微信登录</view>
  22. </view>
  23. <view class="other-type">
  24. <view class="icon"></view>
  25. <view class="text">其他手机登录</view>
  26. </view>
  27. </view>
  28. </view>
  29. <view class="footer">
  30. <view class="link">企业套餐咨询</view>
  31. <view class="link">投诉举报</view>
  32. <view class="link">资质信息</view>
  33. </view>
  34. </view>
  35. </template>
  36. <script>
  37. export default {
  38. data() {
  39. return {
  40. checked: false
  41. }
  42. },
  43. onLoad() {
  44. this.handleLogin()
  45. },
  46. methods: {
  47. login() {
  48. if (!this.checked) {
  49. uni.showToast({
  50. title: '请阅读并同意协议',
  51. icon: 'none'
  52. })
  53. return
  54. }
  55. this.handleLogin()
  56. console.log('点击登录')
  57. },
  58. handleLogin() {
  59. uni.login({
  60. provider: 'univerify',
  61. univerifyStyle: {
  62. fullScreen: true,
  63. icon: {
  64. path: 'static/images/avator.png',
  65. },
  66. authButton: {
  67. normalColor: '#016BF6'
  68. // "normalColor": "#3479f5", // 授权按钮正常状态背景颜色 默认值:#3479f5
  69. // "highlightColor": "#2861c5", // 授权按钮按下状态背景颜色 默认值:#2861c5(仅ios支持)
  70. // "disabledColor": "#73aaf5", // 授权按钮不可点击时背景颜色 默认值:#73aaf5(仅ios支持)
  71. },
  72. otherLoginButton: {
  73. visible: false,
  74. },
  75. privacyTerms: {
  76. defaultCheckBoxState: false,
  77. uncheckedImage: 'static/images/jobApplicant/border.svg',
  78. checkedImage: 'static/images/jobApplicant/check.svg',
  79. privacyItems: [
  80. {
  81. "url": "/my/setting/xieyi", // 点击跳转的协议详情页面
  82. "title": "亿职赞用户协议" // 协议名称
  83. },
  84. {
  85. "url": "/my/setting/mimi", // 点击跳转的协议详情页面
  86. "title": "隐私协议" // 协议名称
  87. },
  88. ]
  89. },
  90. buttons: {
  91. iconWidth: '60px',
  92. list: [
  93. {
  94. provider: 'weixin',
  95. iconPath: 'static/images/avator.png'
  96. },
  97. {
  98. provider: 'phone',
  99. iconPath: 'static/images/avator.png'
  100. }
  101. ]
  102. }
  103. },
  104. success: (res) => {
  105. console.log(JSON.parse(JSON.stringify(res)))
  106. },
  107. fail: (err) => {
  108. console.log(JSON.parse(JSON.stringify(err)))
  109. }
  110. })
  111. }
  112. }
  113. }
  114. </script>
  115. <style lang="scss" scoped>
  116. .container {
  117. height: 100vh;
  118. display: flex;
  119. flex-direction: column;
  120. justify-content: space-between;
  121. padding: 0 70rpx;
  122. .logo {
  123. width: 204rpx;
  124. height: 56rpx;
  125. background-color: gray;
  126. margin: 72rpx auto 92rpx;
  127. }
  128. .main-img {
  129. width: 400rpx;
  130. height: 400rpx;
  131. background-color: gray;
  132. margin: 0 auto 34rpx;
  133. }
  134. .phone-number {
  135. font-size: 56rpx;
  136. font-weight: bold;
  137. line-height: 68rpx;
  138. text-align: center;
  139. }
  140. .agreement {
  141. display: flex;
  142. align-items: flex-start;
  143. font-size: 24rpx;
  144. color: #605d67;
  145. margin: 40rpx auto 68rpx;
  146. .check-box {
  147. display: flex;
  148. justify-content: center;
  149. align-items: center;
  150. margin-right: 16rpx;
  151. image {
  152. width: 24rpx;
  153. height: 24rpx;
  154. margin-top: 6rpx;
  155. }
  156. }
  157. .content {
  158. display: flex;
  159. flex-wrap: wrap;
  160. word-wrap: break-word;
  161. flex: 1;
  162. }
  163. navigator {
  164. color: #016bf6;
  165. }
  166. }
  167. .login-btn {
  168. width: 600rpx;
  169. height: 88rpx;
  170. border-radius: 100px;
  171. background: var(--线性渐变, linear-gradient(90.00deg, rgba(13, 39, 247, 1),rgba(19, 193, 234, 1) 100%));
  172. text-align: center;
  173. line-height: 88rpx;
  174. color: #fff;
  175. font-size: 32rpx;
  176. font-weight: bold;
  177. }
  178. .other-login {
  179. display: flex;
  180. justify-content: center;
  181. margin-top: 80rpx;
  182. .other-type {
  183. margin: 0 24rpx;
  184. }
  185. .icon {
  186. width: 60rpx;
  187. height: 60rpx;
  188. background-color: gray;
  189. margin: 0 auto 8rpx;
  190. }
  191. .text {
  192. text-align: center;
  193. font-size: 24rpx;
  194. line-height: 32rpx;
  195. color: rgb(153, 153, 153);
  196. }
  197. }
  198. .footer {
  199. display: flex;
  200. justify-content: center;
  201. margin-bottom: 40rpx;
  202. .link {
  203. font-size: 28rpx;
  204. color: #999999;
  205. margin: 0 14rpx;
  206. }
  207. }
  208. }
  209. </style>