index.vue 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. <template>
  2. <div class="supplier" style="background: #f2f1f1;padding-top:20px;">
  3. <div class="container">
  4. <div class="article">
  5. <article-one></article-one>
  6. <article-two></article-two>
  7. </div>
  8. <div class="section">
  9. <banner/>
  10. <!--<carousel>-->
  11. <!--<kind-category @loadchild="loadProductKinds"></kind-category>-->
  12. <!--</carousel>-->
  13. <merchant-view/>
  14. </div>
  15. </div>
  16. </div>
  17. </template>
  18. <script>
  19. import { KindCategory, Carousel } from '~components/home'
  20. import { MerchantView, Banner, ArticleOne, ArticleTwo } from '~components/supplier'
  21. export default {
  22. name: 'SupplierView',
  23. layout: 'main',
  24. fetch ({store}) {
  25. return Promise.all([
  26. store.dispatch('supplier/loadVendorList', {page: 1, size: 10}),
  27. store.dispatch('supplier/loadVendorAll', {page: 1, size: 20}),
  28. store.dispatch('supplier/loadNewMerchant', {filter: 'page', size: 10}),
  29. store.dispatch('supplier/loadRecommend', {size: 19})
  30. ])
  31. },
  32. components: {
  33. KindCategory,
  34. Carousel,
  35. MerchantView,
  36. Banner,
  37. ArticleOne,
  38. ArticleTwo
  39. }
  40. }
  41. </script>