Browse Source

完善应急预案

dev
陈鹏飞 3 years ago
parent
commit
9f4cdcaade
  1. 8
      src/app/pages/left-domain/left-domain.component.ts
  2. 7
      src/app/pages/plan/plan.component.html
  3. 10
      src/app/pages/plan/plan.component.ts
  4. 5
      src/styles.scss

8
src/app/pages/left-domain/left-domain.component.ts

@ -53,7 +53,9 @@ export class LeftDomainComponent implements OnInit {
MarkWindow.instance ? this.allMarkPlanData = MarkWindow.instance.allMarkPlanData : null
EventManager.addListener(Event_GetAllMarkPlanData, (data: Event_GetAllMarkPlanData) => {
this.allMarkPlanData = data.data
PlanComponent.instance.allMarkPlanData = this.allMarkPlanData
})
PlanComponent.instance.allMarkPlanData = this.allMarkPlanData
return
}
let list: FacilityInfoUIItem[] = []
@ -209,6 +211,8 @@ export class LeftDomainComponent implements OnInit {
selectNode(item: MarkPlanData, e: MarkNodeData) {
if (this.selectPlanId != item.id || this.selectNodeId != e.id) { //选中
if (!MarkWindow.instance.currentMarkNodeInfo) { //未选中节点
PlanComponent.instance.beforeEmergencyPlan = item
PlanComponent.instance.beforePlanNode = e
this.selectPlanId = item.id
this.selectNodeId = e.id
MarkWindow.instance.selectMarkNode(item.id, e.id)
@ -218,6 +222,8 @@ export class LeftDomainComponent implements OnInit {
isTrue = confirm('切换节点后,没保存的信息将会丢失!')
}
if (isTrue) {
PlanComponent.instance.beforeEmergencyPlan = item
PlanComponent.instance.beforePlanNode = e
this.selectPlanId = item.id
this.selectNodeId = e.id
MarkWindow.instance.selectMarkNode(item.id, e.id)
@ -229,6 +235,8 @@ export class LeftDomainComponent implements OnInit {
isTrue = confirm('切换节点后,没保存的信息将会丢失!')
}
if (isTrue) {
PlanComponent.instance.beforeEmergencyPlan = null
PlanComponent.instance.beforePlanNode = null
this.selectPlanId = null
this.selectNodeId = null
MarkWindow.instance.selectMarkNode(null, null)

7
src/app/pages/plan/plan.component.html

@ -151,7 +151,12 @@
</div>
<div style="height: 5px;"></div>
<div class="pulicPlanDiv bottomPlanCenter">
<label><button>处置预案</button></label>
<label><button nz-dropdown [nzDropdownMenu]="plan" nzTrigger="click">处置预案</button></label>
<nz-dropdown-menu #plan="nzDropdownMenu">
<ul nz-menu class="dropDown dropDownPlan" *ngIf="allMarkPlanData">
<li nz-menu-item *ngFor="let item of allMarkPlanData.datas;let key = index;">{{item.name}}</li>
</ul>
</nz-dropdown-menu>
<label>
<nz-steps>
<nz-step [nzIcon]="iconTemplate"></nz-step>

10
src/app/pages/plan/plan.component.ts

@ -22,6 +22,7 @@ import { JYZInfoMoudleType } from 'src/app/babylon/model/data/institution/jyz-sh
import { AllMarkData } from 'src/app/babylon/model/data/mark/all-mark-data';
import { MarkData } from 'src/app/babylon/model/data/mark/mark-data';
import { MarkWindow } from 'src/app/babylon/view/mark-window/mark-window';
import { AllMarkPlanData, MarkNodeData, MarkPlanData } from 'src/app/babylon/model/data/mark/mark-plan-data';
@ -315,6 +316,15 @@ export class PlanComponent implements OnInit {
}
}
allMarkPlanData: AllMarkPlanData; //处置预案节点 数据
beforeEmergencyPlan: MarkPlanData = null; //当前选择 应急预案
beforePlanNode: MarkNodeData = null; //当前选择 预案节点
//选中应急预案 设备
selectSandTableMark(markData: MarkData, select: boolean) {
MarkWindow.instance.selectMarkData(markData, select)
}
selectRightTopFast: number = 0; //当前选择功能 快捷栏
selectAdsorb: boolean = false; //吸附状态
topLevelView: boolean = false; //顶视图状态

5
src/styles.scss

@ -110,6 +110,11 @@ h1 {
li { text-align: center; }
.ant-checkbox-wrapper { color: #fff; }
}
.dropDownPlan{
background: linear-gradient(360deg, #000D21 0%, rgba(0, 59, 110, 0.8) 100%);
box-shadow: 0px 0px 6px #2399FF;
li { color: #fff; }
}
#threeDimensional {
.ant-tree{ color: #C4E2FC; } //tree
.ant-tree,.ant-tree-node-content-wrapper:hover,.ant-tree-node-content-wrapper.ant-tree-node-selected { background-color: transparent; } //tree

Loading…
Cancel
Save