ota统计对接数据

This commit is contained in:
zyx.net
2023-08-22 10:58:13 +08:00
parent 32e08345bc
commit 17772c37b1
@@ -8,16 +8,16 @@
<div class="title-text" :title="$t('softwareversion')"> <div class="title-text" :title="$t('softwareversion')">
<span>{{ $t('softwareversion') }}</span> <span>{{ $t('softwareversion') }}</span>
</div> </div>
<a-select v-model="queryParam.ctype" <a-select v-model="queryParam.plannedBpLaunchBatch"
class="box-input" class="box-input"
@change="getonChange" @change="getonChange"
showSearch showSearch
optionFilterProp="label" optionFilterProp="label"
:autoClearSearchValue="false" :autoClearSearchValue="false"
:getPopupContainer="triggerNode => triggerNode.parentNode" :popper-append-to-body="false"> :getPopupContainer="triggerNode => triggerNode.parentNode" :popper-append-to-body="false">
<a-select-option v-for="d in options" :key="d.value" :label='d.label' :value="d.value"> <a-select-option v-for="d in options" :key="d.plannedBpLaunchBatch" :label='d.plannedBpLaunchBatch' :value="d.plannedBpLaunchBatch">
<span style="display: inline-block;width: 80%" :title=" d.label"> <span style="display: inline-block;width: 80%" :title=" d.plannedBpLaunchBatch">
{{ d.label }} {{ d.plannedBpLaunchBatch }}
</span> </span>
</a-select-option> </a-select-option>
</a-select> </a-select>
@@ -44,14 +44,14 @@
<td width="150px" height="50px" align="center">{{$t('Pendingapproval')}}</td> <td width="150px" height="50px" align="center">{{$t('Pendingapproval')}}</td>
<td width="150px" height="50px" align="center">{{$t('lock')}}</td> <td width="150px" height="50px" align="center">{{$t('lock')}}</td>
<td width="150px" height="50px" align="center">{{$t('sendBack')}}</td> <td width="150px" height="50px" align="center">{{$t('sendBack')}}</td>
<td width="150px" height="50px" align="center">{{$t('notInvolved')}}</td> <!-- <td width="150px" height="50px" align="center">{{$t('notInvolved')}}</td>-->
</tr> </tr>
<tr> <tr>
<td height="80px" align="center"><span style='color: #5087EC'>{{matchForm.a}}</span></td> <td height="80px" align="center"><span style='color: #5087EC'>{{matchForm.to_be_matched}}</span></td>
<td height="80px" align="center"><span style='color: #68BBC4'>{{matchForm.a}}</span></td> <td height="80px" align="center"><span style='color: #68BBC4'>{{matchForm.to_be_approved}}</span></td>
<td height="80px" align="center"><span style='color: #58A55C'>{{matchForm.a}}</span></td> <td height="80px" align="center"><span style='color: #58A55C'>{{matchForm.locked}}</span></td>
<td height="80px" align="center"><span style='color: #F2BD42'>{{matchForm.a}}</span></td> <td height="80px" align="center"><span style='color: #F2BD42'>{{matchForm.rejected}}</span></td>
<td height="80px" align="center"><span style='color: #BBBBBB'>{{matchForm.a}}</span></td> <!--/* <td height="80px" align="center"><span style='color: #BBBBBB'>{{matchForm.a}}</span></td>*/-->
</tr> </tr>
</table> </table>
</div> </div>
@@ -72,13 +72,13 @@
<td width="190px" height="50px" align="center">{{$t('componentReportHasBeenStored')}}</td> <td width="190px" height="50px" align="center">{{$t('componentReportHasBeenStored')}}</td>
</tr> </tr>
<tr> <tr>
<td height="80px" align="center"><span style='color: #BBBBBB'>{{authenticationForm.a}}</span></td> <td height="80px" align="center"><span style='color: #BBBBBB'>{{authenticationForm.Not_start}}</span></td>
<td height="80px" align="center"><span style='color: #68BBC4'>{{authenticationForm.a}}</span></td> <td height="80px" align="center"><span style='color: #F2BD42'>{{authenticationForm.In_progress}}</span></td>
<td height="80px" align="center"><span style='color: #68BBC4'>{{authenticationForm.a}}</span></td> <td height="80px" align="center"><span style='color: #68BBC4'>{{authenticationForm.Test_passed}}</span></td>
<td height="80px" align="center"><span style='color: #D95040'>{{authenticationForm.a}}</span></td> <td height="80px" align="center"><span style='color: #D95040'>{{authenticationForm.Test_failed}}</span></td>
<td height="80px" align="center"><span style='color: #BBBBBB'>{{authenticationForm.a}}</span></td> <td height="80px" align="center"><span style='color: #BBBBBB'>{{authenticationForm.Component_report_not_submitted}}</span></td>
<td height="80px" align="center"><span style='color: #68BBC4'>{{authenticationForm.a}}</span></td> <td height="80px" align="center"><span style='color: #68BBC4'>{{authenticationForm.Component_report_submitted}}</span></td>
<td height="80px" align="center"><span style='color: #58A55C'>{{authenticationForm.a}}</span></td> <td height="80px" align="center"><span style='color: #58A55C'>{{authenticationForm.Component_report_has_been_stored}}</span></td>
</tr> </tr>
</table> </table>
</div> </div>
@@ -109,8 +109,7 @@
data() { data() {
return { return {
queryParam: { queryParam: {
value: 1, plannedBpLaunchBatch: ''
ctype: ''
}, },
options: [], options: [],
collecting: [], collecting: [],
@@ -142,7 +141,7 @@
}, },
mounted() { mounted() {
this.getoptions() this.getoptions()
this.getData() // this.getData()
}, },
methods: { methods: {
@@ -150,19 +149,17 @@
}, },
getData() { getData() {
let id = '' let query = {
if (this.idList && this.idList.length > 0) { ...this.queryParam,
id = this.idList.join(',') projectId:this.$route.query.id
} else {
id = this.$route.query.id
} }
getAction(this.url.getProjectDetailsStatistics, { id: id }).then((res) => { getAction('ota/otaManageApplyEO/getStatisticalStatus', query).then((res) => {
if (res.success) { if (res.success) {
if (res.result) { if (res.result) {
let mainTopDataSource = res.result.taskToConfirmMap ? res.result.taskToConfirmMap.taskToConfirmMapList : [] let mainTopDataSource = res.result.matchStatusMapList ? res.result.matchStatusMapList : []
let mainEndDataSource = res.result.designComplianceMap ? res.result.designComplianceMap.designComplianceMapList : [] let mainEndDataSource = res.result.attestationScheduleMapList ? res.result.attestationScheduleMapList : []
this.matchForm = res.result.matchForm this.matchForm = res.result.matchStatusMap
this.authenticationForm = res.result.authenticationForm this.authenticationForm = res.result.attestationScheduleMap
this.mainTopEcharts(mainTopDataSource) this.mainTopEcharts(mainTopDataSource)
this.mainEndEcharts(mainEndDataSource) this.mainEndEcharts(mainEndDataSource)
// this.mainRightEcharts(mainRightDataSource) // this.mainRightEcharts(mainRightDataSource)
@@ -177,7 +174,8 @@
getAction('ota/otaManageApplyEO/getVdrListByProject', { projectId: id }).then((res) => { getAction('ota/otaManageApplyEO/getVdrListByProject', { projectId: id }).then((res) => {
if (res.success) { if (res.success) {
this.options = res.result this.options = res.result
this.queryParam.ctype = this.options[0].value this.queryParam.plannedBpLaunchBatch = this.options[0].plannedBpLaunchBatch
this.getData()
// this.getData(this.queryParam.ctype) // this.getData(this.queryParam.ctype)
} else { } else {
} }
@@ -268,40 +266,40 @@
if (dataSource && dataSource.length > 0) { if (dataSource && dataSource.length > 0) {
this.dataSource = [{}] this.dataSource = [{}]
dataSource.forEach(res => { dataSource.forEach(res => {
if (res.taskAffirmStatus == 'Not started') { if (res.matchStatus == 'to_be_matched') {
data.push({ data.push({
value: res.taskAffirmStatusCount, value: res.matchStatusCount,
name: this.$t('notLaunch'), name: this.$t('tobematched'),
color: '#00B3BE', color: '#5087EC',
status: res.taskAffirmStatus status: res.matchStatus
}) })
color.push('#00B3BE') color.push('#5087EC')
} else if (res.taskAffirmStatus == 'List to confirm') { } else if (res.matchStatus == 'to_be_approved') {
data.push({ data.push({
value: res.taskAffirmStatusCount, value: res.matchStatusCount,
name: this.$t('listToConfirm'), name: this.$t('Pendingapproval'),
color: '#FDA71C', color: '#68BBC4',
status: res.taskAffirmStatus status: res.matchStatus
}) })
color.push('#FDA71C') color.push('#68BBC4')
} else if (res.taskAffirmStatus == 'Accepted') { } else if (res.matchStatus == 'locked') {
data.push({ data.push({
value: res.taskAffirmStatusCount, value: res.matchStatusCount,
name: this.$t('accept'), name: this.$t('lock'),
color: '#26BC4B', color: '#58A55C',
status: res.taskAffirmStatus status: res.matchStatus
}) })
color.push('#26BC4B') color.push('#58A55C')
} else if (res.taskAffirmStatus == 'Rejected') { } else if (res.matchStatus == 'rejected') {
data.push({ data.push({
value: res.taskAffirmStatusCount, value: res.matchStatusCount,
name: this.$t('refuse'), name: this.$t('sendBack'),
color: '#E83030', color: '#F2BD42',
status: res.taskAffirmStatus status: res.matchStatus
}) })
color.push('#E83030') color.push('#F2BD42')
} }
this.mainTopNum += res.taskAffirmStatusCount this.mainTopNum += res.matchStatusCount
}) })
} }
this.getEcharts('main-top-Collect', this.$t('Matchingstatestatistics'), color, data) this.getEcharts('main-top-Collect', this.$t('Matchingstatestatistics'), color, data)
@@ -313,41 +311,66 @@
this.mainTopNum = 0 this.mainTopNum = 0
if (dataSource && dataSource.length > 0) { if (dataSource && dataSource.length > 0) {
this.dataSource = [{}] this.dataSource = [{}]
console.log(dataSource)
dataSource.forEach(res => { dataSource.forEach(res => {
if (res.designFlowTaskStatus == 'Not started') { if (res.attestationSchedule == 'Not start') {
data.push({ data.push({
value: res.designFlowTaskStatusCount, value: res.attestationScheduleCount,
name: this.$t('notLaunch'), name: this.$t('Notatthe'),
color: '#00B3BE', color: '#BBBBBB',
status: res.designFlowTaskStatus status: res.attestationSchedule
}) })
color.push('#00B3BE') color.push('#BBBBBB')
} else if (res.designFlowTaskStatus == 'List to confirm') { } else if (res.attestationSchedule == 'In progress') {
data.push({ data.push({
value: res.designFlowTaskStatusCount, value: res.attestationScheduleCount,
name: this.$t('listToConfirm'), name: this.$t('inProgress'),
color: '#FDA71C', color: '#F2BD42',
status: res.designFlowTaskStatus status: res.attestationSchedule
}) })
color.push('#FDA71C') color.push('#F2BD42')
} else if (res.designFlowTaskStatus == 'Accepted') { } else if (res.attestationSchedule == 'Test failed') {
data.push({ data.push({
value: res.designFlowTaskStatusCount, value: res.attestationScheduleCount,
name: this.$t('accept'), name: this.$t('experimentFailed'),
color: '#26BC4B', color: '#D95040',
status: res.designFlowTaskStatus status: res.attestationSchedule
}) })
color.push('#26BC4B') color.push('#D95040')
} else if (res.designFlowTaskStatus == 'Rejected') { } else if (res.attestationSchedule == 'Component report not submitted') {
data.push({ data.push({
value: res.designFlowTaskStatusCount, value: res.attestationScheduleCount,
name: this.$t('refuse'), name: this.$t('componentReportNotSubmitted'),
color: '#E83030', color: '#BBBBBB',
status: res.designFlowTaskStatus status: res.attestationSchedule
}) })
color.push('#E83030') color.push('#BBBBBB')
} else if (res.attestationSchedule == 'Component report submitted') {
data.push({
value: res.attestationScheduleCount,
name: this.$t('componentReportSubmitted'),
color: '#68BBC4',
status: res.attestationSchedule
})
color.push('#68BBC4')
} else if (res.attestationSchedule == 'Component report has been stored') {
data.push({
value: res.attestationScheduleCount,
name: this.$t('componentReportHasBeenStored'),
color: '#58A55C',
status: res.attestationSchedule
})
color.push('#58A55C')
}else if (res.attestationSchedule == 'Test passed') {
data.push({
value: res.attestationScheduleCount,
name: this.$t('experimentPassed'),
color: '#68BBC4',
status: res.attestationSchedule
})
color.push('#68BBC4')
} }
this.mainTopNum += res.designFlowTaskStatusCount this.mainTopNum += res.attestationScheduleCount
}) })
} }
this.getEcharts('main-end-Collect', this.$t('OTaauthenticationprogressstatistics'), color, data) this.getEcharts('main-end-Collect', this.$t('OTaauthenticationprogressstatistics'), color, data)
@@ -355,7 +378,14 @@
responsibility(item) { responsibility(item) {
this.$emit('currentStatus', item) this.$emit('currentStatus', item)
}, },
jump(){ vdrcheckClick(){
this.options.forEach(item => {
if(item.plannedBpLaunchBatch == this.queryParam.plannedBpLaunchBatch){
this.vehicleTypeCode = item.appliedVehicleProject
this.softwareversion = item.plannedBpLaunchBatch
this.releaseName = item.updateDate
}
})
let newUrl = this.$router.resolve({ let newUrl = this.$router.resolve({
path:'/components/detil', path:'/components/detil',
query:{ query:{