Browse Source

应急预案完善

dev
陈鹏飞 3 years ago
parent
commit
799db9e567
  1. 4
      src/app/pages/left-domain/left-domain.component.ts
  2. 24
      src/app/pages/plan/plan.component.html
  3. 35
      src/app/pages/plan/plan.component.ts

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

@ -235,8 +235,8 @@ export class LeftDomainComponent implements OnInit {
isTrue = confirm('切换节点后,没保存的信息将会丢失!')
}
if (isTrue) {
PlanComponent.instance.beforeEmergencyPlan = null
PlanComponent.instance.beforePlanNode = null
PlanComponent.instance.beforeEmergencyPlan = new MarkPlanData(-99, "请选择节点")
PlanComponent.instance.beforePlanNode = new MarkNodeData(-99, "请选择节点")
this.selectPlanId = null
this.selectNodeId = null
MarkWindow.instance.selectMarkNode(null, null)

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

@ -143,33 +143,33 @@
<div class="bottomPlan" *ngIf="selectFence === 7">
<div class="pulicPlanDiv bottomPlanHeader">
<div class="planHeaderText">
<p>灾情描述</p>
<textarea></textarea>
<p><input type="text" [(ngModel)]="beforePlanNode.name" [disabled]="!editMode"></p>
<textarea [(ngModel)]="beforePlanNode.describe"></textarea>
</div>
<div class="planHeaderImg"><a href="javascript:;" class="bottomPlanUpload"><input type="file"><img src="../../../assets/images/uploadImg.png"></a></div>
<div class="planHeaderVideo"><a href="javascript:;" class="bottomPlanUpload" style="width: 100px;"><input type="file"><img src="../../../assets/images/uploadVideo.png"></a></div>
</div>
<div style="height: 5px;"></div>
<div class="pulicPlanDiv bottomPlanCenter">
<label><button nz-dropdown [nzDropdownMenu]="plan" nzTrigger="click">处置预案</button></label>
<label><button nz-dropdown [nzDropdownMenu]="plan" nzTrigger="click">{{beforeEmergencyPlan.name}}</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>
<li nz-menu-item *ngFor="let item of allMarkPlanData.datas;let key = index;" (click)="selectChildNode(item)" [ngStyle]="{'color': beforeEmergencyPlan.id === item.id? '#23D9FF' : null}">{{item.name}}</li>
</ul>
</nz-dropdown-menu>
<label>
<nz-steps>
<nz-step [nzIcon]="iconTemplate"></nz-step>
<nz-step [nzIcon]="iconTemplate"></nz-step>
<nz-step [nzIcon]="iconTemplate"></nz-step>
<nz-steps *ngIf="beforeEmergencyPlan.nodes && beforeEmergencyPlan.nodes.length">
<nz-step [nzIcon]="voidTemplate"></nz-step>
<nz-step [nzIcon]="iconTemplate" *ngFor="let item of beforeEmergencyPlan.nodes"></nz-step>
<ng-template #voidTemplate></ng-template>
<ng-template #iconTemplate><img src="../../../assets/images/stepIcon.png"></ng-template>
</nz-steps>
</label>
<label>
<i nz-icon nzType="backward" nzTheme="outline"></i>
<i nz-icon nzType="pause" nzTheme="outline"></i>
<i nz-icon nzType="border" nzTheme="outline"></i>
<i nz-icon nzType="forward" nzTheme="outline"></i>
<i nz-icon nzType="backward" nzTheme="outline" (click)="toLast()"></i>
<i nz-icon nzType="pause" nzTheme="outline" (click)="suspend()"></i>
<i nz-icon nzType="border" nzTheme="outline" (click)="initialize()"></i>
<i nz-icon nzType="forward" nzTheme="outline" (click)="toNext()"></i>
</label>
</div>
</div>

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

@ -317,8 +317,39 @@ export class PlanComponent implements OnInit {
}
allMarkPlanData: AllMarkPlanData; //处置预案节点 数据
beforeEmergencyPlan: MarkPlanData = null; //当前选择 应急预案
beforePlanNode: MarkNodeData = null; //当前选择 预案节点
beforeEmergencyPlan: MarkPlanData = new MarkPlanData(-99, "请选择节点"); //当前选择 应急预案
beforePlanNode: MarkNodeData = new MarkNodeData(-99, "请选择节点"); //当前选择 预案节点
//选中 子组件预案节点
selectChildNode(item: MarkPlanData) {
if (this.isShowChildComponent && this.leftDomain) {
if (item.nodes.length) {
this.leftDomain.selectNode(item, item.nodes[0])
} else {
this.message.info('暂无数据节点');
}
}
}
//切换预案节点 上一个
toLast() {
}
//切换预案节点 暂停
suspend() {
}
//切换预案节点 初始化
initialize() {
}
//切换预案节点 下一个
toNext() {
}
//选中应急预案 设备
selectSandTableMark(markData: MarkData, select: boolean) {

Loading…
Cancel
Save