Merge branch 'dev' of http://62.234.3.186:3000/sxyanzhu/jhbigscreen into dev
commit
16203203d9
|
@ -3,35 +3,39 @@ import request from '@/utils/request'
|
||||||
|
|
||||||
|
|
||||||
//质量整改-安全分类汇总(按分类)
|
//质量整改-安全分类汇总(按分类)
|
||||||
const safetySummary=(deptId,roleType,projectId)=>{
|
const safetySummary=(data)=>{
|
||||||
return request({
|
return request({
|
||||||
url: `bgscreen/problemmodify/safetySummary?deptId=${deptId}&roleType=${roleType}&projectId=${projectId||0}`,
|
url: `bgscreen/problemmodify/safetySummary`,
|
||||||
method: 'get'
|
method: 'post',
|
||||||
|
data:data
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
//质量整改-质量分类汇总(按分类)
|
//质量整改-质量分类汇总(按分类)
|
||||||
const qualitySummary=(deptId,roleType,projectId)=>{
|
const qualitySummary=(data)=>{
|
||||||
return request({
|
return request({
|
||||||
url: `bgscreen/problemmodify/qualitySummary?deptId=${deptId}&roleType=${roleType}&projectId=${projectId||0}`,
|
url: `bgscreen/problemmodify/qualitySummary`,
|
||||||
method: 'get'
|
method: 'post',
|
||||||
|
data:data
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//质量整改-安全分类汇总(按项目)
|
//质量整改-安全分类汇总(按项目)
|
||||||
const safetySummaryByProject=(deptId,roleType,projectId)=>{
|
const safetySummaryByProject=(data)=>{
|
||||||
return request({
|
return request({
|
||||||
url: `bgscreen/problemmodify/safetySummaryByProject?deptId=${deptId}&roleType=${roleType}&projectId=${projectId||0}`,
|
url: `bgscreen/problemmodify/safetySummaryByProject`,
|
||||||
method: 'get'
|
method: 'post',
|
||||||
|
data:data
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
//质量整改-安全分类汇总(按项目)
|
//质量整改-安全分类汇总(按项目)
|
||||||
const qualitySummaryByProject=(deptId,roleType,projectId)=>{
|
const qualitySummaryByProject=(data)=>{
|
||||||
return request({
|
return request({
|
||||||
url: `bgscreen/problemmodify/qualitySummaryByProject?deptId=${deptId}&roleType=${roleType}&projectId=${projectId||0}`,
|
url: `bgscreen/problemmodify/qualitySummaryByProject`,
|
||||||
method: 'get'
|
method: 'post',
|
||||||
|
data:data
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -485,7 +485,11 @@ export default {
|
||||||
this.qualityNav=n;
|
this.qualityNav=n;
|
||||||
if(n==0){
|
if(n==0){
|
||||||
this.qualityNavTitle="安全隐患总数";
|
this.qualityNavTitle="安全隐患总数";
|
||||||
this.$api.problemmodify.safetySummary(this.deptInfo.id,0).then(d=>{
|
let postData={
|
||||||
|
deptId:this.deptInfo?.id||0,
|
||||||
|
roleType:0
|
||||||
|
};
|
||||||
|
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,
|
||||||
|
@ -502,8 +506,12 @@ export default {
|
||||||
this.elKey++;
|
this.elKey++;
|
||||||
})
|
})
|
||||||
}else{
|
}else{
|
||||||
|
let postData={
|
||||||
|
deptId:this.deptInfo?.id||0,
|
||||||
|
roleType:0
|
||||||
|
};
|
||||||
this.qualityNavTitle="质量隐患总数";
|
this.qualityNavTitle="质量隐患总数";
|
||||||
this.$api.problemmodify.qualitySummary(this.deptInfo.id,0).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,
|
||||||
|
|
|
@ -6,9 +6,14 @@
|
||||||
<div class="screen-content-max">
|
<div class="screen-content-max">
|
||||||
<screen-header :nav="4" ></screen-header>
|
<screen-header :nav="4" ></screen-header>
|
||||||
<div class="screen-content">
|
<div class="screen-content">
|
||||||
<el-row :key="elKey">
|
<el-row>
|
||||||
<el-col :span="12">
|
<el-col :span="12" style="position: relative;">
|
||||||
<module-one-3-1 label="质量隐患检查" class="hide-scroll">
|
<module-one-3-1 label="质量隐患检查" class="hide-scroll">
|
||||||
|
<div style="position: absolute;right:0px;top:4px;">
|
||||||
|
<el-date-picker class="bg-date-picker" v-model="selDate" type="daterange" popper-class="bg-date-picker-pop" :editable="false" @change="dtChange"
|
||||||
|
:picker-options="pickerOptions" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期"></el-date-picker>
|
||||||
|
</div>
|
||||||
|
<div :key="'a'+elSummaryKey">
|
||||||
<div class="warning-info-title" style="padding-left: 20px;">
|
<div class="warning-info-title" style="padding-left: 20px;">
|
||||||
<div :class="safeNav==0?'active':''" @click="doSafeNav(0,'汇总总数')">汇总</div>
|
<div :class="safeNav==0?'active':''" @click="doSafeNav(0,'汇总总数')">汇总</div>
|
||||||
<div :class="safeNav==3?'active':''" @click="doSafeNav(3,'集团总数')">集团</div>
|
<div :class="safeNav==3?'active':''" @click="doSafeNav(3,'集团总数')">集团</div>
|
||||||
|
@ -17,8 +22,9 @@
|
||||||
<div :class="safeNav==6?'active':''" @click="doSafeNav(6,'监理单位')">监理单位</div>
|
<div :class="safeNav==6?'active':''" @click="doSafeNav(6,'监理单位')">监理单位</div>
|
||||||
<div :class="safeNav==7?'active':''" @click="doSafeNav(7,'总包单位')">总包单位</div>
|
<div :class="safeNav==7?'active':''" @click="doSafeNav(7,'总包单位')">总包单位</div>
|
||||||
</div>
|
</div>
|
||||||
<project-overview-chart2 :key="safeNav" :sp="'\n'" :maintitle="fmt(summaryTotal)" :typedata="summary" :text="safeText" :height="230"></project-overview-chart2>
|
<project-overview-chart2 :key="'b'+safeNav" :sp="'\n'" :maintitle="fmt(summaryTotal)" :typedata="summary" :text="safeText" :height="230"></project-overview-chart2>
|
||||||
<div style="padding:0px 20px">
|
</div>
|
||||||
|
<div style="padding:0px 20px" :key="'c'+elSummaryPrjKey">
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span="12" v-if="1==2">
|
<el-col :span="12" v-if="1==2">
|
||||||
<div class="rank-chart-title bottom-line">质量隐患类型分析</div>
|
<div class="rank-chart-title bottom-line">质量隐患类型分析</div>
|
||||||
|
@ -218,7 +224,10 @@ export default {
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
selDate:'',
|
||||||
elKey:0,
|
elKey:0,
|
||||||
|
elSummaryKey:0,
|
||||||
|
elSummaryPrjKey:0,
|
||||||
elCheck:0,
|
elCheck:0,
|
||||||
dept:null,
|
dept:null,
|
||||||
projectInfo:null,
|
projectInfo:null,
|
||||||
|
@ -277,6 +286,33 @@ export default {
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
pickerOptions: {
|
||||||
|
shortcuts: [{
|
||||||
|
text: '最近一周',
|
||||||
|
onClick(picker) {
|
||||||
|
const end = new Date();
|
||||||
|
const start = new Date();
|
||||||
|
start.setTime(start.getTime() - 3600 * 1000 * 24 * 7);
|
||||||
|
picker.$emit('pick', [start, end]);
|
||||||
|
}
|
||||||
|
}, {
|
||||||
|
text: '最近一个月',
|
||||||
|
onClick(picker) {
|
||||||
|
const end = new Date();
|
||||||
|
const start = new Date();
|
||||||
|
start.setTime(start.getTime() - 3600 * 1000 * 24 * 30);
|
||||||
|
picker.$emit('pick', [start, end]);
|
||||||
|
}
|
||||||
|
}, {
|
||||||
|
text: '最近三个月',
|
||||||
|
onClick(picker) {
|
||||||
|
const end = new Date();
|
||||||
|
const start = new Date();
|
||||||
|
start.setTime(start.getTime() - 3600 * 1000 * 24 * 90);
|
||||||
|
picker.$emit('pick', [start, end]);
|
||||||
|
}
|
||||||
|
}]
|
||||||
|
},
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
|
@ -335,8 +371,22 @@ export default {
|
||||||
n=""+n;
|
n=""+n;
|
||||||
return " ".substring(0,3-n.length)+n;
|
return " ".substring(0,3-n.length)+n;
|
||||||
},
|
},
|
||||||
|
dtChange(){
|
||||||
|
this.doDeptChane();
|
||||||
|
},
|
||||||
doDeptChane(){
|
doDeptChane(){
|
||||||
this.$api.problemmodify.qualitySummary(this.dept?.id||0,this.safeNav,this.projectInfo?.id||0).then(d=>{
|
let postData={
|
||||||
|
deptId:this.dept?.id||0,
|
||||||
|
roleType:this.safeNav,
|
||||||
|
projectId:this.projectInfo?.id||0
|
||||||
|
};
|
||||||
|
if(this.selDate.length>0){
|
||||||
|
postData.startDate=this.$dt(this.selDate[0]).format("YYYY-MM-DD");
|
||||||
|
}
|
||||||
|
if(this.selDate.length>1){
|
||||||
|
postData.endDate=this.$dt(this.selDate[1]).format("YYYY-MM-DD");
|
||||||
|
}
|
||||||
|
this.$api.problemmodify.qualitySummary(postData).then(d=>{
|
||||||
this.summary=(d||[]).map(it=>{
|
this.summary=(d||[]).map(it=>{
|
||||||
return {
|
return {
|
||||||
text:it.problemArea,
|
text:it.problemArea,
|
||||||
|
@ -356,10 +406,10 @@ export default {
|
||||||
it.prop=(it.value*100.0/this.summaryTotal).toFixed(1);
|
it.prop=(it.value*100.0/this.summaryTotal).toFixed(1);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
this.elKey++;
|
this.elSummaryKey++;
|
||||||
});
|
});
|
||||||
|
|
||||||
this.$api.problemmodify.qualitySummaryByProject(this.dept?.id||0,this.safeNav,this.projectInfo?.id||0).then(d=>{
|
this.$api.problemmodify.qualitySummaryByProject(postData).then(d=>{
|
||||||
this.summaryPrj=(d||[]).map(it=>{
|
this.summaryPrj=(d||[]).map(it=>{
|
||||||
return {
|
return {
|
||||||
...it,
|
...it,
|
||||||
|
@ -380,7 +430,7 @@ export default {
|
||||||
}
|
}
|
||||||
it.rate = (it.checkState * 100.0 / it.value).toFixed(1);
|
it.rate = (it.checkState * 100.0 / it.value).toFixed(1);
|
||||||
})
|
})
|
||||||
this.elKey++;
|
this.elSummaryPrjKey++;
|
||||||
});
|
});
|
||||||
this.doProjectChecking();
|
this.doProjectChecking();
|
||||||
},
|
},
|
||||||
|
|
|
@ -6,9 +6,14 @@
|
||||||
<div class="screen-content-max">
|
<div class="screen-content-max">
|
||||||
<screen-header :nav="3"></screen-header>
|
<screen-header :nav="3"></screen-header>
|
||||||
<div class="screen-content">
|
<div class="screen-content">
|
||||||
<el-row :key="elKey">
|
<el-row>
|
||||||
<el-col :span="12">
|
<el-col :span="12" style="position: relative;">
|
||||||
<module-one-3-1 label="安全隐患检查">
|
<module-one-3-1 label="安全隐患检查">
|
||||||
|
<div style="position: absolute;right:0px;top:4px;">
|
||||||
|
<el-date-picker class="bg-date-picker" v-model="selDate" type="daterange" popper-class="bg-date-picker-pop" :editable="false" @change="dtChange"
|
||||||
|
:picker-options="pickerOptions" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期"></el-date-picker>
|
||||||
|
</div>
|
||||||
|
<div :key="'a'+elSummaryKey">
|
||||||
<div class="warning-info-title" style="padding-left: 20px;">
|
<div class="warning-info-title" style="padding-left: 20px;">
|
||||||
<div :class="safeNav == 0 ? 'active' : ''" @click="doSafeNav(0, '汇总总数')">汇总</div>
|
<div :class="safeNav == 0 ? 'active' : ''" @click="doSafeNav(0, '汇总总数')">汇总</div>
|
||||||
<div :class="safeNav == 3 ? 'active' : ''" @click="doSafeNav(3, '集团总数')">集团</div>
|
<div :class="safeNav == 3 ? 'active' : ''" @click="doSafeNav(3, '集团总数')">集团</div>
|
||||||
|
@ -17,9 +22,10 @@
|
||||||
<div :class="safeNav == 6 ? 'active' : ''" @click="doSafeNav(6, '监理单位')">监理单位</div>
|
<div :class="safeNav == 6 ? 'active' : ''" @click="doSafeNav(6, '监理单位')">监理单位</div>
|
||||||
<div :class="safeNav == 7 ? 'active' : ''" @click="doSafeNav(7, '总包单位')">总包单位</div>
|
<div :class="safeNav == 7 ? 'active' : ''" @click="doSafeNav(7, '总包单位')">总包单位</div>
|
||||||
</div>
|
</div>
|
||||||
<project-overview-chart2 :key="safeNav" :sp="'\n'" :maintitle="fmt(summaryTotal)"
|
<project-overview-chart2 :key="'b'+safeNav" :sp="'\n'" :maintitle="fmt(summaryTotal)"
|
||||||
:typedata="summary" :text="safeText" :height="230"></project-overview-chart2>
|
:typedata="summary" :text="safeText" :height="230"></project-overview-chart2>
|
||||||
<div style="padding:0px 20px">
|
</div>
|
||||||
|
<div style="padding:0px 20px" :key="'c'+elSummaryPrjKey">
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span="12" v-if="1 == 2">
|
<el-col :span="12" v-if="1 == 2">
|
||||||
<div class="rank-chart-title bottom-line">安全隐患类型分析</div>
|
<div class="rank-chart-title bottom-line">安全隐患类型分析</div>
|
||||||
|
@ -294,6 +300,9 @@ export default {
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
selDate:'',
|
||||||
|
elSummaryKey:0,
|
||||||
|
elSummaryPrjKey:0,
|
||||||
elKey: 0,
|
elKey: 0,
|
||||||
dept: null,
|
dept: null,
|
||||||
projectInfo:null,
|
projectInfo:null,
|
||||||
|
@ -336,7 +345,34 @@ export default {
|
||||||
summary: [],
|
summary: [],
|
||||||
summaryTotal: 0,
|
summaryTotal: 0,
|
||||||
summaryPrj: [],
|
summaryPrj: [],
|
||||||
summaryPrjTotal: 0
|
summaryPrjTotal: 0,
|
||||||
|
pickerOptions: {
|
||||||
|
shortcuts: [{
|
||||||
|
text: '最近一周',
|
||||||
|
onClick(picker) {
|
||||||
|
const end = new Date();
|
||||||
|
const start = new Date();
|
||||||
|
start.setTime(start.getTime() - 3600 * 1000 * 24 * 7);
|
||||||
|
picker.$emit('pick', [start, end]);
|
||||||
|
}
|
||||||
|
}, {
|
||||||
|
text: '最近一个月',
|
||||||
|
onClick(picker) {
|
||||||
|
const end = new Date();
|
||||||
|
const start = new Date();
|
||||||
|
start.setTime(start.getTime() - 3600 * 1000 * 24 * 30);
|
||||||
|
picker.$emit('pick', [start, end]);
|
||||||
|
}
|
||||||
|
}, {
|
||||||
|
text: '最近三个月',
|
||||||
|
onClick(picker) {
|
||||||
|
const end = new Date();
|
||||||
|
const start = new Date();
|
||||||
|
start.setTime(start.getTime() - 3600 * 1000 * 24 * 90);
|
||||||
|
picker.$emit('pick', [start, end]);
|
||||||
|
}
|
||||||
|
}]
|
||||||
|
},
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
|
@ -463,8 +499,22 @@ export default {
|
||||||
n = "" + n;
|
n = "" + n;
|
||||||
return " ".substring(0, 3 - n.length) + n;
|
return " ".substring(0, 3 - n.length) + n;
|
||||||
},
|
},
|
||||||
doDeptChane() {
|
dtChange(){
|
||||||
this.$api.problemmodify.safetySummary(this.dept.id, this.safeNav,this.projectInfo?.id||0).then(d => {
|
this.doDeptChane();
|
||||||
|
},
|
||||||
|
doDeptChane() {
|
||||||
|
let postData={
|
||||||
|
deptId:this.dept?.id||0,
|
||||||
|
roleType:this.safeNav,
|
||||||
|
projectId:this.projectInfo?.id||0
|
||||||
|
};
|
||||||
|
if(this.selDate.length>0){
|
||||||
|
postData.startDate=this.$dt(this.selDate[0]).format("YYYY-MM-DD");
|
||||||
|
}
|
||||||
|
if(this.selDate.length>1){
|
||||||
|
postData.endDate=this.$dt(this.selDate[1]).format("YYYY-MM-DD");
|
||||||
|
}
|
||||||
|
this.$api.problemmodify.safetySummary(postData).then(d => {
|
||||||
|
|
||||||
this.summary = (d || []).map(it => {
|
this.summary = (d || []).map(it => {
|
||||||
return {
|
return {
|
||||||
|
@ -484,11 +534,10 @@ export default {
|
||||||
} else {
|
} else {
|
||||||
it.prop = (it.value * 100.0 / this.summaryTotal).toFixed(1);
|
it.prop = (it.value * 100.0 / this.summaryTotal).toFixed(1);
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
this.elKey++;
|
this.elSummaryKey++;
|
||||||
});
|
});
|
||||||
|
this.$api.problemmodify.safetySummaryByProject(postData).then(d => {
|
||||||
this.$api.problemmodify.safetySummaryByProject(this.dept.id, this.safeNav,this.projectInfo?.id||0).then(d => {
|
|
||||||
this.summaryPrj = (d || []).map(it => {
|
this.summaryPrj = (d || []).map(it => {
|
||||||
return {
|
return {
|
||||||
...it,
|
...it,
|
||||||
|
@ -509,7 +558,7 @@ export default {
|
||||||
}
|
}
|
||||||
it.rate = (it.checkState * 100.0 / it.value).toFixed(1);
|
it.rate = (it.checkState * 100.0 / it.value).toFixed(1);
|
||||||
})
|
})
|
||||||
this.elKey++;
|
this.elSummaryPrjKey++;
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
// 获取图片映射
|
// 获取图片映射
|
||||||
|
|
|
@ -7,18 +7,24 @@ module.exports = defineConfig({
|
||||||
host: '0.0.0.0',
|
host: '0.0.0.0',
|
||||||
port: 3000,
|
port: 3000,
|
||||||
open: true,
|
open: true,
|
||||||
proxy: {
|
proxy: {
|
||||||
|
'/jhapi/profile':{
|
||||||
|
target: `http://62.234.3.186/jhapi/profile/`,
|
||||||
|
changeOrigin: true,
|
||||||
|
pathRewrite: {
|
||||||
|
'^/jhapi/profile':'/'
|
||||||
|
}
|
||||||
|
},
|
||||||
'/jhapi':{
|
'/jhapi':{
|
||||||
target: `http://62.234.3.186/jhapi/`,
|
//target: `http://62.234.3.186/jhapi/`,
|
||||||
//target: `http://127.0.0.1:8090/jhapi`,
|
target: `http://127.0.0.1:8090/jhapi/`,
|
||||||
changeOrigin: true,
|
changeOrigin: true,
|
||||||
pathRewrite: {
|
pathRewrite: {
|
||||||
'^/jhapi':'/'
|
'^/jhapi':'/'
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
'/profile':{
|
'/profile':{
|
||||||
target: `http://62.234.3.186/profile/`,
|
target: `http://62.234.3.186/profile/`,
|
||||||
//target: `http://127.0.0.1:8090/jhapi`,
|
|
||||||
changeOrigin: true,
|
changeOrigin: true,
|
||||||
pathRewrite: {
|
pathRewrite: {
|
||||||
'^/profile':'/'
|
'^/profile':'/'
|
||||||
|
|
Loading…
Reference in New Issue