|
|
@@ -81,7 +81,7 @@
|
|
|
<el-tab-pane
|
|
|
label="游客性别统计"
|
|
|
name="gender">
|
|
|
- <Sex :table-data="statisticsInfo.genderStatistics"></Sex>
|
|
|
+ <Sex :table-data="statisticsInfo.sexStatistics"></Sex>
|
|
|
</el-tab-pane>
|
|
|
</el-tabs>
|
|
|
</el-card>
|
|
|
@@ -93,6 +93,7 @@ import Age from './Statistic/Age'
|
|
|
import Sex from './Statistic/Sex'
|
|
|
import AreaStatics from './Statistic/Area'
|
|
|
import { getVisitorStatistics } from '@/api/visitor'
|
|
|
+import moment from 'moment'
|
|
|
|
|
|
export default {
|
|
|
name: 'visitorStatistic',
|
|
|
@@ -104,12 +105,6 @@ export default {
|
|
|
data () {
|
|
|
return {
|
|
|
activeName: 'source',
|
|
|
- ExportForm: {
|
|
|
- // cancelTimeBegin: new Date(moment().format('YYYY-MM-DD') + ' 00:00:00'),
|
|
|
- // cancelTimeEnd: new Date(moment().format('YYYY-MM-DD') + ' 23:59:59'),
|
|
|
- // ticketTypeIdList: [], // 票种
|
|
|
- // otaSourceNameList: []
|
|
|
- },
|
|
|
form: {
|
|
|
statisticsTimeBegin: '',
|
|
|
statisticsTimeEnd: '',
|
|
|
@@ -128,31 +123,30 @@ export default {
|
|
|
},
|
|
|
methods: {
|
|
|
setTime () {
|
|
|
- if (this.ExportForm.cancelTimeBegin) {
|
|
|
- this.ExportForm.cancelTimeBegin = moment(this.ExportForm.cancelTimeBegin).format('YYYY-MM-DD HH:mm:ss')
|
|
|
+ if (this.form.statisticsTimeBegin) {
|
|
|
+ this.form.statisticsTimeBegin = moment(this.form.statisticsTimeBegin).format('YYYY-MM-DD HH:mm:ss')
|
|
|
} else {
|
|
|
- this.ExportForm.cancelTimeBegin = ''
|
|
|
+ this.form.statisticsTimeBegin = ''
|
|
|
}
|
|
|
|
|
|
- if (this.ExportForm.cancelTimeEnd) {
|
|
|
- this.ExportForm.cancelTimeEnd = moment(this.ExportForm.cancelTimeEnd).format('YYYY-MM-DD HH:mm:ss')
|
|
|
+ if (this.form.statisticsTimeEnd) {
|
|
|
+ this.form.statisticsTimeEnd = moment(this.form.statisticsTimeEnd).format('YYYY-MM-DD HH:mm:ss')
|
|
|
} else {
|
|
|
- this.ExportForm.cancelTimeEnd = ''
|
|
|
+ this.form.statisticsTimeEnd = ''
|
|
|
}
|
|
|
},
|
|
|
|
|
|
//导出
|
|
|
|
|
|
reportExport () {
|
|
|
- this.ExportForm.export = true
|
|
|
this.setTime()
|
|
|
|
|
|
- if (!this.ExportForm.ticketTypeIdList) {
|
|
|
- this.ExportForm.ticketTypeIdList = []
|
|
|
+ if (!this.form.ticketTypeIdList) {
|
|
|
+ this.form.ticketTypeIdList = []
|
|
|
}
|
|
|
|
|
|
- if (!this.ExportForm.otaSourceNameList) {
|
|
|
- this.ExportForm.otaSourceNameList = []
|
|
|
+ if (!this.form.otaSourceNameList) {
|
|
|
+ this.form.otaSourceNameList = []
|
|
|
}
|
|
|
this.$confirm(`是否要导出明细数据`, '确认提示', {
|
|
|
confirmButtonText: '是',
|