chenjingyu 4 years ago
parent
commit
2c5f98eb65
  1. 15
      src/app/key-unit/edit-plan-info/edit-plan-info.component.html
  2. 13
      src/app/key-unit/edit-plan-info/edit-plan-info.component.scss
  3. 5
      src/app/key-unit/edit-plan-info/edit-plan-info.component.ts
  4. 12
      src/app/key-unit/view-unit-details/view-unit-details.component.html
  5. 13
      src/app/key-unit/view-unit-details/view-unit-details.component.scss
  6. 8
      src/app/key-unit/view-unit-details/view-unit-details.component.ts
  7. 1
      src/app/ui/collection-tools-building/collection-tools.component.html
  8. 11
      src/app/ui/collection-tools-building/collection-tools.component.scss
  9. 24
      src/app/ui/collection-tools-building/collection-tools.component.ts
  10. 5
      src/app/ui/collection-tools-plan/collection-tools.component.ts
  11. 1
      src/app/ui/collection-tools/collection-tools.component.html
  12. 10
      src/app/ui/collection-tools/collection-tools.component.scss
  13. 22
      src/app/ui/collection-tools/collection-tools.component.ts

15
src/app/key-unit/edit-plan-info/edit-plan-info.component.html

@ -1,7 +1,14 @@
<mat-tab-group selectedIndex="0" style="height: 100%;" >
<div class="fixedPrompt">
<label class="scorePrompt" *ngIf="selected.value == 0"><label style="color: red;">*</label>单位信息,建筑信息填写完整可得满分</label>
<label class="scorePrompt" *ngIf="selected.value == 1"><label style="color: red;">*</label>单位毗邻模块标注完整可得满分</label>
<label class="scorePrompt" *ngIf="selected.value == 2"><label style="color: red;">*</label>消防设施,重点部位模块标注完整可得满分</label>
<label class="scorePrompt" *ngIf="selected.value == 3"><label style="color: red;">*</label>总平面图模块标注完整可得满分</label>
<label class="scorePrompt" *ngIf="selected.value == 4 || selected.value == 5"><label style="color: red;">*</label>层平面图模块标注完整可得满分</label>
<label class="scorePrompt" *ngIf="selected.value == 6"><label style="color: red;">*</label>填写2条以上可得满分</label>
<label class="scorePrompt" *ngIf="selected.value == 9"><label style="color: red;">*</label>外观,室内,安全出口上传图片可得满分</label>
<label class="scorePrompt" *ngIf="selected.value == 10"><label style="color: red;">*</label>上传2张CAD图片可得满分</label>
</div>
<mat-tab-group style="height: 100%;" [selectedIndex]="selected.value" (selectedIndexChange)="selected.setValue($event)">
<mat-tab label="1.基本信息">
<ng-template matTabContent>
<app-basicinfo></app-basicinfo>

13
src/app/key-unit/edit-plan-info/edit-plan-info.component.scss

@ -1,3 +1,16 @@
.mat-tab-body-wrapper{
height: 100%!important;
}
.fixedPrompt {
position: relative;
width: 100%;
height: 0px;
.scorePrompt {
width: 100%;
text-align: center;
position: absolute;
top: 35px;
font-size: 16px;
z-index: 111;
}
}

5
src/app/key-unit/edit-plan-info/edit-plan-info.component.ts

