陈鹏飞 3 years ago
parent
commit
46d844b0ed
  1. 2
      package.json
  2. 12
      src/app/babylon/controller/config-manager.ts
  3. 2
      src/app/babylon/controller/mode-manager.ts
  4. 2
      src/app/babylon/controller/scene-manager.ts
  5. 6
      src/app/babylon/model/data/model-data/model-data-facility.ts
  6. 3
      src/app/http-interceptors/base-interceptor.ts
  7. 76
      src/app/pages/home-page/home-page.component.ts
  8. 6
      src/app/pages/home/home.component.html
  9. 73
      src/app/pages/home/home.component.ts
  10. 47
      src/app/pages/today-warning-admin/today-warning-admin.component.ts
  11. 6
      src/app/pages/today-warning/get-out-of-line-details/get-out-of-line-details.component.html
  12. 1
      src/app/pages/today-warning/get-out-of-line-details/get-out-of-line-details.component.scss
  13. 46
      src/app/pages/today-warning/today-warning.component.ts
  14. BIN
      src/assets/images/facility/in/XF_MHQ_GF_25.png
  15. BIN
      src/assets/images/facility/in/XF_MHQ_GF_35.png
  16. BIN
      src/assets/images/facility/in/XF_MHQ_GF_4.png
  17. BIN
      src/assets/images/facility/in/XF_MHQ_GF_8.png
  18. BIN
      src/assets/images/facility/in/XF_MHQ_PT_35.png
  19. BIN
      src/assets/images/facility/in/XF_MHQ_PT_4.png
  20. BIN
      src/assets/images/facility/in/XF_MHQ_PT_8.png
  21. BIN
      src/assets/images/facility/in/XF_MHT.png
  22. BIN
      src/assets/images/facility/in/XF_XFCM.png
  23. BIN
      src/assets/images/facility/in/XF_XFF.png
  24. BIN
      src/assets/images/facility/in/XF_XFQ.png
  25. BIN
      src/assets/images/facility/in/XF_XFS.png
  26. BIN
      src/assets/images/facility/in/XF_XFT.png
  27. BIN
      src/assets/images/mark/inside/gfmhq.png
  28. BIN
      src/assets/images/mark/inside/ptmhq.png
  29. BIN
      src/assets/images/mark/inside/tcmhq.png

2
package.json

@ -80,4 +80,4 @@
"tslint": "~5.15.0",
"typescript": "~3.7.5"
}
}
}

12
src/app/babylon/controller/config-manager.ts

