Browse Source

计数器数据获取方式改为后端渲染。

yangc 8 years ago
parent
commit
7cb56aa0d6
2 changed files with 3 additions and 2 deletions
  1. 1 1
      components/main/count/Box.vue
  2. 2 1
      pages/index.vue

+ 1 - 1
components/main/count/Box.vue

@@ -35,7 +35,7 @@
     },
     mounted () {
       this.$nextTick(() => {
-        this.loadCounts()
+//        this.loadCounts()
         // 刷新统计信息
         setInterval(() => {
           this.loadCounts()

+ 2 - 1
pages/index.vue

@@ -20,7 +20,8 @@
         store.dispatch('loadFloors'),
         store.dispatch('loadBanners', {type: 'home'}),
         store.dispatch('loadProductKinds', { id: 0 }),
-        store.dispatch('loadNewsSnapshot', { page: 1, pageSize: 10 })
+        store.dispatch('loadNewsSnapshot', { page: 1, pageSize: 10 }),
+        store.dispatch('loadProductCounts', { _status: 'actived' })
       ])
     },
     components: {