许成详 6 years ago
parent
commit
c28d700730

+ 1
- 1
src/components/dashboardList/page.scss View File

10
       }
10
       }
11
       >div{
11
       >div{
12
         width: 100%;
12
         width: 100%;
13
+        height: 130px;
13
         position: relative;
14
         position: relative;
14
         overflow: hidden;
15
         overflow: hidden;
15
-        padding-bottom: 30%;
16
         border-radius: 10px;
16
         border-radius: 10px;
17
         background: #ccc;
17
         background: #ccc;
18
         >div{
18
         >div{

+ 5
- 1
src/pages/system/dataStatistics/cardCouponList/index.vue View File

37
           type="primary" @click="search">搜索</el-button>
37
           type="primary" @click="search">搜索</el-button>
38
         <el-button
38
         <el-button
39
           size="mini"
39
           size="mini"
40
-          type="success" @click="search">导出Excel</el-button>
40
+          type="success" @click="exportExcel">导出Excel</el-button>
41
       </div>
41
       </div>
42
       <div class="moreFilter"></div>
42
       <div class="moreFilter"></div>
43
     </div>
43
     </div>
153
   methods: {
153
   methods: {
154
     ...mapStaActions([
154
     ...mapStaActions([
155
       'getCardCouponList',
155
       'getCardCouponList',
156
+      'getCardCouponListExcel',
156
     ]),
157
     ]),
157
     search () { // 搜索
158
     search () { // 搜索
158
       this.page = 1
159
       this.page = 1
169
         this.total = res.total
170
         this.total = res.total
170
       })
171
       })
171
     },
172
     },
173
+    exportExcel () {
174
+      window.location.href = `${this.toolClass.ReplaceOrg(this.$api.statistics.cardCouponListExcel.url)}?token=${localStorage.getItem('JWT')}`
175
+    },
172
   }
176
   }
173
 }
177
 }
174
 </script>
178
 </script>

+ 9
- 3
src/pages/system/dataStatistics/cardCouponUsedList/index.vue View File

70
           type="primary" @click="search">搜索</el-button>
70
           type="primary" @click="search">搜索</el-button>
71
         <el-button
71
         <el-button
72
           size="mini"
72
           size="mini"
73
-          type="success" @click="search">导出Excel</el-button>
73
+          type="success" @click="exportExcel">导出Excel</el-button>
74
       </div>
74
       </div>
75
       <div class="moreFilter"></div>
75
       <div class="moreFilter"></div>
76
     </div>
76
     </div>
95
           prop="ReceivingType"
95
           prop="ReceivingType"
96
           label="获取方式">
96
           label="获取方式">
97
           <template slot-scope="scope">
97
           <template slot-scope="scope">
98
-            {{scope.row.ReceivingType === 'system' ? '系统' : scope.row.ReceivingType === 'case' ? '案场' : scope.row.ReceivingType === 'channel' ? '渠道' : ''}}
98
+            {{scope.row.ReceivingType === 'event' ? '系统' : scope.row.ReceivingType === 'case' ? '案场' : scope.row.ReceivingType === 'channel' ? '渠道' : scope.row.ReceivingType === 'give' ? '后台赠送' : ''}}
99
           </template>
99
           </template>
100
         </el-table-column>
100
         </el-table-column>
101
         <el-table-column
101
         <el-table-column
186
         id: 'channel'
186
         id: 'channel'
187
       }, {
187
       }, {
188
         value: '系统',
188
         value: '系统',
189
-        id: 'system'
189
+        id: 'event'
190
+      }, {
191
+        value: '后台赠送',
192
+        id: 'give'
190
       }],
193
       }],
191
       statusList: [{
194
       statusList: [{
192
         value: '不限',
195
         value: '不限',
250
         this.total = res.total
253
         this.total = res.total
251
       })
254
       })
252
     },
255
     },
256
+    exportExcel () {
257
+      window.location.href = `${this.toolClass.ReplaceOrg(this.$api.statistics.cardCouponUsedListExcel.url)}?token=${localStorage.getItem('JWT')}`
258
+    },
253
   }
259
   }
254
 }
260
 }
255
 </script>
261
 </script>

+ 4
- 1
src/pages/system/dataStatistics/courseOrderList/index.vue View File

53
           type="primary" @click="search">搜索</el-button>
53
           type="primary" @click="search">搜索</el-button>
54
         <el-button
54
         <el-button
55
           size="mini"
55
           size="mini"
56
-          type="success" @click="search">导出Excel</el-button>
56
+          type="success" @click="exportExcel">导出Excel</el-button>
57
       </div>