@ -43,8 +43,8 @@ export class ConfigManager {
case FacilityType.QY:
case FacilityType.TPBZ:
case FacilityType.DWBZ:
// case FacilityType.JY_JYJ://临时
case FacilityType.JY_YG://临时
// case FacilityType.JY_JYJ://临时
// case FacilityType.JY_YG://临时
result = true;
break;
@ -82,9 +82,9 @@ export class ConfigManager {
case FacilityType.TPBZ: result = "图片"; break;
case FacilityType.DWBZ: result = "点位"; break;
//内建
case FacilityType.XF_MHQ_PT_4: result = "4kg普通灭火器"; break;
case FacilityType.XF_MHQ_PT_8: result = "8kg普通灭火器"; break;
case FacilityType.XF_MHQ_PT_35: result = "35kg普通灭火器"; break;
case FacilityType.XF_MHQ_PT_4: result = "4kg二氧化碳灭火器"; break;
case FacilityType.XF_MHQ_PT_8: result = "8kg二氧化碳灭火器"; break;
case FacilityType.XF_MHQ_PT_35: result = "35kg二氧化碳灭火器"; break;
case FacilityType.XF_MHQ_GF_4: result = "4kg干粉灭火器"; break;
case FacilityType.XF_MHQ_GF_8: result = "8kg干粉灭火器"; break;
case FacilityType.XF_MHQ_GF_25: result = "25kg干粉灭火器"; break;
@ -154,7 +154,7 @@ export class ConfigManager {
[MarkType.YGCSJ, "油罐车司机"],
[MarkType.XFSD, "消防沙(堆)"],
[MarkType.XFSQ, "消防沙(圈)"],
[MarkType.PTMHQ, "普通灭火器"],
[MarkType.PTMHQ, "二氧化碳灭火器"],
[MarkType.GFMHQ, "干粉灭火器"],
[MarkType.TCMHQ, "推车灭火器"],
[MarkType.ZYMBRQ, "专用密闭容器"],

2
src/app/babylon/controller/mode-manager.ts

@ -23,7 +23,7 @@ export class ModeManager {
/**
*
*/
public static s_isMakeMode = true;
public static s_isMakeMode = false;
/**
*

2
src/app/babylon/controller/scene-manager.ts

@ -431,7 +431,7 @@ export class SceneManager {
if (ev.altKey && ev.key == 'd' && ModeManager.isDebug) {
SceneManager.showDebug = !SceneManager.showDebug;
if (SceneManager.showDebug) {
SceneManager.Instance.scene.debugLayer.show();
SceneManager.Instance.scene.debugLayer.show({ embedMode: true });
} else {
SceneManager.Instance.scene.debugLayer.hide();
}

6
src/app/babylon/model/data/model-data/model-data-facility.ts

@ -158,15 +158,15 @@ export enum FacilityType {
//模型内置
/**
* - 4kg
* - 4kg
*/
XF_MHQ_PT_4 = "XF_MHQ_PT_4",
/**
* - 8kg
* - 8kg
*/
XF_MHQ_PT_8 = "XF_MHQ_PT_8",
/**
* - 35kg ()
* - 35kg ()
*/
XF_MHQ_PT_35 = "XF_MHQ_PT_35",
/**

3
src/app/http-interceptors/base-interceptor.ts

@ -56,7 +56,8 @@ export class BaseInterceptor implements HttpInterceptor {
if (error.status === 401 || error.status === 614) {
this.token.delete()
sessionStorage.clear()
window.localStorage.clear()
// window.localStorage.clear()
localStorage.removeItem("isautologin")
this.cookieService.set("token", '', new Date(new Date().getTime() + 1), '/')
this.cookieService.set("refreshToken", '', new Date(new Date().getTime() + 1), '/')
this.message.create('error', `用户认证信息过期,请重新登录!`);

76
src/app/pages/home-page/home-page.component.ts

@ -5,6 +5,7 @@ import * as echarts from 'echarts';
import * as moment from 'moment';
import { NzModalService } from 'ng-zorro-antd/modal';
import { GetOutOfLineDetailsComponent } from '../today-warning/get-out-of-line-details/get-out-of-line-details.component';
import { NzMessageService } from 'ng-zorro-antd/message';
@Component({
selector: 'app-home-page',
templateUrl: './home-page.component.html',
@ -12,7 +13,7 @@ import { GetOutOfLineDetailsComponent } from '../today-warning/get-out-of-line-d
})
export class HomePageComponent implements OnInit {
constructor(private http: HttpClient, private router: Router, private modal: NzModalService, private viewContainerRef: ViewContainerRef) { }
constructor(private http: HttpClient, private router: Router, private modal: NzModalService, private viewContainerRef: ViewContainerRef, private message: NzMessageService) { }
warningechartpie//预警饼图
warningechartpieOption = {
@ -75,7 +76,7 @@ export class HomePageComponent implements OnInit {
textShadowColor: '#8df',
textShadowBlur: 3,
color: '#fff',
},
active: {
fontSize: 14,
@ -272,10 +273,10 @@ export class HomePageComponent implements OnInit {
violationType: {
violationTypeAgg: []
},
dev:{
stationCount:'',
violationCount:'',
cameraCount:''
dev: {
stationCount: '',
violationCount: '',
cameraCount: ''
}
}
totalCount
@ -641,36 +642,43 @@ export class HomePageComponent implements OnInit {
isOpenModel: boolean = false
look(item) {
this.isOpenModel = true
let data = {
violateImage: item.notification.data.violateImage,
violateVideo: item.notification.data.violateVideo
console.log(item)
if (item.notification.data.eventSystemName == '灭火器维护' || item.notification.data.eventSystemName == '证照预警') {
this.message.create('warning', `证照或者器材即将临期,请联系加油站处理!`);
} else {
this.isOpenModel = true
let data = {
violateImage: item.notification.data.violateImage,
violateVideo: item.notification.data.violateVideo
}
const modal = this.modal.create({
nzContent: GetOutOfLineDetailsComponent,
nzViewContainerRef: this.viewContainerRef,
nzWidth: 1200,
nzBodyStyle: {
'border': '1px solid #6d9cc7',
'border-radius': '0px',
'padding': '0px',
'box-shadow': '0 0 8px 0 #fff',
'background': '#000D21',
},
nzComponentParams: {
data: data
},
nzFooter: null,
nzOnOk: async () => {
}
});
const instance = modal.getContentComponent();
modal.afterClose.subscribe(result => {
this.isOpenModel = false
this.rollStart()
});
this.readMess(item.notification.id)
}
const modal = this.modal.create({
nzContent: GetOutOfLineDetailsComponent,
nzViewContainerRef: this.viewContainerRef,
nzWidth: 1200,
nzBodyStyle: {
'border': '1px solid #6d9cc7',
'border-radius': '0px',
'padding': '0px',
'box-shadow': '0 0 8px 0 #fff',
'background': '#000D21',
},
nzComponentParams: {
data: data
},
nzFooter: null,
nzOnOk: async () => {
}
});
const instance = modal.getContentComponent();
modal.afterClose.subscribe(result => {
this.isOpenModel = false
this.rollStart()
});
this.readMess(item.notification.id)
}
//标记为已读

6
src/app/pages/home/home.component.html

@ -87,4 +87,8 @@
忽略
</div>
</div>
</ng-template>
</ng-template>
<!--
<nz-modal [(nzVisible)]="isVisible">
<app-get-out-of-line-details [data]="modalData"></app-get-out-of-line-details>
</nz-modal> -->

73
src/app/pages/home/home.component.ts

@ -85,7 +85,7 @@ export class HomeComponent implements OnInit {
}
reloadPage = (userNotification) => {
reloadPage = (userNotification) => {
console.log('abp.notifications.received收到通知', userNotification);
this.receiptOfNotification(userNotification)
};
@ -102,42 +102,49 @@ export class HomeComponent implements OnInit {
}
this.messageId.push(obj)
}
isVisible = false
modalData
look(item) {
let params = {
id: item.notification.entityId
}
this.http.get('/api/services/app/ViolateRecord/Get', {
params: params
}).subscribe((data: any) => {
const modal = this.modal.create({
nzContent: GetOutOfLineDetailsComponent,
nzViewContainerRef: this.viewContainerRef,
nzWidth: 1200,
nzBodyStyle: {
'border': '1px solid #6d9cc7',
'border-radius': '0px',
'padding': '0px',
'box-shadow': '0 0 8px 0 #fff',
'background': '#000D21',
},
nzComponentParams: {
data: data.result
},
nzFooter: null,
nzOnOk: async () => {
}
});
const instance = modal.getContentComponent();
this.messageId.forEach((element) => {
if (element.id == item.notification.entityId) {
this.notificationService.remove(element.messageId)
}
if (item.notification.data.properties.EventSystemName == '灭火器维护' || item.notification.data.properties.EventSystemName == '证照预警') {
this.message.create('warning', `证照或者器材即将临期,请联系加油站处理!`);
} else {
let params = {
id: item.notification.entityId
}
this.http.get('/api/services/app/ViolateRecord/Get', {
params: params
}).subscribe((data: any) => {
const modal = this.modal.create({
nzContent: GetOutOfLineDetailsComponent,
nzViewContainerRef: this.viewContainerRef,
nzWidth: 1200,
nzBodyStyle: {
'border': '1px solid #6d9cc7',
'border-radius': '0px',
'padding': '0px',
'box-shadow': '0 0 8px 0 #fff',
'background': '#000D21',
},
nzComponentParams: {
data: data.result
},
nzFooter: null,
nzOnOk: async () => {
}
});
const instance = modal.getContentComponent();
this.messageId.forEach((element) => {
if (element.id == item.notification.entityId) {
this.notificationService.remove(element.messageId)
}
})
this.readMess(item.notification.id)
})
})
this.readMess(item.notification.id)
}
}
//标记为已读

47
src/app/pages/today-warning-admin/today-warning-admin.component.ts

@ -159,34 +159,33 @@ export class TodayWarningAdminComponent implements OnInit {
}
isVisible=false
look(item) {
let type
if (item.violation.violationType.indexOf('卸油')) {
type = 1
if (item.violation.eventSystemName == '灭火器维护' || item.violation.eventSystemName == '证照预警') {
this.message.create('warning', `证照或者器材即将临期,请联系加油站处理!`);
} else {
type = 0
const modal = this.modal.create({
nzContent: GetOutOfLineDetailsComponent,
nzViewContainerRef: this.viewContainerRef,
nzWidth: 1200,
nzBodyStyle: {
'border': '1px solid #6d9cc7',
'border-radius': '0px',
'padding': '0px',
'box-shadow': '0 0 8px 0 #fff',
'background': '#000D21',
},
nzComponentParams: {
data: item
},
nzFooter: null,
nzOnOk: async () => {
}
});
const instance = modal.getContentComponent();
}
const modal = this.modal.create({
nzContent: GetOutOfLineDetailsComponent,
nzViewContainerRef: this.viewContainerRef,
nzWidth: 1200,
nzBodyStyle: {
'border': '1px solid #6d9cc7',
'border-radius': '0px',
'padding': '0px',
'box-shadow': '0 0 8px 0 #fff',
'background': '#000D21',
},
nzComponentParams: {
data: item
},
nzFooter: null,
nzOnOk: async () => {
}
});
const instance = modal.getContentComponent();
}
dispose(item) {

6
src/app/pages/today-warning/get-out-of-line-details/get-out-of-line-details.component.html

@ -13,12 +13,6 @@
</div>
<div class="content">
<div *ngIf="selectedType == 'img'" class="imgbox">
<!-- <div class="imglist">
<span class="imglisttitle">截图列表</span>
<div class="img">
<img src="../../../../assets/images/bgImg.jpg" alt="">
</div>
</div> -->
<div class="bigimg">
<img [src]="imgUrl" alt="">
</div>

1
src/app/pages/today-warning/get-out-of-line-details/get-out-of-line-details.component.scss

@ -98,6 +98,7 @@
}
.bigimg {
// min-width: 1149px;
flex: 1;
box-sizing: border-box;
padding-left: 13px;

46
src/app/pages/today-warning/today-warning.component.ts

@ -113,32 +113,30 @@ export class TodayWarningComponent implements OnInit {
look(item) {
let type
if (item.violation.violationType.indexOf('卸油')) {
type = 1
if (item.violation.eventSystemName == '灭火器维护' || item.violation.eventSystemName == '证照预警') {
this.message.create('warning', `证照或者器材即将临期,请联系加油站处理!`);
} else {
type = 0
}
const modal = this.modal.create({
nzContent: GetOutOfLineDetailsComponent,
nzViewContainerRef: this.viewContainerRef,
nzWidth: 1200,
nzBodyStyle: {
'border': '1px solid #6d9cc7',
'border-radius': '0px',
'padding': '0px',
'box-shadow': '0 0 8px 0 #fff',
'background': '#000D21',
},
nzComponentParams: {
data: item
},
nzFooter: null,
nzOnOk: async () => {
const modal = this.modal.create({
nzContent: GetOutOfLineDetailsComponent,
nzViewContainerRef: this.viewContainerRef,
nzWidth: 1200,
nzBodyStyle: {
'border': '1px solid #6d9cc7',
'border-radius': '0px',
'padding': '0px',
'box-shadow': '0 0 8px 0 #fff',
'background': '#000D21',
},
nzComponentParams: {
data: item
},
nzFooter: null,
nzOnOk: async () => {
}
});
const instance = modal.getContentComponent();
}
});
const instance = modal.getContentComponent();
}
}
dispose(item) {

BIN
src/assets/images/facility/in/XF_MHQ_GF_25.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.7 KiB

After

Width:  |  Height:  |  Size: 5.5 KiB

BIN
src/assets/images/facility/in/XF_MHQ_GF_35.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.7 KiB

After

Width:  |  Height:  |  Size: 5.5 KiB

BIN
src/assets/images/facility/in/XF_MHQ_GF_4.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.5 KiB

After

Width:  |  Height:  |  Size: 4.5 KiB

BIN
src/assets/images/facility/in/XF_MHQ_GF_8.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.7 KiB

After

Width:  |  Height:  |  Size: 4.6 KiB

BIN
src/assets/images/facility/in/XF_MHQ_PT_35.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.4 KiB

After

Width:  |  Height:  |  Size: 5.6 KiB

BIN
src/assets/images/facility/in/XF_MHQ_PT_4.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.3 KiB

After

Width:  |  Height:  |  Size: 4.5 KiB

BIN
src/assets/images/facility/in/XF_MHQ_PT_8.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.4 KiB

After

Width:  |  Height:  |  Size: 4.6 KiB

BIN
src/assets/images/facility/in/XF_MHT.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.1 KiB

After

Width:  |  Height:  |  Size: 3.6 KiB

BIN
src/assets/images/facility/in/XF_XFCM.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.0 KiB

After

Width:  |  Height:  |  Size: 3.6 KiB

BIN
src/assets/images/facility/in/XF_XFF.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.2 KiB

After

Width:  |  Height:  |  Size: 3.7 KiB

BIN
src/assets/images/facility/in/XF_XFQ.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.1 KiB

After

Width:  |  Height:  |  Size: 3.7 KiB

BIN
src/assets/images/facility/in/XF_XFS.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.2 KiB

After

Width:  |  Height:  |  Size: 3.6 KiB

BIN
src/assets/images/facility/in/XF_XFT.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.5 KiB

After

Width:  |  Height:  |  Size: 4.1 KiB

BIN
src/assets/images/mark/inside/gfmhq.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.5 KiB

After

Width:  |  Height:  |  Size: 4.3 KiB

BIN
src/assets/images/mark/inside/ptmhq.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.3 KiB

After

Width:  |  Height:  |  Size: 4.4 KiB

BIN
src/assets/images/mark/inside/tcmhq.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.4 KiB

After

Width:  |  Height:  |  Size: 4.4 KiB

Loading…
Cancel
Save