|
@@ -21,12 +21,14 @@ export default {
|
|
|
timeLeft: null
|
|
|
},
|
|
|
dataFilterProductSelect: '',
|
|
|
+ dataFilterSelectLoading: false,
|
|
|
chartData: {
|
|
|
date: [],
|
|
|
assignedLicensesYData: [],
|
|
|
activatedLicenseYData: []
|
|
|
},
|
|
|
- chartSelectValue: '',
|
|
|
+ chartSelectValue: '',
|
|
|
+ chartSelectLoading: false,
|
|
|
teamData: {
|
|
|
totalTeam: null,
|
|
|
totalMember: null,
|
|
@@ -39,13 +41,14 @@ export default {
|
|
|
},
|
|
|
teamList: [],
|
|
|
teamSelect: '',
|
|
|
- teamFilterProductSelect: ''
|
|
|
+ teamFilterProductSelect: '',
|
|
|
+ teamSelectLoading: false
|
|
|
}
|
|
|
},
|
|
|
created () {
|
|
|
this.getOverview()
|
|
|
this.getOverviewProduct()
|
|
|
- this.getChartStatistics(1)
|
|
|
+ this.getChartStatistics(2)
|
|
|
this.getTeamData()
|
|
|
this.getTeamMemberData()
|
|
|
this.getProductList()
|
|
@@ -68,9 +71,14 @@ export default {
|
|
|
},
|
|
|
// 获取全局预览数据,区分产品
|
|
|
getOverviewProduct () {
|
|
|
+ if (this.dataFilterSelectLoading) return
|
|
|
+ this.dataFilterSelectLoading = true
|
|
|
get('http://81.68.234.235:8032/pdf-tech/vppDashboard/getOverviewProduct', {
|
|
|
codeList: this.dataFilterProductSelect
|
|
|
}).then((res) => {
|
|
|
+ setTimeout(() => {
|
|
|
+ this.dataFilterSelectLoading = false
|
|
|
+ }, 1000)
|
|
|
Object.keys(this.overviewProduct).forEach(key => (this.overviewProduct[key] = ''))
|
|
|
if (res.data.code === 200) {
|
|
|
this.overviewProduct.totalLicenses = res.data.result.totalLicenses
|
|
@@ -84,12 +92,17 @@ export default {
|
|
|
},
|
|
|
// 获取图表数据
|
|
|
getChartStatistics (type) {
|
|
|
+ if (this.chartSelectLoading) return
|
|
|
+ this.chartSelectLoading = true
|
|
|
if (this.chartSelectValue !== '') {
|
|
|
type = this.chartSelectValue
|
|
|
} else {
|
|
|
- type = 1
|
|
|
+ type = 2
|
|
|
}
|
|
|
get('http://81.68.234.235:8032/pdf-tech/vppDashboard/getChartStatistics/' + type).then((res) => {
|
|
|
+ setTimeout(() => {
|
|
|
+ this.chartSelectLoading = false
|
|
|
+ }, 1000)
|
|
|
if (res.data.code === 200) {
|
|
|
this.chartData.date = []
|
|
|
this.chartData.assignedLicensesYData = []
|
|
@@ -117,10 +130,15 @@ export default {
|
|
|
},
|
|
|
// 获取团队成员数据
|
|
|
getTeamMemberData () {
|
|
|
+ if (this.teamSelectLoading) return
|
|
|
+ this.teamSelectLoading = true
|
|
|
get('http://81.68.234.235:8032/pdf-tech/vppDashboard/getTeamMemberData', {
|
|
|
teamId: this.teamSelect,
|
|
|
codeList: this.teamFilterProductSelect
|
|
|
}).then((res) => {
|
|
|
+ setTimeout(() => {
|
|
|
+ this.teamSelectLoading = false
|
|
|
+ }, 1000)
|
|
|
Object.keys(this.teamMemberData).forEach(key => (this.teamMemberData[key] = ''))
|
|
|
if (res.data.code === 200) {
|
|
|
this.teamMemberData.teamMember = res.data.result.teamMember
|