diff --git a/src/api/cardManage/cardManage.js b/src/api/cardManage/cardManage.js
index 9fe2d48..ab88106 100644
--- a/src/api/cardManage/cardManage.js
+++ b/src/api/cardManage/cardManage.js
@@ -14,4 +14,43 @@ export default {
})
},
+ // 导出提货卡报表
+ exportExcel: function(data) {
+ return request({
+ url: '/lpkgiftcard/cardStatisticsListExport',
+ method: 'post',
+ responseType: 'blob', // 表明返回服务器返回的数据类型
+ data: data,
+ headers: {
+ 'Content-Type': 'application/json'
+ }
+ });
+ },
+
+ // 查询企业卡分页列表
+ empCardStatisticsList: function(params) {
+ return request({
+ url: '/empcard/empCardStatisticsList',
+ method: 'post',
+ data: params,
+ headers: {
+ 'Content-Type': 'application/json'
+ }
+ })
+ },
+
+ // 导出提货卡报表
+ empCardStatisticsListExport: function(data) {
+ return request({
+ url: '/empcard/empCardStatisticsListExport',
+ method: 'post',
+ responseType: 'blob', // 表明返回服务器返回的数据类型
+ data: data,
+ headers: {
+ 'Content-Type': 'application/json'
+ }
+ });
+ },
+
+
}
\ No newline at end of file
diff --git a/src/layout/components/Sidebar/index.vue b/src/layout/components/Sidebar/index.vue
index 181aaff..8a8bc08 100644
--- a/src/layout/components/Sidebar/index.vue
+++ b/src/layout/components/Sidebar/index.vue
@@ -112,40 +112,40 @@
// },
]
},
- // {
- // alwaysShow: true,
- // component: "carManage",
- // meta: {
- // icon: "el-icon-menu",
- // title: "营销卡管理",
- // },
- // name: "/cardManage",
- // path: "/cardManage",
- // children: [
+ {
+ alwaysShow: true,
+ component: "carManage",
+ meta: {
+ icon: "el-icon-menu",
+ title: "营销卡管理",
+ },
+ name: "/cardManage",
+ path: "/cardManage",
+ children: [
- // {
- // alwaysShow: true,
- // component: "person",
- // meta: {
- // icon: "el-icon-help",
- // title: "提货卡统计",
- // },
- // name: "/cardManage/person",
- // path: "/cardManage/person",
- // },
+ {
+ alwaysShow: true,
+ component: "person",
+ meta: {
+ icon: "el-icon-help",
+ title: "提货卡统计",
+ },
+ name: "/cardManage/person",
+ path: "/cardManage/person",
+ },
- // {
- // alwaysShow: true,
- // component: "enterprise",
- // meta: {
- // icon: "el-icon-help",
- // title: "企业卡统计",
- // },
- // name: "/cardManage/enterprise",
- // path: "/cardManage/enterprise",
- // },
- // ]
- // },
+ {
+ alwaysShow: true,
+ component: "enterprise",
+ meta: {
+ icon: "el-icon-help",
+ title: "企业卡统计",
+ },
+ name: "/cardManage/enterprise",
+ path: "/cardManage/enterprise",
+ },
+ ]
+ },
{
alwaysShow: true,
component: "pickupPoint",
diff --git a/src/views/cardManage/enterprise.vue b/src/views/cardManage/enterprise.vue
index 6674f62..1631f57 100644
--- a/src/views/cardManage/enterprise.vue
+++ b/src/views/cardManage/enterprise.vue
@@ -41,7 +41,7 @@
@@ -56,8 +56,8 @@
-->
-
+
@@ -189,7 +189,7 @@
},
loadList() {
this.tableLoading = true
- req.customerListPage(this.queryParams).then((resp) => {
+ req.empCardStatisticsList(this.queryParams).then((resp) => {
this.tableLoading = false
if (resp.success) {
const data = resp.data
@@ -274,31 +274,31 @@
},
// 导出
doBuild() {
- // const loading = this.$loading({
- // lock: true,
- // text: 'Loading',
- // spinner: 'el-icon-loading',
- // background: 'rgba(0, 0, 0, 0.7)'
- // })
+ const loading = this.$loading({
+ lock: true,
+ text: 'Loading',
+ spinner: 'el-icon-loading',
+ background: 'rgba(0, 0, 0, 0.7)'
+ })
- // req.bankOrderExportExcel(this.page.params).then((resp) => {
- // loading.close()
- // const blob = new Blob([resp], {
- // type: 'application/vnd.ms-excel'
- // })
- // const fileName = '支行配货明细_' + this.page.params.startDate + '.xls'
- // const elink = document.createElement('a')
- // elink.download = fileName
- // elink.style.display = 'nonde'
- // elink.href = URL.createObjectURL(blob)
- // document.body.appendChild(elink)
- // elink.click()
- // URL.revokeObjectURL(elink.href)
- // document.body.removeChild(elink)
- // }).catch(() => {
- // loading.close()
- // })
+ req.empCardStatisticsListExport(this.queryParams.params).then((resp) => {
+ loading.close()
+ const blob = new Blob([resp], {
+ type: 'application/vnd.ms-excel'
+ })
+ const fileName = '企业卡明细.xls'
+ const elink = document.createElement('a')
+ elink.download = fileName
+ elink.style.display = 'nonde'
+ elink.href = URL.createObjectURL(blob)
+ document.body.appendChild(elink)
+ elink.click()
+ URL.revokeObjectURL(elink.href)
+ document.body.removeChild(elink)
+ }).catch(() => {
+ loading.close()
+ })
},
}
diff --git a/src/views/cardManage/person.vue b/src/views/cardManage/person.vue
index ae84aa3..a9d4770 100644
--- a/src/views/cardManage/person.vue
+++ b/src/views/cardManage/person.vue
@@ -56,8 +56,8 @@
-->
-
+
@@ -274,31 +274,31 @@
},
// 导出
doBuild() {
- // const loading = this.$loading({
- // lock: true,
- // text: 'Loading',
- // spinner: 'el-icon-loading',
- // background: 'rgba(0, 0, 0, 0.7)'
- // })
+ const loading = this.$loading({
+ lock: true,
+ text: 'Loading',
+ spinner: 'el-icon-loading',
+ background: 'rgba(0, 0, 0, 0.7)'
+ })
- // req.bankOrderExportExcel(this.page.params).then((resp) => {
- // loading.close()
- // const blob = new Blob([resp], {
- // type: 'application/vnd.ms-excel'
- // })
- // const fileName = '支行配货明细_' + this.page.params.startDate + '.xls'
- // const elink = document.createElement('a')
- // elink.download = fileName
- // elink.style.display = 'nonde'
- // elink.href = URL.createObjectURL(blob)
- // document.body.appendChild(elink)
- // elink.click()
- // URL.revokeObjectURL(elink.href)
- // document.body.removeChild(elink)
- // }).catch(() => {
- // loading.close()
- // })
+ req.exportExcel(this.queryParams.params).then((resp) => {
+ loading.close()
+ const blob = new Blob([resp], {
+ type: 'application/vnd.ms-excel'
+ })
+ const fileName = '提货卡明细.xls'
+ const elink = document.createElement('a')
+ elink.download = fileName
+ elink.style.display = 'nonde'
+ elink.href = URL.createObjectURL(blob)
+ document.body.appendChild(elink)
+ elink.click()
+ URL.revokeObjectURL(elink.href)
+ document.body.removeChild(elink)
+ }).catch(() => {
+ loading.close()
+ })
},
}