diff --git a/src/app/plan-audit/wait-examineer/wait-examineer.component.ts b/src/app/plan-audit/wait-examineer/wait-examineer.component.ts
index 9f6da9a..ceca217 100644
--- a/src/app/plan-audit/wait-examineer/wait-examineer.component.ts
+++ b/src/app/plan-audit/wait-examineer/wait-examineer.component.ts
@@ -4,7 +4,7 @@
* @Author: sueRimn
* @Date: 2020-12-25 16:13:50
* @LastEditors: sueRimn
- * @LastEditTime: 2021-03-03 15:13:25
+ * @LastEditTime: 2021-03-10 08:36:31
*/
import { Component, Inject, OnInit } from '@angular/core';
import { FormControl } from '@angular/forms';
@@ -395,7 +395,9 @@ export class WaitExamineerComponent implements OnInit {
})
}
}
+ this.shenheTable=[]
}
+
}
//批量审核
else{
@@ -428,11 +430,11 @@ export class WaitExamineerComponent implements OnInit {
this.getAlltabledate()
})
}
-
+ this.shenheTable=[]
}
}
- this.shenheTable=[]
+
}
//拒绝操作
refuse(){
@@ -488,6 +490,7 @@ export class WaitExamineerComponent implements OnInit {
})
}
}
+ this.shenheTable=[]
}
}
//批量审核
@@ -521,9 +524,10 @@ export class WaitExamineerComponent implements OnInit {
this.getAlltabledate()
})
}
+ this.shenheTable=[]
}
}
- this.shenheTable=[]
+ //this.shenheTable=[]
}
diff --git a/src/app/statistic-analysis/addUnit/add-unit-one/add-unit-one.component.ts b/src/app/statistic-analysis/addUnit/add-unit-one/add-unit-one.component.ts
index c68811d..dac3d69 100644
--- a/src/app/statistic-analysis/addUnit/add-unit-one/add-unit-one.component.ts
+++ b/src/app/statistic-analysis/addUnit/add-unit-one/add-unit-one.component.ts
@@ -12,12 +12,16 @@ export class AddUnitOneComponent implements OnInit {
constructor(private router: Router,public echartsData:EchartsDataService) { }
setTimeoutObj//延时器需要清除
+ buildData=[]
+ orData
ngOnInit(): void {
+ /* this.buildData.push(this.echartsData.getData(null,`/api/StatisticsAnalysis/BuildingTypes`))
+ this.orData=this.echartsData.getData(null,`/api/StatisticsAnalysis/Companies`) */
this.setTimeoutObj = window.setTimeout(()=>{
this.initCharts("pieone")
this.initCharts("pietwo")
- },0)
+ },1000)
this.echartsData.eventEmit.subscribe((value: any) => {
if (value == 'echarts') {
setTimeout(() => {
@@ -42,6 +46,7 @@ export class AddUnitOneComponent implements OnInit {
indexBzt//首页饼状图实例
/* 首页饼状图 */
initCharts(id){
+
this.indexBzt = echarts.init(document.getElementById(id),'walden');
let options={
title: {
diff --git a/src/app/statistic-analysis/addUnit/add-unit-two-time/add-unit-two-time.component.html b/src/app/statistic-analysis/addUnit/add-unit-two-time/add-unit-two-time.component.html
index cb3ca61..37487ca 100644
--- a/src/app/statistic-analysis/addUnit/add-unit-two-time/add-unit-two-time.component.html
+++ b/src/app/statistic-analysis/addUnit/add-unit-two-time/add-unit-two-time.component.html
@@ -4,7 +4,7 @@
* @Author: sueRimn
* @Date: 2020-09-05 13:50:45
* @LastEditors: sueRimn
- * @LastEditTime: 2021-01-04 11:09:57
+ * @LastEditTime: 2021-03-10 15:19:25
-->
'
return this.res
- })
+
}
}
diff --git a/src/app/statistic-analysis/buildingType/building-type-three-details/building-type-three-details.component.ts b/src/app/statistic-analysis/buildingType/building-type-three-details/building-type-three-details.component.ts
index 6a9e16c..9be3fca 100644
--- a/src/app/statistic-analysis/buildingType/building-type-three-details/building-type-three-details.component.ts
+++ b/src/app/statistic-analysis/buildingType/building-type-three-details/building-type-three-details.component.ts
@@ -24,17 +24,34 @@ export class BuildingTypeThreeDetailsComponent implements OnInit {
}
organizationName:String
+ listorganizationId//上个页面传过来的组织id
buildingTypeName:String
+ buildingTypeId
+ organizationId=[]//本层id
ngOnInit(): void {
this.route.queryParams.subscribe(params => {
- this.tiaoshiPao=this.echartsData.qipao(this.tiaoshiPao,this.zhongNumData,this.zhongNameData)
this.organizationName = params['organizationName'];
this.buildingTypeName = params['buildingTypeName'];
+ this.listorganizationId=params['organizationId'];
+ this.buildingTypeId=params['buildId'];
});
+ let paramsdata={
+ id:this.buildingTypeId,
+ organizationId:this.listorganizationId
+ }
+ this.echartsData.getData(paramsdata,`/api/StatisticsAnalysis/Companies/BuildingTypes/${this.buildingTypeId}`)
window.setTimeout(()=>{
+ this.tabledata=JSON.parse(JSON.stringify(this.echartsData.allDate))
+ console.log(this.tabledata)
+ for(var i=0;i {
- this.router.navigate(['/statisticanalysis/CompangInfo'],{queryParams:{'name':params.name,'type':1}});
+ this.detailPlanEchart.getZr().on('click', (params) => {
+ const pointInPixel= [params.offsetX, params.offsetY];
+ if (this.detailPlanEchart.containPixel('grid',pointInPixel)) {
+ let xIndex=this.detailPlanEchart.convertFromPixel({seriesIndex:0},[params.offsetX, params.offsetY])[0];
+ /*事件处理代码书写位置*/
+ if(this.echartsData.level=="0"&&this.tiao==false&&this.tabledata[0].organizations.length>1){
+ //总队不跳转
+ console.log(params)
+ this.zhongNameData=[]
+ this.zhongNumData=[]
+ this.organizationId=[]
+ this.tiaoshiPao=''
+ let paramsdatee={
+ id:this.buildingTypeId,
+ organizationId:option.xAxis.id[xIndex]
+ }
+ this.echartsData.getData(paramsdatee,`/api/StatisticsAnalysis/Companies/BuildingTypes/${this.buildingTypeId}`)
+ window.setTimeout(()=>{
+ this.tabledata=JSON.parse(JSON.stringify(this.echartsData.allDate))
+ console.log(this.tabledata)
+ for(var i=0;i
'
res+='';
diff --git a/src/app/statistic-analysis/buildingType/building-type-two-reverse/building-type-two-reverse.component.ts b/src/app/statistic-analysis/buildingType/building-type-two-reverse/building-type-two-reverse.component.ts
index 3d7e65e..a0949f2 100644
--- a/src/app/statistic-analysis/buildingType/building-type-two-reverse/building-type-two-reverse.component.ts
+++ b/src/app/statistic-analysis/buildingType/building-type-two-reverse/building-type-two-reverse.component.ts
@@ -19,15 +19,29 @@ export class BuildingTypeTwoReverseComponent implements OnInit {
this.router.navigate(['/statisticanalysis/buildingType_one/buildingType_two_reverse'])
}
headname//标题
+ buildId//建筑id
ngOnInit(): void {
this.route.queryParams.subscribe(param=>{
this.headname=param.level
+ this.buildId=param.id
});
+ let paramsdata:any = {
+ id:this.buildId,
+ organizationId:'1'
+ }
+ this.data.getData(paramsdata,`/api/StatisticsAnalysis/Companies/BuildingTypes/${this.buildId}`)
window.setTimeout(()=>{
+ this.tabledata=JSON.parse(JSON.stringify(this.data.allDate))
+ for(var i=0;i{
- for(var i=0;i{return {name: v.buildingTypeName,value:v.count}})
- console.log(data)
this.forArr.forEach(item=>{
let _this = this
item.echart = echarts.init(document.getElementById('gaoceng'),'walden');
let option = {
title: {
- text: this.headname+':总数(1024)',
+ text: this.headname+this.tabledata[0].totalCount,
left: "center",
- top: "15",
- //bottom: '80',
+ //top: "12",
+ bottom: '510',
textStyle: {
fontSize: 30
}
},
+ grid: {
+ top: 90,
+ bottom: 30
+ },
xAxis: {
+ id:this.organizationId,
type: 'category',
data: this.zhiNameData,
axisLabel:{
@@ -290,7 +303,7 @@ export class BuildingTypeTwoReverseComponent implements OnInit {
data: this.zhiNumData,
type: 'bar',
markPoint: {
- data: this.tiaoshiPao
+ data:this.tiaoshiPao
},
//showBackground: true,
backgroundStyle: {
@@ -301,11 +314,24 @@ export class BuildingTypeTwoReverseComponent implements OnInit {
}]
};
item.echart.setOption(option);
- item.echart.on('click', (params) => {
- this.router.navigate(['/statisticanalysis/buildingType_one/buildingType_three_details'],{queryParams:{'organizationName':params.name,'buildingTypeName':this.headname}})
+ item.echart.getZr().on('click', (params) => {
+ const pointInPixel= [params.offsetX, params.offsetY];
+ if (item.echart.containPixel('grid',pointInPixel)) {
+ let xIndex=item.echart.convertFromPixel({seriesIndex:0},[params.offsetX, params.offsetY])[0];
+ /*事件处理代码书写位置*/
+ if(this.data.level=='0'||this.data.level=='1'){
+ //总队,支队跳转
+ this.router.navigate(['/statisticanalysis/buildingType_one/buildingType_three_details'],{queryParams:{'organizationName':option.xAxis.data[xIndex],'buildingTypeName':this.headname,'buildId':this.buildId,'organizationId':option.xAxis.id[xIndex]}})
+ }
+ else{
+ this.router.navigate(['/statisticanalysis/CompangInfo'],{queryParams:{'name':params.name,'type':1}});
+ }
+ //this.router.navigate(['/statisticanalysis/delete_one/delete_four'],{queryParams:{'level':this.option.xAxis.data[xIndex]+headName}});
+ }
+
});
})
- })
+
}
diff --git a/src/app/statistic-analysis/compang-info/compang-info.component.ts b/src/app/statistic-analysis/compang-info/compang-info.component.ts
index 73a020b..c314264 100644
--- a/src/app/statistic-analysis/compang-info/compang-info.component.ts
+++ b/src/app/statistic-analysis/compang-info/compang-info.component.ts
@@ -4,7 +4,7 @@
* @Author: sueRimn
* @Date: 2021-03-05 15:57:08
* @LastEditors: sueRimn
- * @LastEditTime: 2021-03-06 11:35:04
+ * @LastEditTime: 2021-03-10 17:02:33
*/
import { Component, OnInit, ViewChild, Inject } from '@angular/core';
import { HttpClient } from '@angular/common/http'
@@ -33,6 +33,7 @@ export class CompangInfoComponent implements OnInit{
this.route.queryParams.subscribe(params => {
this.titlename = params['name'];
this.type = params['type'];
+ this.jsId=params['jsid']
});
this.getAlltabledate()
}
@@ -40,7 +41,7 @@ export class CompangInfoComponent implements OnInit{
tabledataSource
titlename //上个页面传过来的名称
type //上个页面传过来:1重点单位 2预案
- jsId=1 //组织机构id
+ jsId //组织机构id
//分页
@ViewChild(MatPaginator, {static: true})
pageEvent: PageEvent;
diff --git a/src/app/statistic-analysis/echarts-data.service.ts b/src/app/statistic-analysis/echarts-data.service.ts
index f8fa6fa..57a7cf9 100644
--- a/src/app/statistic-analysis/echarts-data.service.ts
+++ b/src/app/statistic-analysis/echarts-data.service.ts
@@ -11,6 +11,7 @@ export class EchartsDataService {
this.allEcharts=this.http.get("/api/StatisticsAnalysis")
//return this.allEcharts.data
}
+ level = sessionStorage.getItem("level");
allEcharts
//计划首页
tableShow=false//控制首页表格显隐
@@ -405,38 +406,37 @@ export class EchartsDataService {
res
tishiData
biaogeTishiZhi(datas){
- let paramsdata:any = {
- BuildingTypeId:datas.id
+ for(var a in this.obdata[0].buildingTypes){
+ if(this.obdata[0].buildingTypes[a].buildingTypeId==datas.id){
+ this.tishiData=this.obdata[0].buildingTypes[a].organizations
+ }
}
- //var res
- this.http.get("/api/StatisticsAnalysis",{params:paramsdata}).subscribe((data:any)=>{
- this.tishiData=data
- console.log(this.tishiData)
-
- })
- this.res= ''+datas.name+'
'
+ console.log(this.tishiData)
+ var countall=0//总计
+ var countbi=0//站比
+ var allCountbi=0//总站比
+ for(var i=0;i
'
this.res+='';
this.res+='';
- this.res+='名称 | ';
this.res+='数量 | '
this.res+='总占比 | '
this.res+='
'
this.res+='';
- var countall=0
- for(var i=0;i'
- for(var i=0;i'
- this.res+=''+this.tishiData.companyStatistics.organizationStatistics.organizations[i].organizationName+' | '
- this.res+=''+this.tishiData.companyStatistics.organizationStatistics.organizations[i].count+' | '
- this.res+=''+Math.round(this.tishiData.companyStatistics.organizationStatistics.organizations[i].count/countall* 10000)/ 100.00 +'% | '
+ this.res+=''+this.tishiData[i].organizationName+' | '
+ this.res+=''+this.tishiData[i].count+' | '
+ this.res+=''+countbi+'% | '
}
this.res+=''
- this.res+='总计 | '+this.tishiData.companyStatistics.totalCount+' | 100% | '
+ this.res+='总计 | '+countall+' | '+allCountbi.toFixed(2)+'% | '
this.res+='
'
return this.res
@@ -444,6 +444,7 @@ export class EchartsDataService {
zhiNameData = ["浦东支队","黄浦支队","徐汇支队","长宁支队","静安支队","普陀支队","虹口支队","杨浦支队","闵行支队","宝山支队","嘉定支队","松江支队","金山支队","崇明支队"]
zhiNumData = [200,190,180,170,160,150,140,130,120,110,100,90,80,70]
+
/**
* @name: 气泡封装
@@ -468,10 +469,14 @@ export class EchartsDataService {
//获取所有数据
allDate=[]
- getData(paramsdata){
- this.http.get("/api/StatisticsAnalysis",{params:paramsdata}).subscribe((data:any)=>{
+ obdata
+ getData(paramsdata,api){
+ this.allDate=[]
+ this.obdata=null
+ this.http.get(api,{params:paramsdata}).subscribe((data:any)=>{
this.allDate.push(data)
- console.log(this.allDate)
+ this.obdata=JSON.parse(JSON.stringify(this.allDate))
+ console.log(this.obdata)
return this.allDate
})
}
diff --git a/src/app/statistic-analysis/state/page-one/page-one.component.ts b/src/app/statistic-analysis/state/page-one/page-one.component.ts
index e7a9efc..8ad2a7c 100644
--- a/src/app/statistic-analysis/state/page-one/page-one.component.ts
+++ b/src/app/statistic-analysis/state/page-one/page-one.component.ts
@@ -4,7 +4,7 @@
* @Author: sueRimn
* @Date: 2020-09-01 15:24:39
* @LastEditors: sueRimn
- * @LastEditTime: 2020-12-30 14:06:07
+ * @LastEditTime: 2021-03-10 14:50:23
*/
import { Component, OnInit } from '@angular/core';
import { Router } from '@angular/router';
@@ -22,9 +22,10 @@ export class PageOneComponent implements OnInit {
constructor(private router: Router,public echartsData:EchartsDataService) { }
ngOnInit() {
+ this.echartsData.getData(null,`/api/StatisticsAnalysis/Plans`)
window.setTimeout(()=>{
this.initCharts()
- },0)
+ },1000)
}
ngOnDestroy(): void {
this.indexBzt.clear()
@@ -34,12 +35,18 @@ export class PageOneComponent implements OnInit {
/* 首页饼状图 */
indexBzt
+ tabledata
+ count
+ indexData
initCharts(){
+ this.tabledata=JSON.parse(JSON.stringify(this.echartsData.allDate))
+ console.log(this.tabledata)
+
var ec = echarts as any;
this.indexBzt = ec.init(document.getElementById('indexBzt'),'walden');
var options={
title: {
- text: '预案状态统计(7005家)',
+ text: `预案状态统计(${this.tabledata[0].totalCount}份)`,
top: "7%",
left: 'center',
textStyle:{
@@ -48,9 +55,10 @@ export class PageOneComponent implements OnInit {
},
tooltip: {
trigger: 'item',
- formatter: (params)=>{
- return this.echartsData.biaogeTishiZhi(params.name)
- }
+ /* formatter: (params)=>{
+ console.log(params)
+ return this.echartsData.biaogeTishiZhi(params.data)
+ } */
},
legend: {
orient: 'vertical',
@@ -86,11 +94,11 @@ export class PageOneComponent implements OnInit {
},
data: [
- {value: 1585, name: '预案新增'},
- {value: 2000, name: '预案审核通过',itemStyle:{color:'#02A7F0'}},
- {value: 2600, name: '预案编制'},
- {value: 1500, name: '预案审核退回'},
- {value: 1800, name: '预案审核中'}
+ {value: 45, name: '预案新增'},
+ {value: this.tabledata[0].planningStatistics.approvedCount, name: '预案审核通过',itemStyle:{color:'#02A7F0'}},
+ {value: 37, name: '预案编制'},
+ {value: this.tabledata[0].planningStatistics.rejectedCount, name: '预案审核退回'},
+ {value: this.tabledata[0].planningStatistics.auditingCount, name: '预案审核中'}
],
emphasis: {
itemStyle: {
diff --git a/src/app/statistic-analysis/state/page-two-name/page-two-name.component.ts b/src/app/statistic-analysis/state/page-two-name/page-two-name.component.ts
index db54f9c..517ff40 100644
--- a/src/app/statistic-analysis/state/page-two-name/page-two-name.component.ts
+++ b/src/app/statistic-analysis/state/page-two-name/page-two-name.component.ts
@@ -88,7 +88,7 @@ export class PageTwoNameComponent implements OnInit {
this.addEchart = echarts.init(document.getElementById('pie'),'walden');
var option = {
title: {
- text: _this.headname+"总数(1024)",
+ text: _this.headname+"总数(102)",
left: "center",
top: "0",
bottom: '100%',
diff --git a/src/app/statistic-analysis/state/page-two-time/page-two-time.component.html b/src/app/statistic-analysis/state/page-two-time/page-two-time.component.html
index 7cbd5ce..f5a6284 100644
--- a/src/app/statistic-analysis/state/page-two-time/page-two-time.component.html
+++ b/src/app/statistic-analysis/state/page-two-time/page-two-time.component.html
@@ -4,7 +4,7 @@
* @Author: sueRimn
* @Date: 2020-09-05 08:59:24
* @LastEditors: sueRimn
- * @LastEditTime: 2021-01-04 11:15:39
+ * @LastEditTime: 2021-03-10 15:16:52
-->