diff --git a/src/app/key-unit/basicinfo-look/basicinfo.component.html b/src/app/key-unit/basicinfo-look/basicinfo.component.html index 52a1c4e..1d9bfe4 100644 --- a/src/app/key-unit/basicinfo-look/basicinfo.component.html +++ b/src/app/key-unit/basicinfo-look/basicinfo.component.html @@ -6,6 +6,7 @@ 单位信息 +
diff --git a/src/app/key-unit/basicinfo-look/basicinfo.component.ts b/src/app/key-unit/basicinfo-look/basicinfo.component.ts index 03a70aa..80e56d5 100644 --- a/src/app/key-unit/basicinfo-look/basicinfo.component.ts +++ b/src/app/key-unit/basicinfo-look/basicinfo.component.ts @@ -18,6 +18,7 @@ import * as _ from 'lodash'; import Swiper from 'swiper'; import { LookMaster2 } from './lookmaster.component' import { ActivatedRoute } from '@angular/router'; +import { StatisticsOfFireFightingFacilities } from '../basicinfo/basicinfo.component'; declare var AMap: any; @Component({ @@ -26,6 +27,14 @@ declare var AMap: any; styleUrls: ['./basicinfo.component.scss'] }) export class BasicinfoLookComponent implements OnInit { + + //查看消防设施统计 + seeFirfightingDevice (e) { + e.stopPropagation() + let dialogRef = this.dialog.open(StatisticsOfFireFightingFacilities); + dialogRef.afterClosed().subscribe(); + } + unitinfo:any={ id: '', name: '', //单位信息名字 diff --git a/src/app/key-unit/basicinfo/basicinfo.component.html b/src/app/key-unit/basicinfo/basicinfo.component.html index 6f90418..dad7ced 100644 --- a/src/app/key-unit/basicinfo/basicinfo.component.html +++ b/src/app/key-unit/basicinfo/basicinfo.component.html @@ -6,6 +6,7 @@ 单位信息 +
diff --git a/src/app/key-unit/basicinfo/basicinfo.component.ts b/src/app/key-unit/basicinfo/basicinfo.component.ts index 0bd7844..c446ffc 100644 --- a/src/app/key-unit/basicinfo/basicinfo.component.ts +++ b/src/app/key-unit/basicinfo/basicinfo.component.ts @@ -28,6 +28,14 @@ declare var AMap: any; styleUrls: ['./basicinfo.component.scss'] }) export class BasicinfoComponent implements OnInit { + + //查看消防设施统计 + seeFirfightingDevice (e) { + e.stopPropagation() + let dialogRef = this.dialog.open(StatisticsOfFireFightingFacilities); + dialogRef.afterClosed().subscribe(); + } + unitinfo:any={ id: '', name: '', //单位信息名字 @@ -1154,4 +1162,26 @@ export class BasicinfoComponent implements OnInit { this.houses[key].data = data }) } +} + + + +//消防设施统计 +@Component({ + selector: 'app-StatisticsOfFireFightingFacilities', + templateUrl: './statisticsOfFireFightingFacilities.html', + styleUrls: ['./basicinfo.component.scss'] +}) +export class StatisticsOfFireFightingFacilities implements OnInit { + + constructor(private http: HttpClient, public dialog: MatDialog,public snackBar: MatSnackBar) { } + + ngOnInit(): void { + let params = { companyId: sessionStorage.getItem('companyId'),buildingType: sessionStorage.getItem('buildingTypeId') } + this.http.get(`/api/CompanyFacilities/GetAllFacilities`,{params}).subscribe(data=>{ + Object.keys(data).forEach(key => { this.allFireList.push(`${key} ${data[key]}`) }) + }) + } + allFireList = [] + } \ No newline at end of file diff --git a/src/app/key-unit/basicinfo/statisticsOfFireFightingFacilities.html b/src/app/key-unit/basicinfo/statisticsOfFireFightingFacilities.html new file mode 100644 index 0000000..e24e0ab --- /dev/null +++ b/src/app/key-unit/basicinfo/statisticsOfFireFightingFacilities.html @@ -0,0 +1,4 @@ +
消防设施统计
+
+

{{item}}

+
\ No newline at end of file diff --git a/src/app/key-unit/key-unit.module.ts b/src/app/key-unit/key-unit.module.ts index 93d6b60..07f1796 100644 --- a/src/app/key-unit/key-unit.module.ts +++ b/src/app/key-unit/key-unit.module.ts @@ -48,7 +48,7 @@ import { ViewUnitDetailsComponent } from './view-unit-details/view-unit-details. import { ReactiveFormsModule, FormsModule } from '@angular/forms'; import { AddHouseInfo } from './basicinfo/addhouseinfo.component'; import { LookMaster } from './basicinfo/lookmaster.component'; -import { BasicinfoComponent } from './basicinfo/basicinfo.component'; +import { BasicinfoComponent, StatisticsOfFireFightingFacilities } from './basicinfo/basicinfo.component'; import { EditPlanInfoComponent } from './edit-plan-info/edit-plan-info.component'; import { CountdownModule } from 'ngx-countdown'; import { BasicinfoLookComponent } from './basicinfo-look/basicinfo.component'; @@ -88,7 +88,7 @@ import { upname } from './key-unit-management/key-unit-management.component'; import { companyAuditResult } from './key-unit-management/key-unit-management.component' @NgModule({ - declarations: [KeyUnitManagementComponent, EditUnitInfoComponent, ViewUnitDetailsComponent,CreateUnit,BasicinfoComponent,LookMaster,AddHouseInfo, EditPlanInfoComponent,BasicinfoLookComponent, ViewUnitDetailsPlanComponent,FunctionDivisionComponent,addPartition,addPartitionAttribute,AllaroundComponent,ImgDetails,RealisticPictureComponent,previewImg,addRealPicture,editRealPicture,KeySiteComponent,KeyImgDetail,KeySiteImgs,UploadingCADComponent,readFile,editFile,KeySiteLookComponent,KeySiteImgs2,FunctionDivisionLookComponent,RealisticPictureLookComponent,previewImg3,UploadingCADLookComponent,FireFightingDeviceComponent,ImagesData,previewBigImg,ImgsDataDetail,FireFightingDeviceLookComponent,ImagesData2,ImgsDataDetail2,previewBigImg2,LookMaster2,addPartitionAttribute2, SixFamiliarityComponent, ActualCombatDrillComponent,routerMapComponent, SixFamiliarListComponent,TrainingRecordinfoComponent,RouterGISComponent,WaterRoadComponent,PhotoofthesceneComponent,KnowRouteComponent,FindProblemComponent,upname,companyAuditResult], + declarations: [KeyUnitManagementComponent, EditUnitInfoComponent, ViewUnitDetailsComponent,CreateUnit,BasicinfoComponent,LookMaster,AddHouseInfo, EditPlanInfoComponent,BasicinfoLookComponent, ViewUnitDetailsPlanComponent,FunctionDivisionComponent,addPartition,addPartitionAttribute,AllaroundComponent,ImgDetails,RealisticPictureComponent,previewImg,addRealPicture,editRealPicture,KeySiteComponent,KeyImgDetail,KeySiteImgs,UploadingCADComponent,readFile,editFile,KeySiteLookComponent,KeySiteImgs2,FunctionDivisionLookComponent,RealisticPictureLookComponent,previewImg3,UploadingCADLookComponent,FireFightingDeviceComponent,ImagesData,previewBigImg,ImgsDataDetail,FireFightingDeviceLookComponent,ImagesData2,ImgsDataDetail2,previewBigImg2,LookMaster2,addPartitionAttribute2, SixFamiliarityComponent, ActualCombatDrillComponent,routerMapComponent, SixFamiliarListComponent,TrainingRecordinfoComponent,RouterGISComponent,WaterRoadComponent,PhotoofthesceneComponent,KnowRouteComponent,FindProblemComponent,upname,companyAuditResult,StatisticsOfFireFightingFacilities], exports:[ViewUnitDetailsPlanComponent], imports: [ CommonModule,