forget.vue 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119
  1. <template>
  2. <page-loading class="forget-page" :loading="loading">
  3. <view class="logo logo-white" />
  4. <view class="static-text">本平台仅限极创社会员使用,无账号的请联系下方客服电话或微信</view>
  5. <view
  6. v-for="(item,index) in contacts"
  7. :key="index"
  8. class="contact-item"
  9. >
  10. <view
  11. v-if="item.phone_num"
  12. @click="handleCallPhone(item.phone_num)"
  13. >
  14. <view class="text main-center cross-center">{{ item.name }}</view>
  15. <view class="phone-num main-center cross-center">
  16. <view class="icon phone" />
  17. <text>{{ item.phone_num }}</text>
  18. </view>
  19. </view>
  20. <view
  21. v-else-if="item.wechat_num"
  22. @click="$util.copyText(item.wechat_num)"
  23. >
  24. <view class="text main-center cross-center">{{ item.name }}</view>
  25. <view class="phone-num main-center cross-center">
  26. <view class="icon wechat" />
  27. <text>{{ item.wechat_num }}</text>
  28. <view class="icon copy" />
  29. </view>
  30. </view>
  31. </view>
  32. </page-loading>
  33. </template>
  34. <script>
  35. import PageLoading from '@/components/PageLoading'
  36. export default {
  37. name: 'Forget',
  38. components: { PageLoading },
  39. data() {
  40. return {
  41. loading: true,
  42. contacts: []
  43. }
  44. },
  45. computed: {},
  46. methods: {
  47. handleCallPhone(phoneNumber) {
  48. uni.makePhoneCall({
  49. phoneNumber: phoneNumber
  50. })
  51. },
  52. getContact() {
  53. this.$api.setting.loginContact().then(res => {
  54. this.loading = false
  55. this.contacts = res.data
  56. })
  57. }
  58. },
  59. onLoad() {
  60. this.getContact()
  61. }
  62. }
  63. </script>
  64. <style lang="scss" scoped>
  65. .forget-page {
  66. padding: 0 30rpx;
  67. .logo{
  68. margin: 100rpx auto 50rpx;
  69. }
  70. .static-text{
  71. text-align: center;
  72. margin-bottom: 60rpx;
  73. line-height: 1.65;
  74. }
  75. .contact-item{
  76. .text{
  77. position: relative;
  78. font-size: 38rpx;
  79. &:before,&:after{
  80. content: "";
  81. position: absolute;
  82. width: 20rpx;
  83. height: 4rpx;
  84. background: #000;
  85. transform: translateX(-400%);
  86. }
  87. &:after{
  88. transform: translateX(400%);
  89. }
  90. }
  91. .phone-num{
  92. margin: 10rpx 0 40rpx;
  93. .icon{
  94. width: 30rpx;
  95. height: 30rpx;
  96. background-repeat: no-repeat;
  97. background-position: center;
  98. background-size: 100%;
  99. margin: 0 8rpx;
  100. &.phone{
  101. background-image: url("/static/image/icon/phone.png");
  102. }
  103. &.wechat{
  104. background-image: url("/static/image/icon/wechat.png");
  105. }
  106. &.copy{
  107. background-image: url("/static/image/icon/copy.png");
  108. background-size: 90%;
  109. margin-left: 16rpx;
  110. }
  111. }
  112. }
  113. }
  114. }
  115. </style>