微信

customizationDetail.vue 4.5KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199
  1. <template>
  2. <div class="mainPage" v-if="showPage">
  3. <div class="top">
  4. <img :src="detail.ModelName === '黑色'?topImgBlack:topImgRed">
  5. <div>
  6. <div class="list">
  7. <img :src="detail.ModelName === '黑色'?cover:cover2">
  8. <div>
  9. <div>云台天境 定制您的2019专属台历</div>
  10. <div>主办案场: {{detail.CaseName}}</div>
  11. <div>参与时间: {{toolClass.dateFormat(detail.CreateDate)}}</div>
  12. </div>
  13. <span>{{detail.MakeStatus === 'making' ? '制作中' : '制作完成'}}</span>
  14. </div>
  15. </div>
  16. </div>
  17. <div class="main">
  18. <div class="title">定制模版</div>
  19. <img :src="detail.cover.CalendarImg">
  20. <div class="text">云台天境日历模版</div>
  21. </div>
  22. <div class="bottom">
  23. <div class="title">定制预览</div>
  24. <div class="pic-list">
  25. <img
  26. v-for="(item,index) in detail.Imgs"
  27. :src="item.CalendarImg"
  28. :key="index"
  29. v-if="showMore || index < 4"
  30. >
  31. </div>
  32. <div v-if="!showMore" @click="more()" class="more">
  33. 查看更多
  34. <i class="iconfont icon-xia"></i>
  35. </div>
  36. <div v-else @click="noMore()" class="more">
  37. 收起
  38. <i class="iconfont icon-shang"></i>
  39. </div>
  40. </div>
  41. <div class="foot">
  42. <div>联系我们: 025-86426666</div>
  43. </div>
  44. </div>
  45. </template>
  46. <script>
  47. import cover from '@/common/icon/heise.png'
  48. import cover2 from '@/common/icon/honhse.png'
  49. import topImgRed from '@/common/icon/topImgRed.jpg'
  50. import topImgBlack from '@/common/icon/topImgBlack.png'
  51. import { createNamespacedHelpers } from 'vuex'
  52. const { mapState: mapCustomizationState, mapActions: mapCustomizationActions } = createNamespacedHelpers('customization')
  53. export default {
  54. data () {
  55. return {
  56. topImgRed,
  57. topImgBlack,
  58. cover,
  59. cover2,
  60. showPage: false,
  61. showMore: false
  62. }
  63. },
  64. created () {
  65. this.getDetail({ calendarId: this.$route.query.id }).then(() => {
  66. this.showPage = true
  67. })
  68. },
  69. computed: {
  70. ...mapCustomizationState({
  71. detail: item => item.detail
  72. })
  73. },
  74. methods: {
  75. ...mapCustomizationActions(['getDetail']),
  76. more () {
  77. this.showMore = true
  78. },
  79. noMore () {
  80. this.showMore = false
  81. }
  82. }
  83. }
  84. </script>
  85. <style lang="scss" scoped>
  86. .mainPage {
  87. overflow-y: scroll;
  88. -webkit-overflow-scrolling: touch;
  89. transform: translateZ(0);
  90. -webkit-transform: translateZ(0);
  91. }
  92. .title {
  93. font-size: 0.16rem;
  94. padding: 0.2rem 0 0.1rem 0.25rem;
  95. text-align: left;
  96. }
  97. .top {
  98. > img {
  99. width: 100%;
  100. }
  101. > div {
  102. height: 0.85rem;
  103. background: #f2f2f2;
  104. position: relative;
  105. .list {
  106. box-sizing: border-box;
  107. position: absolute;
  108. bottom: 0.1rem;
  109. left: 50%;
  110. transform: translateX(-50%);
  111. width: 3.43rem;
  112. height: 1.1rem;
  113. background: #fff;
  114. padding: 0.16rem 0.1rem;
  115. display: flex;
  116. box-shadow: 0px 2px 8px 0px rgba(204, 204, 204, 0.5);
  117. border-radius: 10px;
  118. img {
  119. width: 0.8rem;
  120. height: 0.8rem;
  121. border-radius: 0.05rem;
  122. }
  123. > div {
  124. padding: 0.05rem 0.14rem;
  125. flex: 1;
  126. div:nth-of-type(1) {
  127. color: #000;
  128. padding: 0px;
  129. }
  130. div:nth-of-type(2) {
  131. padding-top: 0.12rem;
  132. }
  133. div {
  134. font-size: 0.12rem;
  135. padding-top: 0.08rem;
  136. color: #999999;
  137. }
  138. }
  139. span {
  140. position: absolute;
  141. right: 0;
  142. top: 0.1rem;
  143. display: block;
  144. background: linear-gradient(
  145. 270deg,
  146. rgba(227, 191, 172, 1) 0%,
  147. rgba(178, 144, 132, 1) 100%
  148. );
  149. border-radius: 10px 0px 0px 10px;
  150. padding: 1px 0.1rem 2px 0.15rem;
  151. font-size: 0.12rem;
  152. }
  153. }
  154. }
  155. }
  156. .main {
  157. border-bottom: 0.1rem solid #f2f2f2;
  158. text-align: center;
  159. background: #fff;
  160. .text {
  161. padding-bottom: 0.15rem;
  162. }
  163. img {
  164. width: 1.65rem;
  165. margin: 20px;
  166. }
  167. }
  168. .bottom {
  169. background: #fff;
  170. .pic-list {
  171. justify-content: center;
  172. padding: 0.05rem;
  173. box-sizing: border-box;
  174. display: flex;
  175. flex-flow: row wrap;
  176. img {
  177. width: 1.65rem;
  178. height: 2.6rem;
  179. margin: 0.08rem;
  180. }
  181. }
  182. .more {
  183. color: #77a5f0;
  184. text-align: center;
  185. margin-bottom: 0.1rem;
  186. i {
  187. color: #77a5f0;
  188. }
  189. }
  190. }
  191. .foot {
  192. height: 0.9rem;
  193. text-align: center;
  194. line-height: 0.9rem;
  195. background: #f2f2f2;
  196. }
  197. </style>