@ -1,4 +1,5 @@
import { Component, OnInit } from '@angular/core';
import { FormControl } from '@angular/forms';
@Component({
selector: 'app-edit-plan-info',
@ -9,7 +10,7 @@ export class EditPlanInfoComponent implements OnInit {
constructor() { }
ngOnInit(): void {
}
ngOnInit(): void { }
selected = new FormControl(0);
}

12
src/app/key-unit/view-unit-details/view-unit-details.component.html

@ -1,4 +1,14 @@
<mat-tab-group selectedIndex="0" style="height:99%;" (selectedTabChange)="selectedtab($event)">
<div class="fixedPrompt">
<label class="scorePrompt" *ngIf="selected.value == 0"><label style="color: red;">*</label>单位信息,建筑信息填写完整可得满分</label>
<label class="scorePrompt" *ngIf="selected.value == 1"><label style="color: red;">*</label>单位毗邻模块标注完整可得满分</label>
<label class="scorePrompt" *ngIf="selected.value == 2"><label style="color: red;">*</label>消防设施,重点部位模块标注完整可得满分</label>
<label class="scorePrompt" *ngIf="selected.value == 3"><label style="color: red;">*</label>总平面图模块标注完整可得满分</label>
<label class="scorePrompt" *ngIf="selected.value == 4 || selected.value == 5"><label style="color: red;">*</label>层平面图模块标注完整可得满分</label>
<label class="scorePrompt" *ngIf="selected.value == 6"><label style="color: red;">*</label>填写2条以上可得满分</label>
<label class="scorePrompt" *ngIf="selected.value == 9"><label style="color: red;">*</label>外观,室内,安全出口上传图片可得满分</label>
<label class="scorePrompt" *ngIf="selected.value == 10"><label style="color: red;">*</label>上传2张CAD图片可得满分</label>
</div>
<mat-tab-group style="height:100%;" [selectedIndex]="selected.value" (selectedIndexChange)="selected.setValue($event)">
<mat-tab label="1.基本信息">
<ng-template matTabContent>
<app-basicinfo-look></app-basicinfo-look>

13
src/app/key-unit/view-unit-details/view-unit-details.component.scss

@ -1,3 +1,16 @@
.mat-tab-body-wrapper{
height: 100%!important;
}
.fixedPrompt {
position: relative;
width: 100%;
height: 0px;
.scorePrompt {
width: 100%;
text-align: center;
position: absolute;
top: 35px;
font-size: 16px;
z-index: 111;
}
}

8
src/app/key-unit/view-unit-details/view-unit-details.component.ts

@ -1,4 +1,5 @@
import { Component, OnInit } from '@angular/core';
import { FormControl } from '@angular/forms';
@Component({
selector: 'app-view-unit-details',
@ -9,10 +10,7 @@ export class ViewUnitDetailsComponent implements OnInit {
constructor() { }
ngOnInit(): void {
}
ngOnInit(): void { }
selected = new FormControl(0);
selectedtab(e){
sessionStorage.setItem("tabsindex",e.index)
}
}

1
src/app/ui/collection-tools-building/collection-tools.component.html

@ -431,6 +431,7 @@
</div>
<div class="firecategoriesTree">
<div class="hideAllTreeNode" (click)='toggoleAllTreenode()' *ngIf="allFireElements.length"><label>全部显示/隐藏</label><mat-icon [ngClass]="{'icongray': hideAllTreenode == false}">visibility</mat-icon></div>
<!-- 消防列表树写在这里 -->
<mat-tree [dataSource]="dataSource" [treeControl]="treeControl" cdkDropList [cdkDropListData]="dataSource" (cdkDropListDropped)="drop($event)">

11
src/app/ui/collection-tools-building/collection-tools.component.scss

@ -191,7 +191,6 @@
}
}
//右侧属性
.property{
display: flex;
@ -314,6 +313,16 @@
}
}
.hideAllTreeNode {
box-sizing: border-box;
margin: 3px 0;
padding: 0 6px 0 10px;
font-size: 14px;
height: 24px;
line-height: 24px;
display: flex;
label { display: inline-block; flex: 1; cursor: pointer; }
}
//右侧消防要素
.firecategories{
background-color: #fff;

24
src/app/ui/collection-tools-building/collection-tools.component.ts

@ -1316,7 +1316,7 @@ export class CollectionToolsBuildingComponent implements OnInit {
//处理 tree 数据结构
handleTreeData (storeyData) {
this.hideAllTreenode = true
this.storeyData = storeyData
let data = this.allFireElements //所有消防要素模板
let treeData = [] //tree型 处理完成后的数据
@ -1384,9 +1384,24 @@ export class CollectionToolsBuildingComponent implements OnInit {
this.canvas.setHighlight(iconHighLightArr)
}
hideAllTreenode:boolean = true; //全部显示/隐藏tree节点
toggoleAllTreenode () {
this.hideAllTreenode = !this.hideAllTreenode
let list = []
this.allFireElements.forEach(element=>{
if (element.isTemplate) { this.hideAllTreenode? element.isLook = false : element.isLook = true }
})
this.treeControl.dataNodes.forEach(item=>{
this.hideAllTreenode? item.isLook = false : item.isLook = true
item.level === 0 ? list.push(item) : null
})
list.forEach(item=>{
this.clickLookItem(item)
})
}
//点击数节点的显示隐藏icon
clickLookItem(node){
//修改真实素材islook属性
for(let key in this.storeyData.data){
if(key == node.id){
@ -1397,9 +1412,8 @@ export class CollectionToolsBuildingComponent implements OnInit {
//所有消防要素模板变化islook值
if(node.isTemplate){
this.allFireElements.forEach(item=>{
if(item.id == node.id || item.name == "其他"){
item.isLook = !item.isLook
}
if(item.id == node.id){ item.isLook = !item.isLook }
if (item.name == '其他' && node.name == '其他') { item.isLook = !item.isLook }
})
}

5
src/app/ui/collection-tools-plan/collection-tools.component.ts

@ -1409,9 +1409,8 @@ export class CollectionToolsPlanComponent implements OnInit {
//所有消防要素模板变化islook值
if(node.isTemplate){
this.allFireElements.forEach(item=>{
if(item.id == node.id || item.name == "其他"){
item.isLook = !item.isLook
}
if(item.id == node.id){ item.isLook = !item.isLook }
if (item.name == '其他' && node.name == '其他') { item.isLook = !item.isLook }
})
}

1
src/app/ui/collection-tools/collection-tools.component.html

@ -507,6 +507,7 @@
</div>
<div class="firecategoriesTree">
<div class="hideAllTreeNode" (click)='toggoleAllTreenode()' *ngIf="allFireElements.length"><label>全部显示/隐藏</label><mat-icon [ngClass]="{'icongray': hideAllTreenode == false}">visibility</mat-icon></div>
<!-- 消防列表树写在这里 -->
<mat-tree [dataSource]="dataSource" [treeControl]="treeControl" cdkDropList [cdkDropListData]="dataSource" (cdkDropListDropped)="drop($event)">

10
src/app/ui/collection-tools/collection-tools.component.scss

@ -357,6 +357,16 @@
}
}
.hideAllTreeNode {
box-sizing: border-box;
margin: 3px 0;
padding: 0 6px 0 10px;
font-size: 14px;
height: 24px;
line-height: 24px;
display: flex;
label { display: inline-block; flex: 1; cursor: pointer; }
}
//右侧消防要素
.firecategories{
position: relative;

22
src/app/ui/collection-tools/collection-tools.component.ts

@ -1329,6 +1329,7 @@ export class CollectionToolsComponent implements OnInit {
selectPanelPoint //传过来的处置素材
//处理 tree 数据结构
handleTreeData (storeyData,selectPanelPoint) {
this.hideAllTreenode = true
this.storeyData = storeyData
this.selectPanelPoint = selectPanelPoint
let data = this.allFireElements //所有消防要素模板
@ -1420,6 +1421,22 @@ export class CollectionToolsComponent implements OnInit {
this.canvas.setHighlight(iconHighLightArr)
}
hideAllTreenode:boolean = true; //全部显示/隐藏tree节点
toggoleAllTreenode () {
this.hideAllTreenode = !this.hideAllTreenode
let list = []
this.allFireElements.forEach(element=>{
if (element.isTemplate) { this.hideAllTreenode? element.isLook = false : element.isLook = true }
})
this.treeControl.dataNodes.forEach(item=>{
this.hideAllTreenode? item.isLook = false : item.isLook = true
item.level === 0 ? list.push(item) : null
})
list.forEach(item=>{
this.clickLookItem(item)
})
}
//点击数节点的显示隐藏icon
clickLookItem(node){
//修改真实素材islook属性
@ -1439,9 +1456,8 @@ export class CollectionToolsComponent implements OnInit {
//所有消防要素模板变化islook值
if(node.isTemplate){
this.allFireElements.forEach(item=>{
if(item.id == node.id || item.name == "其他"){
item.isLook = !item.isLook
}
if ( item.id == node.id ) { item.isLook = !item.isLook }
if (item.name == '其他' && node.name == '其他') { item.isLook = !item.isLook }
})
}

Loading…
Cancel
Save