57
       </div>
58
       <div class="moreFilter"></div>
58
       <div class="moreFilter"></div>
59
     </div>
59
     </div>
198
         this.total = res.total
198
         this.total = res.total
199
       })
199
       })
200
     },
200
     },
201
+    exportExcel () {
202
+      window.location.href = `${this.toolClass.ReplaceOrg(this.$api.statistics.courseOrderExcel.url)}?token=${localStorage.getItem('JWT')}`
203
+    },
201
   }
204
   }
202
 }
205
 }
203
 </script>
206
 </script>

+ 4
- 1
src/pages/system/dataStatistics/courseStatisticsList/index.vue View File

37
           type="primary" @click="search">搜索</el-button>
37
           type="primary" @click="search">搜索</el-button>
38
         <el-button
38
         <el-button
39
           size="mini"
39
           size="mini"
40
-          type="success" @click="search">导出Excel</el-button>
40
+          type="success" @click="exportExcel">导出Excel</el-button>
41
       </div>
41
       </div>
42
       <div class="moreFilter"></div>
42
       <div class="moreFilter"></div>
43
     </div>
43
     </div>
172
         this.total = res.total
172
         this.total = res.total
173
       })
173
       })
174
     },
174
     },
175
+    exportExcel () {
176
+      window.location.href = `${this.toolClass.ReplaceOrg(this.$api.statistics.courseListExcel.url)}?token=${localStorage.getItem('JWT')}`
177
+    },
175
   }
178
   }
176
 }
179
 }
177
 </script>
180
 </script>

+ 5
- 2
src/pages/system/dataStatistics/courseVerifyList/index.vue View File

46
           type="primary" @click="search">搜索</el-button>
46
           type="primary" @click="search">搜索</el-button>
47
         <el-button
47
         <el-button
48
           size="mini"
48
           size="mini"
49
-          type="success" @click="search">导出Excel</el-button>
49
+          type="success" @click="exportExcel">导出Excel</el-button>
50
       </div>
50
       </div>
51
       <div class="moreFilter"></div>
51
       <div class="moreFilter"></div>
52
     </div>
52
     </div>
192
     },
192
     },
193
     getList () {
193
     getList () {
194
       this.getCourseVerifyList(this.postData).then((res) => {
194
       this.getCourseVerifyList(this.postData).then((res) => {
195
-        console.log(JSON.stringify(res))
195
+        // console.log(JSON.stringify(res))
196
         this.postData.page = res.page
196
         this.postData.page = res.page
197
         this.total = res.total
197
         this.total = res.total
198
       })
198
       })
199
     },
199
     },
200
+    exportExcel () {
201
+      window.location.href = `${this.toolClass.ReplaceOrg(this.$api.statistics.courseVerifyListExcel.url)}?token=${localStorage.getItem('JWT')}`
202
+    },
200
   }
203
   }
201
 }
204
 }
202
 </script>
205
 </script>

+ 4
- 1
src/pages/system/dataStatistics/goodsOrderList/index.vue View File

56
           type="primary" @click="search">搜索</el-button>
56
           type="primary" @click="search">搜索</el-button>
57
         <el-button
57
         <el-button
58
           size="mini"
58
           size="mini"
59
-          type="success" @click="search">导出Excel</el-button>
59
+          type="success" @click="exportExcel">导出Excel</el-button>
60
       </div>
60
       </div>
61
       <div class="moreFilter"></div>
61
       <div class="moreFilter"></div>
62
     </div>
62
     </div>
214
         this.total = res.total
214
         this.total = res.total
215
       })
215
       })
216
     },
216
     },
217
+    exportExcel () {
218
+      window.location.href = `${this.toolClass.ReplaceOrg(this.$api.statistics.goodsOrderExcel.url)}?token=${localStorage.getItem('JWT')}`
219
+    },
217
   }
220
   }
218
 }
221
 }
219
 </script>
222
 </script>

+ 4
- 1
src/pages/system/dataStatistics/goodsStatisticsList/index.vue View File

37
           type="primary" @click="search">搜索</el-button>
37
           type="primary" @click="search">搜索</el-button>
38
         <el-button
38
         <el-button
39
           size="mini"
39
           size="mini"
40
-          type="success" @click="search">导出Excel</el-button>
40
+          type="success" @click="exportExcel">导出Excel</el-button>
41
       </div>
41
       </div>
42
       <div class="moreFilter"></div>
42
       <div class="moreFilter"></div>
43
     </div>
