修改UAT提出的问题

This commit is contained in:
范强强
2023-05-09 11:13:10 +08:00
parent ed770c7e58
commit e972566364
9 changed files with 377 additions and 267 deletions
@@ -2,14 +2,24 @@
<div>
<div class="box-content">
<div class="box-content-left">
<div class="total-text">
<span>{{$t('totalTable')+' : '+mainLeftNum}}</span>
</div>
<div id="main-left"></div>
</div>
<div class="box-content-right">
<div class="total-text">
<span>{{$t('totalTable')+' : '+mainRightNum}}</span>
</div>
<div id="main-right"></div>
</div>
</div>
<div class="box-content">
<div class="box-content-bottom">
<div class="total-text-text" :class="{'total-text-text-cntop':long == 'zh-cn' ? true:false,
'total-text-text-entop':long == 'zh-cn' ? false:true}">
<span>{{$t('totalTable')+' : '+mainBottomNum}}</span>
</div>
<div class="box-content-text">
<div class="box-content-text-text" @click="boxContentClick(0)">
{{$t('whole')}}
@@ -50,8 +60,12 @@
url: {
getProjectDetailsStatistics: '/project/projectLibraryBase/getProjectDetailsStatistics'
},
certificationProgressMap:{},
num:'0',
certificationProgressMap: {},
num: '0',
mainLeftNum: 0,
mainRightNum: 0,
mainBottomNum: 0,
long: localStorage.getItem('language') || 'zh-cn'
}
},
mounted() {
@@ -92,6 +106,7 @@
dataEcharts(dataSource) {
let data = []
let color = []
this.mainLeftNum = 0
if (dataSource && dataSource.length > 0) {
this.dataSource = [{}]
dataSource.forEach(res => {
@@ -100,7 +115,7 @@
value: res.taskAffirmStatusCount,
name: this.$t('notLaunch'),
color: '#00B3BE',
status:res.taskAffirmStatus
status: res.taskAffirmStatus
})
color.push('#00B3BE')
} else if (res.taskAffirmStatus == 'List to confirm') {
@@ -108,7 +123,7 @@
value: res.taskAffirmStatusCount,
name: this.$t('listToConfirm'),
color: '#FDA71C',
status:res.taskAffirmStatus
status: res.taskAffirmStatus
})
color.push('#FDA71C')
} else if (res.taskAffirmStatus == 'Accepted') {
@@ -116,7 +131,7 @@
value: res.taskAffirmStatusCount,
name: this.$t('accept'),
color: '#26BC4B',
status:res.taskAffirmStatus
status: res.taskAffirmStatus
})
color.push('#26BC4B')
} else if (res.taskAffirmStatus == 'Rejected') {
@@ -124,17 +139,19 @@
value: res.taskAffirmStatusCount,
name: this.$t('refuse'),
color: '#E83030',
status:res.taskAffirmStatus
status: res.taskAffirmStatus
})
color.push('#E83030')
}
this.mainLeftNum += res.taskAffirmStatusCount
})
}
this.getEcharts('main-left', this.$t('certificationTaskConfirmation'), color, data)
},
mainRightEcharts(dataSource){
mainRightEcharts(dataSource) {
let data = []
let color = []
this.mainRightNum = 0
if (dataSource && dataSource.length > 0) {
this.dataSource = [{}]
dataSource.forEach(res => {
@@ -143,7 +160,7 @@
value: res.taskAffirmStatusCount,
name: this.$t('notLaunch'),
color: '#00B3BE',
status:res.taskAffirmStatus
status: res.taskAffirmStatus
})
color.push('#00B3BE')
} else if (res.taskAffirmStatus == 'List to confirm') {
@@ -151,7 +168,7 @@
value: res.taskAffirmStatusCount,
name: this.$t('listToConfirm'),
color: '#FDA71C',
status:res.taskAffirmStatus
status: res.taskAffirmStatus
})
color.push('#FDA71C')
} else if (res.taskAffirmStatus == 'Review and pass') {
@@ -159,7 +176,7 @@
value: res.taskAffirmStatusCount,
name: this.$t('reviewAndPass'),
color: '#26BC4B',
status:res.taskAffirmStatus
status: res.taskAffirmStatus
})
color.push('#26BC4B')
} else if (res.taskAffirmStatus == 'Review and return') {
@@ -167,17 +184,19 @@
value: res.taskAffirmStatusCount,
name: this.$t('reviewAndReturn'),
color: '#E83030',
status:res.taskAffirmStatus
status: res.taskAffirmStatus
})
color.push('#E83030')
}
this.mainRightNum += res.taskAffirmStatusCount
})
}
this.getEcharts('main-right', this.$t('preHomoFlow'), color, data)
},
mainBottomEcharts(dataSource){
mainBottomEcharts(dataSource) {
let data = []
let color = []
this.mainBottomNum = 0
if (dataSource && dataSource.length > 0) {
dataSource.forEach(res => {
if (res.certificationProgress == 'Not start') {
@@ -185,7 +204,7 @@
value: res.certificationProgressCount,
name: this.$t('Notatthe'),
color: '#00B3BE',
status:res.certificationProgress
status: res.certificationProgress
})
color.push('#00B3BE')
} else if (res.certificationProgress == 'In progress') {
@@ -193,7 +212,7 @@
value: res.certificationProgressCount,
name: this.$t('inProgress'),
color: '#FDA71C',
status:res.certificationProgress
status: res.certificationProgress
})
color.push('#FDA71C')
} else if (res.certificationProgress == 'Test passed') {
@@ -201,7 +220,7 @@
value: res.certificationProgressCount,
name: this.$t('experimentPassed'),
color: '#26BC4B',
status:res.certificationProgress
status: res.certificationProgress
})
color.push('#26BC4B')
} else if (res.certificationProgress == 'Test failed') {
@@ -209,34 +228,35 @@
value: res.certificationProgressCount,
name: this.$t('experimentFailed'),
color: '#E83030',
status:res.certificationProgress
status: res.certificationProgress
})
color.push('#E83030')
}else if (res.certificationProgress == 'Component report not submitted') {
} else if (res.certificationProgress == 'Component report not submitted') {
data.push({
value: res.certificationProgressCount,
name: this.$t('componentReportNotSubmitted'),
color: '#FDA71C',
status:res.certificationProgress
status: res.certificationProgress
})
color.push('#FDA71C')
}else if (res.certificationProgress == 'Component report submitted') {
} else if (res.certificationProgress == 'Component report submitted') {
data.push({
value: res.certificationProgressCount,
name: this.$t('componentReportSubmitted'),
color: '#6FD682',
status:res.certificationProgress
status: res.certificationProgress
})
color.push('#6FD682')
}else if (res.certificationProgress == 'Component report has been stored') {
} else if (res.certificationProgress == 'Component report has been stored') {
data.push({
value: res.certificationProgressCount,
name: this.$t('componentReportHasBeenStored'),
color: '#26BC4B',
status:res.certificationProgress
status: res.certificationProgress
})
color.push('#26BC4B')
}
this.mainBottomNum += res.certificationProgressCount
})
}
this.getEcharts('main-bottom', this.$t('CertificationProgress'), color, data)
@@ -249,14 +269,14 @@
},
tooltip: {
trigger: 'item',
textStyle : {
fontWeight : 'normal',
fontSize : 14,
color:'#040B29',
fontFamily:'BlueSkyNoto',
textStyle: {
fontWeight: 'normal',
fontSize: 14,
color: '#040B29',
fontFamily: 'BlueSkyNoto'
},
formatter: function (parms) {
let str = parms.marker+' '+parms.data.name+'&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;'+parms.data.value+' ('+parms.percent+'%)'
formatter: function(parms) {
let str = parms.marker + ' ' + parms.data.name + '&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;' + parms.data.value + ' (' + parms.percent + '%)'
return str
}
},
@@ -300,11 +320,11 @@
query.operatorType = 'queryPrehomoStatistics'
query.status = params.data.status
} else if (params.seriesName === this.$t('CertificationProgress')) {
if (this.num == '0'){
if (this.num == '0') {
query.operatorType = 'queryCertificationProgressStatisticsAll'
}else if(this.num == '1'){
} else if (this.num == '1') {
query.operatorType = 'queryCertificationProgressStatisticsCar'
}else if(this.num == '2'){
} else if (this.num == '2') {
query.operatorType = 'queryCertificationProgressStatisticsPart'
}
query.status = params.data.status
@@ -327,12 +347,12 @@
boxContentTextText[num].classList.add('box-content-text-color')
}
this.num = num
if (num == 0){
this.mainBottomEcharts( this.certificationProgressMap.allMapList || [])
}else if(num == 1){
this.mainBottomEcharts( this.certificationProgressMap.carMapList || [])
}else if(num == 2){
this.mainBottomEcharts( this.certificationProgressMap.partMapList || [])
if (num == 0) {
this.mainBottomEcharts(this.certificationProgressMap.allMapList || [])
} else if (num == 1) {
this.mainBottomEcharts(this.certificationProgressMap.carMapList || [])
} else if (num == 2) {
this.mainBottomEcharts(this.certificationProgressMap.partMapList || [])
}
}
}
@@ -350,6 +370,7 @@
.box-content-left {
width: calc(50% - 10px);
height: 346px;
position: relative;
border: 2px #eff1f3 solid;
border-radius: 6px;
margin-top: 4px;
@@ -365,6 +386,7 @@
.box-content-right {
width: calc(50% - 10px);
height: 346px;
position: relative;
border: 2px #eff1f3 solid;
border-radius: 6px;
margin-top: 4px;
@@ -384,6 +406,7 @@
position: relative;
border-radius: 6px;
margin-top: 20px;
overflow: hidden;
.box-content-text {
height: 30px;
@@ -429,4 +452,27 @@
}
}
.total-text {
position: absolute;
right: 28px;
top: 19px;
font-size: 18px;
font-weight: bold;
}
.total-text-text {
position: absolute;
right: 28px;
top: 21px;
font-size: 18px;
font-weight: bold;
}
.total-text-text-cntop {
right: 180px;
}
.total-text-text-entop {
right: 290px;
}
</style>