update code

dev-login
haha 2023-09-10 00:56:59 +08:00
parent db3b88db30
commit 5f33fc5fc5
13 changed files with 517 additions and 259 deletions

View File

@ -13,7 +13,11 @@
<script src="https://cdn.makalu.cc/js/vue/vue.js"></script> <script src="https://cdn.makalu.cc/js/vue/vue.js"></script>
<script src="https://unpkg.com/element-ui@2.15.13/lib/index.js"></script> <script src="https://unpkg.com/element-ui@2.15.13/lib/index.js"></script>
<script src="https://cdn.makalu.cc/js/jquery/3.5.1/jquery.min.js"></script> <script src="https://cdn.makalu.cc/js/jquery/3.5.1/jquery.min.js"></script>
<script crossorigin="anonymous" integrity="sha384-gb8mitZ44MWVFB3GKzmtx1OCjOh3Cj4mgusyTvNzl1Nu31l0em1FrApJindwVAe0" src="https://lib.baomitu.com/echarts/4.2.1/echarts.min.js"></script> <script src="./js/echarts.min.js"></script>
<!--
<script crossorigin="anonymous" integrity="sha384-gb8mitZ44MWVFB3GKzmtx1OCjOh3Cj4mgusyTvNzl1Nu31l0em1FrApJindwVAe0"
src="https://lib.baomitu.com/echarts/4.2.1/echarts.min.js"></script>
-->
<script src="https://cdn.makalu.cc/js/echarts/china.js"></script> <script src="https://cdn.makalu.cc/js/echarts/china.js"></script>
<script type="text/javascript" src="https://api.map.baidu.com/api?v=1.0&&type=webgl&ak=6zAD8CIavtzWnkGg0a7roush5maGMIPn"></script> <script type="text/javascript" src="https://api.map.baidu.com/api?v=1.0&&type=webgl&ak=6zAD8CIavtzWnkGg0a7roush5maGMIPn"></script>
<style type="text/css"> <style type="text/css">

45
public/js/echarts.min.js vendored 100644

File diff suppressed because one or more lines are too long

View File

