office.vue 4.2KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175
  1. <!-- home -->
  2. <template>
  3. <div class="office-index">
  4. <pure-image :bg-image="require('@/assets/office/1.png')"></pure-image>
  5. <office-image class="office-navi" @goto="handleGoto" />
  6. <div v-for="(item, index) in list" :key="item.image">
  7. <yz-modal :visible="visible[index]" class="office-modal">
  8. <pure-image :bg-image="item.image"></pure-image>
  9. <div class="back-sign" @click="cancelShow(index)">
  10. <img :src="item.backSign" alt />
  11. </div>
  12. </yz-modal>
  13. </div>
  14. <yz-modal :visible="visible[2]" class="apartment-modal">
  15. <swiper-image :list="featureList"></swiper-image>
  16. <div class="back-sign" @click="cancelShow(2)">
  17. <img :src="backSignImg" alt />
  18. </div>
  19. </yz-modal>
  20. <yz-modal :visible="visible[3]" class="apartment-modal">
  21. <swiper-image :list="houseList"></swiper-image>
  22. <div class="back-sign" @click="cancelShow(3)">
  23. <img :src="backSignImg" alt />
  24. </div>
  25. </yz-modal>
  26. <div class="back-sign index-back" @click="handleGotoIndex(index)">
  27. <img :src="backSignImg" alt />
  28. </div>
  29. </div>
  30. </template>
  31. <script>
  32. import { share } from '@/utils/wx'
  33. const backSignImg = require('@/assets/office/1-2.png')
  34. const backSignImg2 = require('@/assets/images/apartment/backSign-2.png')
  35. const shareImg = `${location.origin}${location.pathname}wx_share.jpg`
  36. export default {
  37. components: {
  38. PureImage: () => import('./components/PureImage.vue'),
  39. SwiperImage: () => import('./components/SwiperImage.vue'),
  40. // ApartmentNavi: () => import('./components/ApartmentNavi.vue'),
  41. OfficeImage: () => import('./components/OfficeImage.vue')
  42. },
  43. data() {
  44. return {
  45. backSignImg,
  46. backSignImg2,
  47. visible: Array(5).fill(false),
  48. list: [
  49. {
  50. image: require('@/assets/office/2-1.png'),
  51. color: '#f0f0f0',
  52. backSign: backSignImg
  53. },
  54. {
  55. image: require('@/assets/office/3-1.png'),
  56. color: '#f0f0f0',
  57. backSign: backSignImg2
  58. },
  59. {
  60. image: require('@/assets/office/4-1.png'),
  61. color: '#f0f0f0',
  62. backSign: backSignImg
  63. },
  64. {
  65. image: require('@/assets/office/5-1.png'),
  66. color: '#f0f0f0',
  67. backSign: backSignImg
  68. },
  69. {
  70. image: require('@/assets/office/6-1.png'),
  71. color: '#f0f0f0',
  72. backSign: backSignImg
  73. }
  74. ],
  75. houseList: [
  76. {
  77. image: require('@/assets/office/5-1.png'),
  78. color: '#f0f0f0'
  79. },
  80. {
  81. image: require('@/assets/office/5-2.png'),
  82. color: '#f0f0f0'
  83. },
  84. {
  85. image: require('@/assets/office/5-3.png'),
  86. color: '#f0f0f0'
  87. },
  88. {
  89. image: require('@/assets/office/5-4.png'),
  90. color: '#f0f0f0'
  91. },
  92. {
  93. image: require('@/assets/office/5-5.png'),
  94. color: '#f0f0f0'
  95. }
  96. ],
  97. featureList: [
  98. {
  99. image: require('@/assets/office/4-1.png'),
  100. color: '#f0f0f0'
  101. },
  102. {
  103. image: require('@/assets/office/4-2.png'),
  104. color: '#f0f0f0'
  105. },
  106. {
  107. image: require('@/assets/office/4-3.png'),
  108. color: '#f0f0f0'
  109. }
  110. ]
  111. }
  112. },
  113. mounted() {
  114. share({ title: '华侨城欢乐滨江可售物业', link: window.location.href, imgUrl: shareImg })
  115. },
  116. methods: {
  117. handleGoto(inx) {
  118. // inx 是从1开始的
  119. this.$set(this.visible, inx - 1, true)
  120. },
  121. cancelShow(inx) {
  122. this.$set(this.visible, inx, false)
  123. },
  124. handleGotoIndex(inx) {
  125. this.$router.push({ path: '/' })
  126. }
  127. }
  128. }
  129. </script>
  130. <style lang="scss" scoped>
  131. .office-index {
  132. height: 100%;
  133. position: relative;
  134. overflow: hidden;
  135. .office-modal {
  136. position: absolute;
  137. width: 100%;
  138. height: 100%;
  139. bottom: 0;
  140. left: 0;
  141. }
  142. .office-navi {
  143. position: absolute;
  144. width: 100%;
  145. height: 40%;
  146. bottom: 0;
  147. left: 0;
  148. }
  149. .back-sign {
  150. position: absolute;
  151. z-index: 500;
  152. right: 10px;
  153. bottom: -10px;
  154. width: 76px;
  155. height: 68px;
  156. img {
  157. width: 100%;
  158. height: 100%;
  159. }
  160. }
  161. }
  162. </style>