43
     </div>
160
         this.total = res.total
160
         this.total = res.total
161
       })
161
       })
162
     },
162
     },
163
+    exportExcel () {
164
+      window.location.href = `${this.toolClass.ReplaceOrg(this.$api.statistics.goodsExcel.url)}?token=${localStorage.getItem('JWT')}`
165
+    },
163
   }
166
   }
164
 }
167
 }
165
 </script>
168
 </script>

+ 12
- 0
src/store/sta/sta.js View File

118
         }).catch(reject)
118
         }).catch(reject)
119
       })
119
       })
120
     },
120
     },
121
+    getCardCouponListExcel ({ commit }, payload) {
122
+      return new Promise((resolve, reject) => {
123
+        ajax(api.statistics.cardCouponListExcel.url, {
124
+          method: api.statistics.cardCouponListExcel.method,
125
+          queryData: {
126
+            ...payload,
127
+          }
128
+        }).then(res => {
129
+          resolve(res)
130
+        }).catch(reject)
131
+      })
132
+    },
121
     getCardCouponUsedList ({ commit }, payload) {
133
     getCardCouponUsedList ({ commit }, payload) {
122
       return new Promise((resolve, reject) => {
134
       return new Promise((resolve, reject) => {
123
         ajax(api.statistics.cardCouponUsedList.url, {
135
         ajax(api.statistics.cardCouponUsedList.url, {

+ 28
- 0
src/util/api.js View File

695
       method: 'get',
695
       method: 'get',
696
       url: `${baseUrl}${common}/statistics/goods`
696
       url: `${baseUrl}${common}/statistics/goods`
697
     },
697
     },
698
+    goodsExcel: {
699
+      method: 'get',
700
+      url: `${baseUrl}${common}/statistics/goods/excel`
701
+    },
698
     goodsOrder: {
702
     goodsOrder: {
699
       method: 'get',
703
       method: 'get',
700
       url: `${baseUrl}${common}/statistics/goodsorders`
704
       url: `${baseUrl}${common}/statistics/goodsorders`
701
     },
705
     },
706
+    goodsOrderExcel: {
707
+      method: 'get',
708
+      url: `${baseUrl}${common}/statistics/goodsorders/excel`
709
+    },
702
     courseOrder: {
710
     courseOrder: {
703
       method: 'get',
711
       method: 'get',
704
       url: `${baseUrl}${common}/statistics/courseorders`
712
       url: `${baseUrl}${common}/statistics/courseorders`
705
     },
713
     },
714
+    courseOrderExcel: {
715
+      method: 'get',
716
+      url: `${baseUrl}${common}/statistics/courseorders/excel`
717
+    },
706
     courseList: {
718
     courseList: {
707
       method: 'get',
719
       method: 'get',
708
       url: `${baseUrl}${common}/statistics/courses`
720
       url: `${baseUrl}${common}/statistics/courses`
709
     },
721
     },
722
+    courseListExcel: {
723
+      method: 'get',
724
+      url: `${baseUrl}${common}/statistics/courses/excel`
725
+    },
710
     cardCouponList: {
726
     cardCouponList: {
711
       method: 'get',
727
       method: 'get',
712
       url: `${baseUrl}${common}/statistics/cardcoupon`
728
       url: `${baseUrl}${common}/statistics/cardcoupon`
713
     },
729
     },
730
+    cardCouponListExcel: {
731
+      method: 'get',
732
+      url: `${baseUrl}${common}/statistics/cardcoupon/excel`
733
+    },
714
     cardCouponUsedList: {
734
     cardCouponUsedList: {
715
       method: 'get',
735
       method: 'get',
716
       url: `${baseUrl}${common}/statistics/cardcouponused`
736
       url: `${baseUrl}${common}/statistics/cardcouponused`
717
     },
737
     },
738
+    cardCouponUsedListExcel: {
739
+      method: 'get',
740
+      url: `${baseUrl}${common}/statistics/cardcouponused/excel`
741
+    },
718
     courseVerifyList: {
742
     courseVerifyList: {
719
       method: 'get',
743
       method: 'get',
720
       url: `${baseUrl}${common}/statistics/cardcouponverify`
744
       url: `${baseUrl}${common}/statistics/cardcouponverify`
721
     },
745
     },
746
+    courseVerifyListExcel: {
747
+      method: 'get',
748
+      url: `${baseUrl}${common}/statistics/cardcouponverify/excel`
749
+    },
722
   }
750
   }
723
 }
751
 }
724
 export default $api
752
 export default $api