酒店桌布为微信小程序
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

154 lines
2.8 KiB

10 months ago
10 months ago
10 months ago
9 months ago
10 months ago
9 months ago
10 months ago
9 months ago
10 months ago
9 months ago
10 months ago
  1. <template>
  2. <view class="login">
  3. <view class="logo">
  4. <!-- <image src="/static/image/login/logo.png" mode=""></image> -->
  5. </view>
  6. <view class="title">
  7. 欢迎使用布周到
  8. </view>
  9. <view class="btn mt"
  10. @click="wxLogin">
  11. <view class="icon">
  12. <image src="../static/auth/wx.png" mode=""></image>
  13. </view>
  14. <view class="">
  15. 微信授权登录
  16. </view>
  17. </view>
  18. <view class="btn b2"
  19. @click="$utils.navigateTo('/pages_order/auth/loginAndRegisterAndForgetPassword')">
  20. 使用账号密码登录
  21. </view>
  22. <view class="config">
  23. <uv-checkbox-group
  24. v-model="checkboxValue"
  25. shape="circle">
  26. <view class="content">
  27. <view
  28. style="display: flex;">
  29. <uv-checkbox
  30. size="40rpx"
  31. icon-size="30rpx"
  32. activeColor="#FD5100"
  33. :name="1"
  34. ></uv-checkbox>
  35. 阅读并同意我们的<text @click="openConfigDetail('getPrivacyPolicy')">服务协议与隐私条款</text>
  36. </view>
  37. <view class="">
  38. 以及<text @click="openConfigDetail('getUserAgreement')">个人信息保护指引</text>
  39. </view>
  40. </view>
  41. </uv-checkbox-group>
  42. </view>
  43. <configPopup ref="popup"></configPopup>
  44. </view>
  45. </template>
  46. <script>
  47. import configPopup from '@/components/config/configPopup.vue';
  48. export default {
  49. name : 'Login',
  50. data() {
  51. return {
  52. checkboxValue : []
  53. }
  54. },
  55. methods: {
  56. wxLogin(){
  57. if(!this.checkboxValue.length){
  58. return uni.showToast({
  59. title: '请先同意隐私协议',
  60. icon:'none'
  61. })
  62. }
  63. this.$store.commit('login')
  64. },
  65. //打开应用配置
  66. openConfigDetail(key){
  67. this.$refs.popup.open(key)
  68. }
  69. }
  70. }
  71. </script>
  72. <style scoped lang="scss">
  73. .login{
  74. display: flex;
  75. justify-content: center;
  76. align-items: center;
  77. height: 80vh;
  78. flex-direction: column;
  79. position: relative;
  80. .logo{
  81. height: 140rpx;
  82. width: 140rpx;
  83. background-color: #ddd;
  84. border-radius: 30rpx;
  85. image{
  86. width: 80rpx;
  87. height: 80rpx;
  88. }
  89. margin-bottom: 20rpx;
  90. }
  91. .title{
  92. position: relative;
  93. font-weight: 900;
  94. font-size: 45rpx;
  95. &::after{
  96. content: '';
  97. position: absolute;
  98. left: 0;
  99. top: 100%;
  100. display: block;
  101. height: 8rpx;
  102. width: 210rpx;
  103. background: linear-gradient(to right,$uni-color, #fff);
  104. }
  105. }
  106. .btn{
  107. width: 80%;
  108. height: 100rpx;
  109. background-color: $uni-color;
  110. color: #fff;
  111. display: flex;
  112. justify-content: center;
  113. align-items: center;
  114. margin: 20rpx 0;
  115. border-radius: 20rpx;
  116. .icon{
  117. margin-right: 10rpx;
  118. image{
  119. width: 40rpx;
  120. height: 35rpx;
  121. }
  122. }
  123. }
  124. .b2{
  125. background-color: rgba($uni-color, 0.2);
  126. color: $uni-color;
  127. }
  128. .mt{
  129. margin-top: 200rpx;
  130. }
  131. .config{
  132. position: absolute;
  133. bottom: 0;
  134. font-size: 22rpx;
  135. text-align: center;
  136. line-height: 40rpx;
  137. text{
  138. color: $uni-color;
  139. }
  140. }
  141. }
  142. </style>