历史数据刷新

This commit is contained in:
zhouyuejun
2018-12-24 18:32:32 +08:00
parent 9815df7b0f
commit bcda5908e7
5 changed files with 96 additions and 24 deletions
+8 -8
View File
@@ -142,21 +142,21 @@
[ngClass]="{'selected':row_state['renderFlight']['FLNO']===airline_row['renderFlight']['FLNO']}">
<td>{{i+1}}</td>
<td>
<img class="mr-2" *ngIf="getVipNotes(airline_row)" src="/adminweb/assets/images/important-notes/vip.png"
<img class="mr-2" *ngIf="getVipNotes(airline_row)" src="/assets/images/important-notes/vip.png"
alt="">
<img class="mr-2" *ngIf="getOutplanNotes(airline_row)" src="/adminweb/assets/images/important-notes/out_plan.png"
<img class="mr-2" *ngIf="getOutplanNotes(airline_row)" src="/assets/images/important-notes/out_plan.png"
alt="">
<img class="mr-2" *ngIf="getAlternateNotes(airline_row)" src="/adminweb/assets/images/important-notes/alternate.png"
<img class="mr-2" *ngIf="getAlternateNotes(airline_row)" src="/assets/images/important-notes/alternate.png"
alt="">
<img class="mr-2" *ngIf="getDelay30Notes(airline_row)" src="/adminweb/assets/images/important-notes/delay_30.png"
<img class="mr-2" *ngIf="getDelay30Notes(airline_row)" src="/assets/images/important-notes/delay_30.png"
alt="">
<img class="mr-2" *ngIf="getDelayNotes(airline_row)" src="/adminweb/assets/images/important-notes/delay.png"
<img class="mr-2" *ngIf="getDelayNotes(airline_row)" src="/assets/images/important-notes/delay.png"
alt="">
<img class="mr-2" *ngIf="getReturnNotes(airline_row)" src="/adminweb/assets/images/important-notes/return.png"
<img class="mr-2" *ngIf="getReturnNotes(airline_row)" src="/assets/images/important-notes/return.png"
alt="">
<img class="mr-2" *ngIf="getCancleNotes(airline_row)" src="/adminweb/assets/images/important-notes/cancle.png"
<img class="mr-2" *ngIf="getCancleNotes(airline_row)" src="/assets/images/important-notes/cancle.png"
alt="">
<img class="mr-2" *ngIf="getStopoverNotes(airline_row)" src="/adminweb/assets/images/important-notes/stopover.png"
<img class="mr-2" *ngIf="getStopoverNotes(airline_row)" src="/assets/images/important-notes/stopover.png"
alt="">
</td>
<td>{{airline_row['renderFlight']['FLID']}}</td>
+12 -4
View File
@@ -43,6 +43,7 @@ export class MainComponent implements OnInit {
).subscribe(
(event: NavigationEnd) => {
if (event.urlAfterRedirects === '/app/main') {
// this.operateSpinServiceService.showSpin();
this.httpCilent.get('/adminapi/settings/uisettings').subscribe(
data => {
data.body.forEach(element => {
@@ -56,6 +57,7 @@ export class MainComponent implements OnInit {
}
});
this.changeDetectorRef.detectChanges();
// this.operateSpinServiceService.hideSpin();
}
)
}
@@ -123,6 +125,7 @@ export class MainComponent implements OnInit {
let data = JSON.parse(event as string);
if (data.topic === 'schd') {
let message = JSON.parse(data.message);
console.log(message);
//是否可以开始处理动态消息
if (this.canHandleDynamicMessage) {
this.dynamicMessageHandle(message);
@@ -131,6 +134,7 @@ export class MainComponent implements OnInit {
}
} else if (data.topic === 'msg') {
let message = JSON.parse(data.message);
console.log(message);
if (this.canHandleDynamicAlert) {
this.dynamicAlertHandle(message);
} else {
@@ -828,13 +832,17 @@ export class MainComponent implements OnInit {
if (this.orderHandle.isArriFlight(flight)) {
return false;
} else {
if (flight['reaFlight']['DELY'] && Array.isArray(flight['reaFlight']['DELY']) && flight['reaFlight']['DELY'].length > 0) {
if (parseInt(flight['preFlight']['DELY'][0]['DURA']) - 30 > 0) {
return true;
try {
if (flight['reaFlight']['DELY'] && Array.isArray(flight['reaFlight']['DELY']) && flight['reaFlight']['DELY'].length > 0) {
if (parseInt(flight['preFlight']['DELY'][0]['DURA']) - 30 > 0) {
return true;
} else {
return false;
}
} else {
return false;
}
} else {
} catch (error) {
return false;
}
}