@ -17,6 +17,7 @@ import materialSeal from './materialSeal/index'
import costOut from './costOut/index' import costOut from './costOut/index'
import checkDetection from './checkDetection/index' import checkDetection from './checkDetection/index'
import video from './video/index' import video from './video/index'
import plan from './plan/index'
import {axios,download} from '@/utils/request' import {axios,download} from '@/utils/request'
export default { export default {
project, project,
@ -39,5 +40,6 @@ export default {
checkDetection, checkDetection,
http:axios, http:axios,
video, video,
plan,
downFile:download downFile:download
} }

View File

@ -0,0 +1,21 @@
import request from '@/utils/request'
const listAllTop3=()=>{
return request({
url: `bgscreen/projectPlan/listAllTop3`,
method: 'get'
})
}
const listAll=(type)=>{
return request({
url: `bgscreen/projectPlan/listAll/${type}`,
method: 'get'
})
}
export default{
listAllTop3,
listAll
}

View File

@ -33,9 +33,13 @@ Vue.component("staff-survey-chart", {
init(){ init(){
this.getChartData() this.getChartData()
}, },
chartClick(p){
this.$emit("chart-click",p);
},
getChartData(){ getChartData(){
//品类金额占比 饼图 //品类金额占比 饼图
var chChart = echarts.init(this.$refs.chart); var chChart = echarts.init(this.$refs.chart);
chChart.on("click",this.chartClick)
this.echart(chChart,this.data) this.echart(chChart,this.data)
}, },
echart(chChart,chartData){ echart(chChart,chartData){
@ -93,6 +97,7 @@ Vue.component("staff-survey-chart", {
], ],
yAxis: [ yAxis: [
{ {
triggerEvent:true,
type: 'category', type: 'category',
axisLabel: { axisLabel: {
show: false, //让Y轴数据不显示 show: false, //让Y轴数据不显示
@ -108,6 +113,7 @@ Vue.component("staff-survey-chart", {
}, },
data: [], data: [],
},{ },{
triggerEvent:true,
show: false, show: false,
data: [], data: [],
axisLine: { axisLine: {

View File

@ -2,7 +2,7 @@
<div class="my-dialog"> <div class="my-dialog">
<transition name="el-zoom-in-top"> <transition name="el-zoom-in-top">
<div class="popup-project-introduction-max" v-show="showDlg"> <div class="popup-project-introduction-max" v-show="showDlg">
<div class="popup-project-introduction-min" :style="{ 'width': width, 'height': height }"> <div class="popup-project-introduction-min" :style="{ 'width': width, 'height': height }" v-loading="loading">
<div class="popup-project-introduction-con"> <div class="popup-project-introduction-con">
<div class="popup-project-introduction-title"> <div class="popup-project-introduction-title">
<div style="width: 100%;"> <div style="width: 100%;">
@ -43,6 +43,10 @@ export default {
className:{ className:{
type:String, type:String,
default:'', default:'',
},
loading:{
type:Boolean,
default:false,
} }
}, },
data() { data() {

View File

@ -29,16 +29,18 @@
:maintitle="overviewTotal" :legend-opt="legendOpt1" :typedata="typeDistributionData" :maintitle="overviewTotal" :legend-opt="legendOpt1" :typedata="typeDistributionData"
:text="overviewText" :height="230"></project-overview-chart> :text="overviewText" :height="230"></project-overview-chart>
<rank-chart :data="availabilityData" :showval="true" :height="300" :width="projectCategoryWidth"></rank-chart> <rank-chart :data="availabilityData" :showval="true" :height="300"
:width="projectCategoryWidth"></rank-chart>
</module-one-2-1> </module-one-2-1>
<module-one-1-1 label="安全/质量管理" > <module-one-1-1 label="安全/质量管理">
<div class="warning-info-title" style="padding-left: 20px;" > <div class="warning-info-title" style="padding-left: 20px;">
<div :class="qualityNav == 0 ? 'active' : ''" @click="qualityNavClick(0)"></div> <div :class="qualityNav == 0 ? 'active' : ''" @click="qualityNavClick(0)"></div>
<div :class="qualityNav == 1 ? 'active' : ''" @click="qualityNavClick(1)"></div> <div :class="qualityNav == 1 ? 'active' : ''" @click="qualityNavClick(1)"></div>
</div> </div>
<project-overview-chart :sp="'\n'" :maintitle="qualityNavTotal" :legend-opt="legendOpt2" :key="elKey" <project-overview-chart :sp="'\n'" :maintitle="qualityNavTotal" :legend-opt="legendOpt2"
:typedata="dangersDatas" :text="qualityNavTitle" :height="220" style="top:0px"></project-overview-chart> :key="elKey" :typedata="dangersDatas" :text="qualityNavTitle" :height="220"
style="top:0px"></project-overview-chart>
</module-one-1-1> </module-one-1-1>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
@ -75,13 +77,17 @@
<el-col :span="12" style="position: relative;"> <el-col :span="12" style="position: relative;">
<module-one-1-1 label="项目进度汇总"> <module-one-1-1 label="项目进度汇总">
<img src="images/icon2001.png" <img src="images/icon2001.png"
style="position: absolute;cursor: pointer;right: 13px;top: 12px;" @click="doShowDlg2"> style="position: absolute;cursor: pointer;right: 13px;top: 12px;"
@click="doShowDlg2">
<div class="warning-info-title" style="padding-left: 20px;"> <div class="warning-info-title" style="padding-left: 20px;">
<div :class="prjProcessNav == 1 ? 'active' : ''" @click="doPrjProcess(1, '在建项目')">在建项目({{ getPrjCateCount(0) }}) <div :class="prjProcessNav == 1 ? 'active' : ''" @click="doPrjProcess(1, '在建项目')">
在建项目({{ getPrjCateCount(0) }})
</div> </div>
<div :class="prjProcessNav == 2 ? 'active' : ''" @click="doPrjProcess(2, '拟建项目')">拟建项目({{ getPrjCateCount(1) }}) <div :class="prjProcessNav == 2 ? 'active' : ''" @click="doPrjProcess(2, '拟建项目')">
拟建项目({{ getPrjCateCount(1) }})
</div> </div>
<div :class="prjProcessNav == 4 ? 'active' : ''" @click="doPrjProcess(4, '完成项目')">完成项目({{ getPrjCateCount(3) }}) <div :class="prjProcessNav == 4 ? 'active' : ''" @click="doPrjProcess(4, '完成项目')">
完成项目({{ getPrjCateCount(3) }})
</div> </div>
</div> </div>
<el-row> <el-row>
@ -136,7 +142,7 @@
</el-col> </el-col>
<el-col :span="16" :key="elSumKey"> <el-col :span="16" :key="elSumKey">
<staff-survey-chart :height="220" :unit="'个'" :data="prjPrcessData" <staff-survey-chart :height="220" :unit="'个'" :data="prjPrcessData"
:width="140"></staff-survey-chart> :width="140" @chart-click="planSummaryChartClick"></staff-survey-chart>
</el-col> </el-col>
</el-row> </el-row>
</module-one-1-1> </module-one-1-1>
@ -147,12 +153,12 @@
<el-col :span="6"> <el-col :span="6">
<module-one-1-1 label="集团新闻"> <module-one-1-1 label="集团新闻">
<el-carousel> <el-carousel>
<el-carousel-item v-for="(item,idx) in JournalismList" :key="idx"> <el-carousel-item v-for="(item, idx) in JournalismList" :key="idx">
<div style="height: 94%;text-align: center;" @click="handJournalism(item)"> <div style="height: 94%;text-align: center;" @click="handJournalism(item)">
<img :src="$apiPath + item.mainImage+'.min.jpg'" style="width: 99%;height: 100%;"> <img :src="$apiPath + item.mainImage + '.min.jpg'" style="width: 99%;height: 100%;">
</div> </div>
<div style="text-align: center;font-size: 12px;line-height: 32px;margin-top: -32px;"> <div style="text-align: center;font-size: 12px;line-height: 32px;margin-top: -32px;">
{{item.title}} {{ item.title }}
</div> </div>
</el-carousel-item> </el-carousel-item>
</el-carousel> </el-carousel>
@ -160,47 +166,53 @@
<module-one-1-1 label="成本管理" :key="elKey"> <module-one-1-1 label="成本管理" :key="elKey">
<div class="glr-max cost-out" style="position: relative;"> <div class="glr-max cost-out" style="position: relative;">
<div class="glr-min"> <div class="glr-min">
<div class="glr-title">开累产值</div> <div class="glr-title">开累产值</div>
<div class="labour-education" > <div class="labour-education">
<div style="transform: scale(0.8);margin-left:-20px"> <div style="transform: scale(0.8);margin-left:-20px">
<people-number :number="numberWithCommas((sumCost.totalMonth*1.0||0).toFixed(2))||'0.00'" unit="万元"></people-number> <people-number
:number="numberWithCommas((sumCost.totalMonth * 1.0 || 0).toFixed(2)) || '0.00'"
unit="万元"></people-number>
</div>
<div class="survey_content" style="position: absolute;right: 15px;top: -4px;">
<div class="survey_content_img labour-education_bgd">
<svg class="my-svg-icon"
style="vertical-align: middle;fill: currentColor;overflow: hidden;"
viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg"
p-id="16007">
<path
d="M544.853333 545.322667v54.826666h100.053334a33.749333 33.749333 0 1 1 0 67.541334h-99.989334v91.648a33.749333 33.749333 0 0 1-67.52 0v-91.648h-98.282666a33.749333 33.749333 0 0 1 0-67.52h98.282666v-54.848h-98.282666a33.749333 33.749333 0 0 1 0-67.52h76.565333l-90.176-151.658667a33.856 33.856 0 0 1 58.133333-34.453333l88.298667 148.501333 88.362667-148.501333a33.856 33.856 0 0 1 58.069333 34.453333l-90.176 151.68h76.693333a33.749333 33.749333 0 0 1 0 67.498667H544.853333zM512 110.186667a400 400 0 0 0-284.16 117.674666A400.426667 400.426667 0 0 0 110.208 512a400 400 0 0 0 117.674667 284.16A400.426667 400.426667 0 0 0 512 913.792a400 400 0 0 0 284.16-117.674667A400.426667 400.426667 0 0 0 913.792 512a400 400 0 0 0-117.653333-284.16A400.426667 400.426667 0 0 0 512 110.208zM512 42.666667c259.2 0 469.333333 210.133333 469.333333 469.333333s-210.133333 469.333333-469.333333 469.333333S42.666667 771.2 42.666667 512 252.8 42.666667 512 42.666667z"
fill="#8A8A8A" p-id="16008"></path>
</svg>
</div> </div>
<div class="survey_content" style="position: absolute;right: 15px;top: -4px;"> </div>
<div class="survey_content_img labour-education_bgd"> </div>
<svg class="my-svg-icon"
style="vertical-align: middle;fill: currentColor;overflow: hidden;"
viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg"
p-id="16007">
<path
d="M544.853333 545.322667v54.826666h100.053334a33.749333 33.749333 0 1 1 0 67.541334h-99.989334v91.648a33.749333 33.749333 0 0 1-67.52 0v-91.648h-98.282666a33.749333 33.749333 0 0 1 0-67.52h98.282666v-54.848h-98.282666a33.749333 33.749333 0 0 1 0-67.52h76.565333l-90.176-151.658667a33.856 33.856 0 0 1 58.133333-34.453333l88.298667 148.501333 88.362667-148.501333a33.856 33.856 0 0 1 58.069333 34.453333l-90.176 151.68h76.693333a33.749333 33.749333 0 0 1 0 67.498667H544.853333zM512 110.186667a400 400 0 0 0-284.16 117.674666A400.426667 400.426667 0 0 0 110.208 512a400 400 0 0 0 117.674667 284.16A400.426667 400.426667 0 0 0 512 913.792a400 400 0 0 0 284.16-117.674667A400.426667 400.426667 0 0 0 913.792 512a400 400 0 0 0-117.653333-284.16A400.426667 400.426667 0 0 0 512 110.208zM512 42.666667c259.2 0 469.333333 210.133333 469.333333 469.333333s-210.133333 469.333333-469.333333 469.333333S42.666667 771.2 42.666667 512 252.8 42.666667 512 42.666667z"
fill="#8A8A8A" p-id="16008"></path>
</svg>
</div>
</div>
</div>
<div class="glr-title">年度产值</div> <div class="glr-title">年度产值</div>
<div class="labour-education" > <div class="labour-education">
<div style="transform: scale(0.8);margin-left:-20px"> <div style="transform: scale(0.8);margin-left:-20px">
<people-number :number="numberWithCommas((sumCost.curYear*1.0||0).toFixed(2))||'0.00'" unit="万元"></people-number> <people-number
</div> :number="numberWithCommas((sumCost.curYear * 1.0 || 0).toFixed(2)) || '0.00'"
</div> unit="万元"></people-number>
</div>
</div>
<div class="glr-title">月度产值</div>
<div class="labour-education">
<div style="transform: scale(0.8);margin-left:-20px">
<people-number
:number="numberWithCommas((sumCost.curMonth * 1.0 || 0).toFixed(2)) || '0.00'"
unit="万元"></people-number>
</div>
</div>
<div class="glr-title">月度产值</div>
<div class="labour-education" >
<div style="transform: scale(0.8);margin-left:-20px">
<people-number :number="numberWithCommas((sumCost.curMonth*1.0||0).toFixed(2))||'0.00'" unit="万元"></people-number>
</div>
</div>
</div> </div>
</div> </div>
</module-one-1-1> </module-one-1-1>
<module-one-1-1 label="项目监测预警"> <module-one-1-1 label="项目监测预警">
<MonitAndWarning></MonitAndWarning> <MonitAndWarning></MonitAndWarning>
</module-one-1-1> </module-one-1-1>
</el-col> </el-col>
</el-row> </el-row>
@ -240,10 +252,10 @@ export default {
}, },
data() { data() {
return { return {
elDeptWorks:0, elDeptWorks: 0,
prj:{}, prj: {},
prjs:[], prjs: [],
elSumKey:0, elSumKey: 0,
elKey: 0, elKey: 0,
prjInfo: {}, prjInfo: {},
loading: true, loading: true,
@ -263,12 +275,12 @@ export default {
}, },
}, },
}, },
legendOpt2: { legendOpt2: {
icon: "rect", icon: "rect",
orient: "horizontal", orient: "horizontal",
left:'50%', left: '50%',
top:'top', top: 'top',
itemGap:0, itemGap: 0,
textStyle: { textStyle: {
fontSize: 14, fontSize: 14,
rich: { rich: {
@ -303,8 +315,8 @@ export default {
], ],
// //
qualityNav: 0, qualityNav: 0,
qualityNavTitle:'', qualityNavTitle: '',
qualityNavTotal:0, qualityNavTotal: 0,
// //
infoNav: 0, infoNav: 0,
staffText: '在岗人员', staffText: '在岗人员',
@ -440,50 +452,50 @@ export default {
// //
warningInterval: undefined, warningInterval: undefined,
forIndex: 0, forIndex: 0,
projectCategory:[], projectCategory: [],
projectCategoryWidth:200, projectCategoryWidth: 200,
deptInfo:{}, deptInfo: {},
JournalismList:[], JournalismList: [],
sumCost:{}, sumCost: {},
} }
}, },
created() { created() {
this.init() this.init()
}, },
mounted() { mounted() {
window.xapp=this; window.xapp = this;
this.$nextTick(() => { this.$nextTick(() => {
this.loading = true; this.loading = true;
}); });
this.$bus.$on("loadProjects", prjs => { this.$bus.$on("loadProjects", prjs => {
this.prjs = prjs; this.prjs = prjs;
if(this.prj.id==0){ if (this.prj.id == 0) {
this.prjInfo=this.prjs[1]; this.prjInfo = this.prjs[1];
} }
}); });
this.$bus.$on("projectChange", res => { this.$bus.$on("projectChange", res => {
if(res.id==0){ if (res.id == 0) {
const func=()=>{ const func = () => {
if(this.prjs && this.prjs.length>1){ if (this.prjs && this.prjs.length > 1) {
this.prjInfo = this.prjs[1]; this.prjInfo = this.prjs[1];
}else{ } else {
setTimeout(func,100); setTimeout(func, 100);
} }
} }
func(); func();
}else{ } else {
this.prjInfo = res; this.prjInfo = res;
} }
this.prj=res; this.prj = res;
this.investmentAmountData1[0].value = "" + res.paidAmount * 1.0; this.investmentAmountData1[0].value = "" + res.paidAmount * 1.0;
this.investmentAmountData2[0].value = "" + res.onAccountAmount * 1.0; this.investmentAmountData2[0].value = "" + res.onAccountAmount * 1.0;
this.elKey++; this.elKey++;
this.onWarningInfoNav(0); this.onWarningInfoNav(0);
this.sumCostOutByDeptId(); this.sumCostOutByDeptId();
}); });
this.$bus.$on("deptChange",dept=>{ this.$bus.$on("deptChange", dept => {
this.deptInfo=dept; this.deptInfo = dept;
this.groupByProjectCategory(dept.id); this.groupByProjectCategory(dept.id);
this.onClickoOverview(0) this.onClickoOverview(0)
this.qualityNavClick(0); this.qualityNavClick(0);
@ -491,77 +503,95 @@ export default {
this.sumCostOutByDeptId(); this.sumCostOutByDeptId();
}); });
}, },
methods: { methods: {
sumCostOutByDeptId(){ planSummaryChartClick(p){
let dt=this.$dt(new Date()); let idx=0;
let postData={ if(p.event.target.parent.style && p.event.target.parent.style.text){
year:dt.$y, if(p.event.target.parent.style.text.includes("正常推进项目")){
month:dt.$M+1 idx=2;
}
if(p.event.target.parent.style.text.includes("进度滞后项目")){
idx=1;
}
}else{
idx=p.seriesIndex;
}
if(idx==1||idx==2){
this.$refs.dlg2.showDetailDialog(this.prjProcessNav,idx);
}
},
sumCostOutByDeptId() {
let dt = this.$dt(new Date());
let postData = {
year: dt.$y,
month: dt.$M + 1
}; };
if(this.prj && this.prj.id>0){ if (this.prj && this.prj.id > 0) {
postData.projectId=this.prj.id; postData.projectId = this.prj.id;
}else{ } else {
postData.id=this.deptInfo.id; postData.id = this.deptInfo.id;
} }
if(this.callSumCostTime){ if (this.callSumCostTime) {
if(+new Date() - this.callSumCostTime <400){ if (+new Date() - this.callSumCostTime < 400) {
return; return;
} }
} }
this.callSumCostTime=+new Date(); this.callSumCostTime = +new Date();
this.$api.costOut.sumByDeptId(postData).then(d=>{ this.$api.costOut.sumByDeptId(postData).then(d => {
this.sumCost=d; this.sumCost = d;
}); });
}, },
qualityNavClick(n){ qualityNavClick(n) {
this.qualityNav=n; this.qualityNav = n;
if(n==0){ if (n == 0) {
this.qualityNavTitle="安全隐患总数"; this.qualityNavTitle = "安全隐患总数";
let postData={ let postData = {
deptId:this.deptInfo?.id||0, deptId: this.deptInfo?.id || 0,
roleType:0 roleType: 0
}; };
this.$api.problemmodify.safetySummary(postData).then(d=>{ this.$api.problemmodify.safetySummary(postData).then(d => {
this.dangersDatas=(d||[]).map(it=>{ this.dangersDatas = (d || []).map(it => {
return { return {
text:it.problemArea, text: it.problemArea,
prop:'0.0', prop: '0.0',
name:it.problemArea, name: it.problemArea,
value:+it.roleType||0 value: +it.roleType || 0
} }
}); });
let sum=0; let sum = 0;
this.dangersDatas.forEach(it=>{ this.dangersDatas.forEach(it => {
sum+=it.value*1; sum += it.value * 1;
}) })
this.qualityNavTotal=sum; this.qualityNavTotal = sum;
this.elKey++; this.elKey++;
}) })
}else{ } else {
let postData={ let postData = {
deptId:this.deptInfo?.id||0, deptId: this.deptInfo?.id || 0,
roleType:0 roleType: 0
}; };
this.qualityNavTitle="质量隐患总数"; this.qualityNavTitle = "质量隐患总数";
this.$api.problemmodify.qualitySummary(postData).then(d=>{ this.$api.problemmodify.qualitySummary(postData).then(d => {
this.dangersDatas=(d||[]).map(it=>{ this.dangersDatas = (d || []).map(it => {
return { return {
text:it.problemArea, text: it.problemArea,
prop:'0.0', prop: '0.0',
name:it.problemArea, name: it.problemArea,
value:+it.roleType||0 value: +it.roleType || 0
} }
}); });
let sum=0; let sum = 0;
this.dangersDatas.forEach(it=>{ this.dangersDatas.forEach(it => {
sum+=it.value*1; sum += it.value * 1;
}) })
this.qualityNavTotal=sum; this.qualityNavTotal = sum;
this.elKey++; this.elKey++;
}) })
} }
}, },
numberWithCommas(x) { numberWithCommas(x) {
x = x.toString(); x = x.toString();
var pattern = /(-?\d+)(\d{3})/; var pattern = /(-?\d+)(\d{3})/;
@ -576,36 +606,36 @@ export default {
this.$refs.dlg1.showDialog() this.$refs.dlg1.showDialog()
}, },
doShowDlg2() { doShowDlg2() {
this.$refs.dlg2.showDialog(this.prjProcessNav,[this.getPrjCateCount(0),this.getPrjCateCount(1),this.getPrjCateCount(3)]) this.$refs.dlg2.showDialog(this.prjProcessNav, [this.getPrjCateCount(0), this.getPrjCateCount(1), this.getPrjCateCount(3)])
}, },
getPrjCateCount(n){ getPrjCateCount(n) {
if(this.projectCategory.length<n+1){ if (this.projectCategory.length < n + 1) {
return 0;
}
let tmps=this.projectCategory[n];
if(tmps && tmps.length>0){
let sum=0;
tmps.forEach(d=>{
sum+=d.cnt;
})
return sum;
}
return 0; return 0;
}, }
groupByProjectCategory(deptId){ let tmps = this.projectCategory[n];
this.$api.project.groupByProjectCategory(deptId,datas=>{ if (tmps && tmps.length > 0) {
this.projectCategory=datas; let sum = 0;
this.prjPrcessTotal=this.getPrjCateCount(0); tmps.forEach(d => {
let item=this.projectCategory.length>0?this.projectCategory[0]:null; sum += d.cnt;
this.prjPrcessData[0].value=item && item.length>0?item[0].cnt:0; })
this.prjPrcessData[1].value=item && item.length>1?item[1].cnt:0; return sum;
}
return 0;
},
groupByProjectCategory(deptId) {
this.$api.project.groupByProjectCategory(deptId, datas => {
this.projectCategory = datas;
this.prjPrcessTotal = this.getPrjCateCount(0);
let item = this.projectCategory.length > 0 ? this.projectCategory[0] : null;
this.prjPrcessData[0].value = item && item.length > 0 ? item[0].cnt : 0;
this.prjPrcessData[1].value = item && item.length > 1 ? item[1].cnt : 0;
this.doPrjProcess(1, '在建项目'); this.doPrjProcess(1, '在建项目');
this.elKey++; this.elKey++;
}); });
}, },
init() { init() {
this.localStorage = JSON.parse(localStorage.getItem("data1")) this.localStorage = JSON.parse(localStorage.getItem("data1"))
// //
@ -617,23 +647,23 @@ export default {
// //
this.warningInterval = setInterval(this.automaticRoll, 5000); this.warningInterval = setInterval(this.automaticRoll, 5000);
this.getJournalismList(); this.getJournalismList();
setInterval(this.getDeptWorksList, 600000); setInterval(this.getDeptWorksList, 600000);
setInterval(this.getJournalismList, 600000); setInterval(this.getJournalismList, 600000);
}, },
doPrjProcess(n, text) { doPrjProcess(n, text) {
this.prjProcessNav = n; this.prjProcessNav = n;
this.prjPrcessText = text; this.prjPrcessText = text;
n--; n--;
this.prjPrcessTotal=this.getPrjCateCount(n); this.prjPrcessTotal = this.getPrjCateCount(n);
let item=this.projectCategory.length>n?this.projectCategory[n]:null; let item = this.projectCategory.length > n ? this.projectCategory[n] : null;
this.prjPrcessData[0].value=item && item.length>0?item[0].cnt:0; this.prjPrcessData[0].value = item && item.length > 0 ? item[0].cnt : 0;
this.prjPrcessData[1].value=item && item.length>1?item[1].cnt:0; this.prjPrcessData[1].value = item && item.length > 1 ? item[1].cnt : 0;
this.elSumKey++; this.elSumKey++;
}, },
// //
onWarningInfoNav(n) { onWarningInfoNav(n) {
this.infoNav = n this.infoNav = n
this.staffText = n==0?'在岗人数':'今日出勤' this.staffText = n == 0 ? '在岗人数' : '今日出勤'
if (n == 0) { if (n == 0) {
this.surveyUrl = 'images/survey_icon_4.png' this.surveyUrl = 'images/survey_icon_4.png'
} else { } else {
@ -642,50 +672,50 @@ export default {
this.getDeptWorksList(); this.getDeptWorksList();
}, },
// //
getDeptWorksList(){ getDeptWorksList() {
let deptId = this.deptInfo?.id||0; let deptId = this.deptInfo?.id || 0;
if (this.infoNav == 0) { if (this.infoNav == 0) {
// //
this.$api.attendance.getDeptWorksList(deptId,this.prj.id).then(d => { this.$api.attendance.getDeptWorksList(deptId, this.prj.id).then(d => {
this.laborPersonnelTotal=0; this.laborPersonnelTotal = 0;
this.laborPersonnelData=[{text: "劳务人员", value: 0},{text: "监理人员", value: 0},{text: "总包人员", value: 0}]; this.laborPersonnelData = [{ text: "劳务人员", value: 0 }, { text: "监理人员", value: 0 }, { text: "总包人员", value: 0 }];
if(d.rows.length>0 && d.rows[0]!=null){ if (d.rows.length > 0 && d.rows[0] != null) {
this.laborPersonnelData=[]; this.laborPersonnelData = [];
this.laborPersonnelTotal += d.rows[0].servicePersonnel; this.laborPersonnelTotal += d.rows[0].servicePersonnel;
this.laborPersonnelData.push({text: "劳务人员", value: d.rows[0].servicePersonnel}); this.laborPersonnelData.push({ text: "劳务人员", value: d.rows[0].servicePersonnel });
this.laborPersonnelTotal += d.rows[0].supervisorPersonnel; this.laborPersonnelTotal += d.rows[0].supervisorPersonnel;
this.laborPersonnelData.push({text: "监理人员", value: d.rows[0].supervisorPersonnel}); this.laborPersonnelData.push({ text: "监理人员", value: d.rows[0].supervisorPersonnel });
this.laborPersonnelTotal += d.rows[0].contractorPersonnel; this.laborPersonnelTotal += d.rows[0].contractorPersonnel;
this.laborPersonnelData.push({text: "总包人员", value: d.rows[0].contractorPersonnel}); this.laborPersonnelData.push({ text: "总包人员", value: d.rows[0].contractorPersonnel });
} }
this.elDeptWorks++; this.elDeptWorks++;
}); });
} else { } else {
// //
this.$api.attendance.getWorkAttendanceList(deptId).then(d => { this.$api.attendance.getWorkAttendanceList(deptId).then(d => {
this.laborPersonnelTotal=0; this.laborPersonnelTotal = 0;
this.laborPersonnelData=[{text: "劳务人员", value: 0},{text: "监理人员", value: 0},{text: "总包人员", value: 0}]; this.laborPersonnelData = [{ text: "劳务人员", value: 0 }, { text: "监理人员", value: 0 }, { text: "总包人员", value: 0 }];
if(d.rows.length>0 && d.rows[0]!=null){ if (d.rows.length > 0 && d.rows[0] != null) {
this.laborPersonnelData=[]; this.laborPersonnelData = [];
this.laborPersonnelTotal += d.rows[0].servicePersonnel; this.laborPersonnelTotal += d.rows[0].servicePersonnel;
this.laborPersonnelData.push({text: "劳务人员", value: d.rows[0].servicePersonnel}); this.laborPersonnelData.push({ text: "劳务人员", value: d.rows[0].servicePersonnel });
this.laborPersonnelTotal += d.rows[0].supervisorPersonnel; this.laborPersonnelTotal += d.rows[0].supervisorPersonnel;
this.laborPersonnelData.push({text: "监理人员", value: d.rows[0].supervisorPersonnel}); this.laborPersonnelData.push({ text: "监理人员", value: d.rows[0].supervisorPersonnel });
this.laborPersonnelTotal += d.rows[0].contractorPersonnel; this.laborPersonnelTotal += d.rows[0].contractorPersonnel;
this.laborPersonnelData.push({text: "总包人员", value: d.rows[0].contractorPersonnel}); this.laborPersonnelData.push({ text: "总包人员", value: d.rows[0].contractorPersonnel });
} }
this.elDeptWorks++; this.elDeptWorks++;
}); });
} }
}, },
// //
getJournalismList(){ getJournalismList() {
// //
this.$api.journalism.getJournalismList().then(d => { this.$api.journalism.getJournalismList().then(d => {
this.JournalismList = d.rows; this.JournalismList = d.rows;
}); });
}, },
handJournalism(item){ handJournalism(item) {
this.$refs.journalismDlg.showDialog(item); this.$refs.journalismDlg.showDialog(item);
}, },
// //
@ -706,65 +736,65 @@ export default {
// //
onClickoOverview(n) { onClickoOverview(n) {
this.overview = n this.overview = n
if (this.overview == 0) { if (this.overview == 0) {
this.projectCategoryWidth=290; this.projectCategoryWidth = 290;
this.overviewText = "项目数"; this.overviewText = "项目数";
this.surveyUrlSb = 'images/survey_icon_1.png' this.surveyUrlSb = 'images/survey_icon_1.png'
} else if (this.overview == 1) { } else if (this.overview == 1) {
this.projectCategoryWidth=210; this.projectCategoryWidth = 210;
this.overviewText = "项目总投资"; this.overviewText = "项目总投资";
this.surveyUrlSb = 'images/survey_icon_2.png' this.surveyUrlSb = 'images/survey_icon_2.png'
} else { } else {
this.projectCategoryWidth=210; this.projectCategoryWidth = 210;
this.overviewText = "项目年投资"; this.overviewText = "项目年投资";
this.surveyUrlSb = 'images/survey_icon_3.png' this.surveyUrlSb = 'images/survey_icon_3.png'
} }
let year=this.$dt(new Date()).$y; let year = this.$dt(new Date()).$y;
this.$api.project.groupByCategory(this.deptInfo.id,n,year).then(d=>{ this.$api.project.groupByCategory(this.deptInfo.id, n, year).then(d => {
let tmps=(d.data||[]).map(it=>{ let tmps = (d.data || []).map(it => {
return { return {
id:it.id, id: it.id,
name:it.projectName, name: it.projectName,
value:it.deptId/10000.0 value: it.deptId / 10000.0
} }
}); });
let sum=0; let sum = 0;
tmps.forEach(it=>{ tmps.forEach(it => {
sum+=it.value; sum += it.value;
}) })
this.overviewTotal=sum; this.overviewTotal = sum;
this.typeDistributionData=tmps; this.typeDistributionData = tmps;
this.elKey++; this.elKey++;
}) })
this.$api.project.groupByLevel(this.deptInfo.id,n,year).then(d=>{ this.$api.project.groupByLevel(this.deptInfo.id, n, year).then(d => {
let tmps=(d.data||[]).map(it=>{ let tmps = (d.data || []).map(it => {
return { return {
id:it.id, id: it.id,
text:it.projectName, text: it.projectName,
value:it.deptId/10000.0, value: it.deptId / 10000.0,
prop:0, prop: 0,
} }
}); });
let sum=0; let sum = 0;
tmps.forEach(it=>{ tmps.forEach(it => {
sum+=it.value; sum += it.value;
}) })
let total=0; let total = 0;
tmps.forEach((it,idx)=>{ tmps.forEach((it, idx) => {
it.prop=sum==0?0:(it.value*100.0/sum).toFixed(1) it.prop = sum == 0 ? 0 : (it.value * 100.0 / sum).toFixed(1)
if(idx<tmps.length-1){ if (idx < tmps.length - 1) {
total+=it.prop*1; total += it.prop * 1;
}else{ } else {
if(sum>0){ if (sum > 0) {
it.prop=(100-total).toFixed(1); it.prop = (100 - total).toFixed(1);
} }
} }
}) })
this.availabilityData=tmps; this.availabilityData = tmps;
this.elKey++; this.elKey++;
}) })
@ -907,8 +937,8 @@ export default {
} }
}, },
automaticRoll() { automaticRoll() {
var height = window.$(".afoot-con-for").innerHeight() var height = window.$(".afoot-con-for").innerHeight()
@ -958,14 +988,17 @@ export default {
position: relative; position: relative;
bottom: -8px; bottom: -8px;
} }
.number-unit{
.number-unit {
word-break: keep-all; word-break: keep-all;
} }
.cost-out{
.labour-education{ .cost-out {
.labour-education {
height: 60px; height: 60px;
.people-number-con{
padding:0px; .people-number-con {
padding: 0px;
} }
} }
} }

View File

@ -1,12 +1,13 @@
<template> <template>
<MyDialog v-if="show" v-model="show" width="1600px" height="850px" ref="dlg" class="index-dlg3" :class="'font-size-'+fontSize"> <MyDialog v-if="show" v-model="show" :loading="loading" width="1600px" height="850px" ref="dlg" class="index-dlg3" :class="'font-size-'+fontSize">
<template slot="title"> <template slot="title">
<div class="warning-info-title" style="padding-left: 20px;"> <div class="warning-info-title" style="padding-left: 20px;" v-if="showType=='all'">
<div :class="nav == 1 ? 'active' : ''" class="nav-item" @click="toggleNav(1)">({{ cnts[0] }})</div> <div :class="nav == 1 ? 'active' : ''" class="nav-item" @click="toggleNav(1)">({{ cnts[0] }})</div>
<div :class="nav == 2 ? 'active' : ''" class="nav-item" @click="toggleNav(2)">({{ cnts[1] }})</div> <div :class="nav == 2 ? 'active' : ''" class="nav-item" @click="toggleNav(2)">({{ cnts[1] }})</div>
<div :class="nav == 4 ? 'active' : ''" class="nav-item" @click="toggleNav(4)">({{ cnts[2] }})</div> <div :class="nav == 4 ? 'active' : ''" class="nav-item" @click="toggleNav(4)">({{ cnts[2] }})</div>
</div> </div>
<template v-else>{{ title }}({{ tableData.length }})</template>
</template> </template>
<div class="font-size-tools"> <div class="font-size-tools">
<i class="set-font-size font-size2" @click="fontSize = 2" :class="fontSize==2?'active':''"> <i class="set-font-size font-size2" @click="fontSize = 2" :class="fontSize==2?'active':''">
@ -47,7 +48,7 @@
<div class="div-text">{{ it.projectName }}</div> <div class="div-text">{{ it.projectName }}</div>
</el-col> </el-col>
<el-col :span="12" style="display: flex;" v-if="nav!=4"> <el-col :span="12" style="display: flex;" v-if="nav!=4||showType!='all'">
<img src="images/title_icon.png"><span class="sp-lbl">目前状态:</span> <img src="images/title_icon.png"><span class="sp-lbl">目前状态:</span>
<div class="div-text" :class="getState(it.projectSchedule)">{{ it.projectSchedule==1?'正常':'滞后' }}</div> <div class="div-text" :class="getState(it.projectSchedule)">{{ it.projectSchedule==1?'正常':'滞后' }}</div>
</el-col> </el-col>
@ -115,7 +116,7 @@
</div> </div>
<div v-if="tableData.length==0" style="text-align: center;margin-top:200px;"> <div v-if="tableData.length==0 && !loading" style="text-align: center;margin-top:200px;">
<img src="images/nodata.png" style="width: 240px;"> <img src="images/nodata.png" style="width: 240px;">
<div style="text-align: center;">暂无数据</div> <div style="text-align: center;">暂无数据</div>
</div> </div>
@ -133,12 +134,16 @@ export default {
}, },
data() { data() {
return { return {
title:'',
dataState:0,
showType:'',
quarterlyName:'', quarterlyName:'',
nav: 1, nav: 1,
show: false, show: false,
fontSize:0, fontSize:0,
cnts:[], cnts:[],
tableData:[] tableData:[],
loading:false
}; };
}, },
@ -178,10 +183,12 @@ export default {
}), }),
this.$api.schedule.selectByProjectType(n) this.$api.schedule.selectByProjectType(n)
]; ];
this.loading=true;
this.$api.http.all(ajaxs).then(res=>{ this.$api.http.all(ajaxs).then(res=>{
this.loading=false;
let prjs=res[0].data||[]; let prjs=res[0].data||[];
let tmps=res[1].data||[]; let tmps=res[1].data||[];
this.tableData=prjs.map(it=>{ let objs=prjs.map(it=>{
it.projectName=it.project?.projectName||''; it.projectName=it.project?.projectName||'';
it.projectSchedule=it.project?.projectSchedule||'1'; it.projectSchedule=it.project?.projectSchedule||'1';
let objs=tmps.filter(item=>it.id==item.projectId); let objs=tmps.filter(item=>it.id==item.projectId);
@ -191,6 +198,15 @@ export default {
} }
return it; return it;
}).sort((a,b)=>b.projectSchedule-a.projectSchedule); }).sort((a,b)=>b.projectSchedule-a.projectSchedule);
if(this.showType=="all"){
this.tableData=objs;
}else{
if(this.dataState==1){
this.tableData=objs.filter(ob=>ob.projectSchedule!=1);
}else{
this.tableData=objs.filter(ob=>ob.projectSchedule==1);
}
}
}) })
}, },
@ -204,12 +220,14 @@ export default {
this.$api.schedule.selectByProjectType(n), this.$api.schedule.selectByProjectType(n),
this.$api.buildNode.queryByProjectTypeNoTree(n) this.$api.buildNode.queryByProjectTypeNoTree(n)
]; ];
this.loading=true;
this.$api.http.all(ajaxs).then(res=>{ this.$api.http.all(ajaxs).then(res=>{
this.loading=false;
let prjs=res[0].data||[]; let prjs=res[0].data||[];
let tmps=res[1].data||[]; let tmps=res[1].data||[];
let nodes=res[2]||[]; let nodes=res[2]||[];
let findNodes=['01','02','03','04','05']; let findNodes=['01','02','03','04','05'];
this.tableData=prjs.map(it=>{ let objs=prjs.map(it=>{
it.projectName=it.project?.projectName||''; it.projectName=it.project?.projectName||'';
it.projectSchedule=it.project?.projectSchedule||'1'; it.projectSchedule=it.project?.projectSchedule||'1';
let objs=tmps.filter(item=>it.id==item.projectId); let objs=tmps.filter(item=>it.id==item.projectId);
@ -220,23 +238,56 @@ export default {
it.nodes=this.$api.buildNode.toTree(nds); it.nodes=this.$api.buildNode.toTree(nds);
return it; return it;
}).sort((a,b)=>b.projectSchedule-a.projectSchedule); }).sort((a,b)=>b.projectSchedule-a.projectSchedule);
if(this.showType=="all"){
this.tableData=objs;
}else{
if(this.dataState==1){
this.tableData=objs.filter(ob=>ob.projectSchedule!=1);
}else{
this.tableData=objs.filter(ob=>ob.projectSchedule==1);
}
}
}) })
}, },
loadData4(n){ loadData4(n){
this.loading=true;
this.$api.schedule.selectByProjectType(n).then(d=>{ this.$api.schedule.selectByProjectType(n).then(d=>{
this.tableData=(d.data||[]).map(it=>{ this.loading=false;
let objs=(d.data||[]).map(it=>{
it.projectName=it.surProject?.projectName||'' it.projectName=it.surProject?.projectName||''
it.projectSchedule=it.surProject?.projectSchedule||'1' it.projectSchedule=it.surProject?.projectSchedule||'1'
return it; return it;
}).sort((a,b)=>b.projectSchedule-a.projectSchedule);; }).sort((a,b)=>b.projectSchedule-a.projectSchedule);;
if(this.showType=="all"){
this.tableData=objs;
}else{
if(this.dataState==1){
this.tableData=objs.filter(ob=>ob.projectSchedule!=1);
}else{
this.tableData=objs.filter(ob=>ob.projectSchedule==1);
}
}
}) })
}, },
showDialog(n,cnts) { showDialog(n,cnts) {
this.loading=true;
this.tableData=[]
this.showType="all";
this.cnts=cnts; this.cnts=cnts;
this.nav=n; this.nav=n;
this.toggleNav(n); this.toggleNav(n);
this.show = true this.show = true
} },
showDetailDialog(n,type){
this.loading=true;
this.tableData=[]
this.showType="detail";
this.nav=n;
this.dataState=type;
this.toggleNav(n);
this.title=["","在建项目","拟建项目","","完成项目"][n]+"-"+(type==1?'进度滞后项目':'正常推进项目');
this.show=true;
},
}, },
}; };
</script> </script>

View File

@ -5,6 +5,8 @@ import './style/index.less'
import dayfilter from '@/utils/dayfilter' import dayfilter from '@/utils/dayfilter'
import {tryToJson} from '../utils/tools' import {tryToJson} from '../utils/tools'
import H265Player from '../components/h265-player/index' import H265Player from '../components/h265-player/index'
import { Loading } from 'element-ui';
Loading.install(Vue);
H265Player.install(Vue); H265Player.install(Vue);
dayfilter(Vue); dayfilter(Vue);
const vue=new Vue(); const vue=new Vue();

View File

@ -13,7 +13,9 @@
<el-table v-show="nav == 0" :data="tableData1" class="mytable" height="500" style="width: 100%;background: transparent;" <el-table v-show="nav == 0" :data="tableData1" class="mytable" height="500" style="width: 100%;background: transparent;"
ref="fbsubordinateUnit"> ref="fbsubordinateUnit">
<el-table-column prop="num" label="序号" class-name="text-left" width="100"> </el-table-column> <el-table-column prop="num" label="序号" class-name="text-left" width="100">
<template slot-scope="scope">{{ scope.$index+1}}</template>
</el-table-column>
<el-table-column prop="prj" label="项目名称" width="400" class-name="text-left"> </el-table-column> <el-table-column prop="prj" label="项目名称" width="400" class-name="text-left"> </el-table-column>
<el-table-column prop="detail" label="建设规模及主要工程内容" class-name="text-left"> <el-table-column prop="detail" label="建设规模及主要工程内容" class-name="text-left">
<template slot-scope="scope"> <template slot-scope="scope">
@ -21,7 +23,7 @@
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="prop" label="建设性质(新建/续建/前期)" width="100"> <el-table-column prop="prop" label="建设性质" width="100">
<template slot-scope="scope"> <template slot-scope="scope">
<span style="color:red">{{ scope.row.prop }}</span> <span style="color:red">{{ scope.row.prop }}</span>
</template> </template>
@ -40,7 +42,9 @@
<el-table v-show="nav == 1" :data="tableData2" class="mytable" height="500" style="width: 100%;background: transparent;" <el-table v-show="nav == 1" :data="tableData2" class="mytable" height="500" style="width: 100%;background: transparent;"
ref="fbsubordinateUnit"> ref="fbsubordinateUnit">
<el-table-column prop="num" label="序号" class-name="text-left" width="100"> </el-table-column> <el-table-column prop="num" label="序号" class-name="text-left" width="100">
<template slot-scope="scope">{{ scope.$index+1}}</template>
</el-table-column>
<el-table-column prop="prj" label="项目名称" width="400" class-name="text-left"> </el-table-column> <el-table-column prop="prj" label="项目名称" width="400" class-name="text-left"> </el-table-column>
<el-table-column prop="detail" label="建设规模及主要工程内容" class-name="text-left"> <el-table-column prop="detail" label="建设规模及主要工程内容" class-name="text-left">
<template slot-scope="scope"> <template slot-scope="scope">
@ -48,7 +52,7 @@
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="prop" label="建设性质(新建/续建/前期)" width="100"> <el-table-column prop="prop" label="建设性质" width="100">
<template slot-scope="scope"> <template slot-scope="scope">
<span style="color:red">{{ scope.row.prop }}</span> <span style="color:red">{{ scope.row.prop }}</span>
</template> </template>
@ -210,13 +214,42 @@ export default {
] ]
this.initData();
}, },
methods: { methods: {
initData(){
this.tableData1=[];
this.tableData2=[];
let ajaxs=[
this.$api.plan.listAll(0),
this.$api.plan.listAll(1),
];
this.$api.http.all(ajaxs).then(res=>{
this.tableData1=this.convertData(res[0].data||[]);
this.tableData2=this.convertData(res[1].data||[]);
});
},
convertData(tmps){
return tmps.map(it=>{
return{
prj:it.projectName,
detail:it.content,
prop:it.buildType,
department:it.dept,
startTime:it.startDate,
endTime:it.endDate,
taotal:it.totalInvestment,
year:it.yearInvestment,
...it
}
});
},
toggleNav(n) { toggleNav(n) {
this.nav = n; this.nav = n;
}, },
showDialog(n) { showDialog(n) {
this.initData();
this.nav=n; this.nav=n;
this.show = true this.show = true
} }

View File

@ -104,13 +104,16 @@
<el-col :span="12"> <el-col :span="12">
<module-one-1-2 label="项目推进明细"> <module-one-1-2 label="项目推进明细">
<el-row style="padding: 20px;" :key="elKey"> <el-row style="padding: 20px;" :key="elKey">
<el-col :span="12"> <el-col :span="12" style="position: relative;">
<img src="images/icon2001.png"
style="position: absolute;cursor: pointer;right: 24px;top: 12px;"
@click="showPrjSummary">
<div class="warning-info-title my-warning-info-title"> <div class="warning-info-title my-warning-info-title">
<div :class="pushNav == 0 ? 'active' : ''" @click="doPushNav(0, '在建项目')">在建项目({{ <div :class="pushNav == 1 ? 'active' : ''" @click="doPushNav(1, '在建项目')">在建项目({{
getPrjCateCount(0) }})</div> getPrjCateCount(0) }})</div>
<div :class="pushNav == 1 ? 'active' : ''" @click="doPushNav(1, '拟建项目')">拟建项目({{ <div :class="pushNav == 2 ? 'active' : ''" @click="doPushNav(2, '拟建项目')">拟建项目({{
getPrjCateCount(1) }})</div> getPrjCateCount(1) }})</div>
<div :class="pushNav == 3 ? 'active' : ''" @click="doPushNav(3, '完成项目')">完成项目({{ <div :class="pushNav == 4 ? 'active' : ''" @click="doPushNav(4, '完成项目')">完成项目({{
getPrjCateCount(3) }})</div> getPrjCateCount(3) }})</div>
</div> </div>
<el-row> <el-row>
@ -126,7 +129,7 @@
</div> </div>
</el-col> </el-col>
<el-col :span="16"> <el-col :span="16">
<staff-survey-chart :height="220" unit=" " :data="pushData" <staff-survey-chart :height="220" unit=" " :data="pushData" @chart-click="planSummaryChartClick"
:width="140"></staff-survey-chart> :width="140"></staff-survey-chart>
</el-col> </el-col>
</el-row> </el-row>
@ -358,6 +361,7 @@
<index-dlg1 ref="dlg1"></index-dlg1> <index-dlg1 ref="dlg1"></index-dlg1>
<index-dlg2 ref="dlg2"></index-dlg2> <index-dlg2 ref="dlg2"></index-dlg2>
<index-dlg3 ref="dlg3"></index-dlg3> <index-dlg3 ref="dlg3"></index-dlg3>
<prj-summary-dlg ref="prjSummary"></prj-summary-dlg>
<build-node-dlg ref="buildNodeDlg"></build-node-dlg> <build-node-dlg ref="buildNodeDlg"></build-node-dlg>
</div> </div>
</template> </template>
@ -374,6 +378,7 @@ import '../components/screen-select'
import indexDlg1 from './progress/indexDlg1' import indexDlg1 from './progress/indexDlg1'
import indexDlg2 from './progress/indexDlg2' import indexDlg2 from './progress/indexDlg2'
import indexDlg3 from './progress/indexDlg3' import indexDlg3 from './progress/indexDlg3'
import PrjSummaryDlg from './index/indexDlg2.vue'
import problemProgress from './progress/problemProgress.vue' import problemProgress from './progress/problemProgress.vue'
import buildNodeDlg from './progress/buildNodeDlg.vue' import buildNodeDlg from './progress/buildNodeDlg.vue'
export default { export default {
@ -382,7 +387,8 @@ export default {
indexDlg2, indexDlg2,
indexDlg3, indexDlg3,
problemProgress, problemProgress,
buildNodeDlg buildNodeDlg,
PrjSummaryDlg
}, },
data() { data() {
return { return {
@ -393,7 +399,7 @@ export default {
nodePLanData: [], nodePLanData: [],
assessData: [], assessData: [],
pushUrl: 'images/company_6.png', pushUrl: 'images/company_6.png',
pushNav: 0, pushNav: 1,
pushText: '在建项目', pushText: '在建项目',
pushCount: 35, pushCount: 35,
pushData: [ pushData: [
@ -452,6 +458,7 @@ export default {
}, },
created() { created() {
this.init() this.init()
this.loadPlan();
}, },
mounted() { mounted() {
window.app = this; window.app = this;
@ -473,6 +480,45 @@ export default {
}) })
}, },
methods: { methods: {
planSummaryChartClick(p){
let idx=0;
if(p.event.target.parent.style && p.event.target.parent.style.text){
if(p.event.target.parent.style.text.includes("正常推进项目")){
idx=2;
}
if(p.event.target.parent.style.text.includes("进度滞后项目")){
idx=1;
}
}else{
idx=p.seriesIndex;
}
if(idx==1||idx==2){
this.$refs.prjSummary.showDetailDialog(this.pushNav,idx);
}
},
showPrjSummary(){
this.$refs.prjSummary.showDialog(this.pushNav,[this.getPrjCateCount(0),this.getPrjCateCount(1),this.getPrjCateCount(3)])
},
loadPlan(){
this.$api.plan.listAllTop3().then(d=>{
let tmps=(d.data||[]).map(it=>{
return{
prj:it.projectName,
detail:it.content,
prop:it.buildType,
department:it.dept,
startTime:it.startDate,
endTime:it.endDate,
taotal:it.totalInvestment,
year:it.yearInvestment,
...it
}
});
this.planData1=tmps.filter(d=>d.planType==0);
this.planData2=tmps.filter(d=>d.planType==1);
})
},
selectCompletionRate(){ selectCompletionRate(){
let postData = {} let postData = {}
if (this.prjInfo.id == 0) { if (this.prjInfo.id == 0) {
@ -486,8 +532,8 @@ export default {
}, },
selectScheduledAlerts() { selectScheduledAlerts() {
let postData = {} let postData = {}
if (this.prjInfo.id == 0) { if ((this.prjInfo?.id||0) == 0) {
postData.id = this.dept.id; postData.id = this.dept?.id||0;
} else { } else {
postData.projectId = this.prjInfo.id; postData.projectId = this.prjInfo.id;
} }
@ -585,6 +631,7 @@ export default {
this.pushNav = n; this.pushNav = n;
this.pushText = t; this.pushText = t;
this.pushUrl = ['images/company_6.png', 'images/company_5.png', 'images/company_4.png'][n] this.pushUrl = ['images/company_6.png', 'images/company_5.png', 'images/company_4.png'][n]
n--;
this.pushCount = this.getPrjCateCount(n); this.pushCount = this.getPrjCateCount(n);
let item = this.projectCategory.length > n ? this.projectCategory[n] : null; let item = this.projectCategory.length > n ? this.projectCategory[n] : null;
this.pushData[0].value = item && item.length > 0 ? item[0].cnt : 0; this.pushData[0].value = item && item.length > 0 ? item[0].cnt : 0;
@ -672,14 +719,14 @@ export default {
} }
return 0; return 0;
}, },
groupByProjectCategory(detpId){ groupByProjectCategory(deptId) {
this.$api.project.groupByProjectCategory(detpId,datas => { this.$api.project.groupByProjectCategory(deptId, datas => {
this.projectCategory = datas; this.projectCategory = datas;
this.pushCount = this.getPrjCateCount(0); this.prjPrcessTotal = this.getPrjCateCount(0);
let item = this.projectCategory.length > 0 ? this.projectCategory[0] : null; let item = this.projectCategory.length > 0 ? this.projectCategory[0] : null;
this.pushData[0].value = item && item.length > 0 ? item[0].cnt : 0; this.pushData[0].value = item && item.length > 0 ? item[0].cnt : 0;
this.pushData[1].value = item && item.length > 1 ? item[1].cnt : 0; this.pushData[1].value = item && item.length > 1 ? item[1].cnt : 0;
this.doPushNav(0, '在建项目'); this.doPushNav(1, '在建项目');
this.elKey++; this.elKey++;
}); });
}, },

View File

@ -622,7 +622,7 @@ export default {
} }
this.videoListData = videoListData this.videoListData = videoListData
debugger
this.playVideo(); this.playVideo();
@ -1338,7 +1338,7 @@ export default {
this.oWebControl.JS_Disconnect().then(function () { }, function () { }); this.oWebControl.JS_Disconnect().then(function () { }, function () { });
}, },
videoPlay(video) { videoPlay(video) {
debugger
// //
// var VideoDistribution = this.VideoDistribution // var VideoDistribution = this.VideoDistribution
// for (var i = 0; i < VideoDistribution.length; i++) { // for (var i = 0; i < VideoDistribution.length; i++) {

View File

@ -97,4 +97,14 @@
top:0px !important; top:0px !important;
} }
} }
}
.el-loading-mask{
background-color: rgba(255,255,255,.4);
.el-loading-spinner{
.circular{
right:unset;
width: 100px;
height: 100px;
}
}
} }