store.vue 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. <template>
  2. <view class="diy-store" :style="{ background: itemData.style.background }">
  3. <view class="diy-head d-b-c">
  4. <view class="left d-s-c">
  5. <view class="name">
  6. 线下门店
  7. </view>
  8. </view>
  9. </view>
  10. <view class="store-item d-s-c p-30-0" :key="index" v-for="(store, index) in itemData.data" @click="gotoDetail(store.store_id)">
  11. <view class="store-item-logo mr30"><image :src="store.logo_image" mode="aspectFill"></image></view>
  12. <view class="flex-1 o-h">
  13. <view class="ww100 f34 gray3 text-ellipsis">
  14. <text>{{ store.store_name }}</text>
  15. </view>
  16. <view class="text-ellipsis mt10 f24 gray3">门店地址:{{ store.region.province }}{{ store.region.city }}{{ store.region.region }}{{ store.address }}</view>
  17. <view class="mt10 f24">
  18. <text>联系电话:{{ store.phone }}</text>
  19. </view>
  20. </view>
  21. </view>
  22. </view>
  23. </template>
  24. <script>
  25. export default {
  26. data() {
  27. return {};
  28. },
  29. props: ['itemData'],
  30. methods: {
  31. /*跳转门店详情*/
  32. gotoDetail(e) {
  33. let url = 'pages/store/detail/detail?store_id=' + e;
  34. this.gotoPage(url);
  35. }
  36. }
  37. };
  38. </script>
  39. <style>
  40. .diy-store {
  41. margin: 20rpx;
  42. border-radius: 20rpx;
  43. padding: 0 20rpx 20rpx;
  44. background: #ffffff;
  45. box-shadow: 0 0 8rpx rgba(0, 0, 0, 0.1);
  46. }
  47. .diy-store .diy-head {
  48. height: 100rpx;
  49. }
  50. .diy-store .diy-head .name {
  51. font-size: 36rpx;
  52. font-weight: bold;
  53. }
  54. .diy-store .store-item {
  55. border-top: 1rpx solid #eeeeee;
  56. }
  57. .diy-store .store-item-logo,
  58. .diy-store .store-item-logo image {
  59. width: 120rpx;
  60. height: 120rpx;
  61. }
  62. </style>