Merge branch 'shenzhen-dev' of http://139.9.66.234:18023/yjlHub/zhgdlarge into shenzhen-dev

This commit is contained in:
Vce 2024-06-25 14:58:00 +08:00
commit 814e53ad9e
8 changed files with 134 additions and 57 deletions

View File

@ -40,10 +40,10 @@ const outPie = ref([
// //
async function getSpecialInfo() { async function getSpecialInfo() {
let data = { let data = {
projectSn: '', projectSn: store.sn,
} }
if(BASEURL == 'http://182.90.224.237:51234' || BASEURL == 'http://192.168.34.221:9111') data.projectSn = 'BD3137498CB84BF0969979E0342CDBCA' // if(BASEURL == 'http://182.90.224.237:51234' || BASEURL == 'http://192.168.34.221:9111') data.projectSn = 'BD3137498CB84BF0969979E0342CDBCA'
if(BASEURL == 'http://42.180.188.17:9809' || BASEURL == 'http://42.180.188.17:11211') data.projectSn = '471568F45EB247A3912A0D10EA1BFCEB' // if(BASEURL == 'http://42.180.188.17:9809' || BASEURL == 'http://42.180.188.17:11211') data.projectSn = '471568F45EB247A3912A0D10EA1BFCEB'
await getStatBySpecialApi(data).then(res => { await getStatBySpecialApi(data).then(res => {
if(res.success){ if(res.success){
if(res.result){ if(res.result){

View File

@ -49,10 +49,10 @@
<div>{{ item.jlNotPerformNum || 0 }}/{{ item.jlInServiceNum || 0 }}</div> <div>{{ item.jlNotPerformNum || 0 }}/{{ item.jlInServiceNum || 0 }}</div>
</div> </div>
</el-scrollbar> </el-scrollbar>
</div> <div class="not-data" v-if="performanceAnalysisList.length == 0">
<div class="not-data" v-if="performanceAnalysisList.length == 0"> <img src="@/assets/images/noData.png" alt="" />
<img src="@/assets/images/noData.png" alt="" /> <p>暂无数据</p>
<p>暂无数据</p> </div>
</div> </div>
</div> </div>
</div> </div>
@ -183,6 +183,7 @@ onMounted(async () => {
.leftTop { .leftTop {
width: 100%; width: 100%;
height: 100%; height: 100%;
.top-content { .top-content {
width: 18%; width: 18%;
position: absolute; position: absolute;
@ -191,6 +192,7 @@ onMounted(async () => {
display: flex; display: flex;
align-items: center; align-items: center;
justify-content: space-between; justify-content: space-between;
span { span {
font-family: ABeeZee, ABeeZee; font-family: ABeeZee, ABeeZee;
font-weight: normal; font-weight: normal;
@ -203,19 +205,23 @@ onMounted(async () => {
text-transform: none; text-transform: none;
cursor: pointer; cursor: pointer;
} }
.active { .active {
color: #ffffff; color: #ffffff;
} }
} }
.box-content { .box-content {
width: 100%; width: 100%;
height: 100%; height: 100%;
padding-top: 1%; padding-top: 1%;
.remark-top-data { .remark-top-data {
display: flex; display: flex;
align-items: center; align-items: center;
justify-content: space-around; justify-content: space-around;
margin-bottom: 2%; margin-bottom: 2%;
.top-data-item { .top-data-item {
width: 135px; width: 135px;
height: 51px; height: 51px;
@ -225,30 +231,37 @@ onMounted(async () => {
flex-direction: column; flex-direction: column;
padding: 0.5% 0; padding: 0.5% 0;
padding-left: 2%; padding-left: 2%;
span:nth-child(1) { span:nth-child(1) {
font-size: 16px; font-size: 16px;
color: #fff; color: #fff;
font-family: ABeeZee-Regular; font-family: ABeeZee-Regular;
margin-bottom: 1%; margin-bottom: 1%;
} }
span:nth-child(2) { span:nth-child(2) {
font-size: 24px; font-size: 24px;
color: #65d7f9; color: #65d7f9;
font-family: ABeeZee-Regular; font-family: ABeeZee-Regular;
} }
} }
.top-data-item:not(:last-child) { .top-data-item:not(:last-child) {
margin-right: 2%; margin-right: 2%;
} }
} }
.remark-bottom-table { .remark-bottom-table {
height: 62%; height: 62%;
box-sizing: border-box; box-sizing: border-box;
margin: 0 2%; margin: 0 2%;
position: relative; position: relative;
.list-content { .list-content {
height: 95%; height: 95%;
width: 100%; width: 100%;
position: relative;
.tab-list { .tab-list {
display: flex; display: flex;
align-items: center; align-items: center;
@ -260,6 +273,7 @@ onMounted(async () => {
top: 75%; top: 75%;
color: #ccc; color: #ccc;
font-size: 16px; font-size: 16px;
// justify-content: space-around; // justify-content: space-around;
div { div {
width: 25%; width: 25%;
@ -267,8 +281,10 @@ onMounted(async () => {
white-space: nowrap; white-space: nowrap;
} }
} }
.list-box { .list-box {
height: 82%; height: 82%;
.listStyle { .listStyle {
display: flex; display: flex;
align-items: center; align-items: center;
@ -278,23 +294,29 @@ onMounted(async () => {
margin-top: 0.5%; margin-top: 0.5%;
cursor: pointer; cursor: pointer;
background: rgba(0, 122, 255, 0.06); background: rgba(0, 122, 255, 0.06);
div { div {
width: 25%; width: 25%;
text-align: center; text-align: center;
white-space: nowrap; white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
} }
} }
.listStyle:hover { .listStyle:hover {
background: rgba(0, 122, 255, 0.43); background: rgba(0, 122, 255, 0.43);
} }
} }
} }
} }
.member-top-data { .member-top-data {
display: flex; display: flex;
align-items: center; align-items: center;
justify-content: center; justify-content: center;
margin-bottom: 2%; margin-bottom: 2%;
.top-data-item { .top-data-item {
width: 135px; width: 135px;
height: 51px; height: 51px;
@ -304,30 +326,36 @@ onMounted(async () => {
flex-direction: column; flex-direction: column;
padding: 0.5% 0; padding: 0.5% 0;
padding-left: 2%; padding-left: 2%;
span:nth-child(1) { span:nth-child(1) {
font-size: 16px; font-size: 16px;
color: #fff; color: #fff;
font-family: ABeeZee-Regular; font-family: ABeeZee-Regular;
margin-bottom: 1%; margin-bottom: 1%;
} }
span:nth-child(2) { span:nth-child(2) {
font-size: 24px; font-size: 24px;
color: #65d7f9; color: #65d7f9;
font-family: ABeeZee-Regular; font-family: ABeeZee-Regular;
} }
} }
.top-data-item:not(:last-child) { .top-data-item:not(:last-child) {
margin-right: 2%; margin-right: 2%;
} }
} }
.member-bottom-table { .member-bottom-table {
height: 62%; height: 62%;
box-sizing: border-box; box-sizing: border-box;
margin: 0 2%; margin: 0 2%;
position: relative; position: relative;
.list-content { .list-content {
height: 95%; height: 95%;
width: 100%; width: 100%;
.tab-list { .tab-list {
display: flex; display: flex;
align-items: center; align-items: center;
@ -339,6 +367,7 @@ onMounted(async () => {
top: 75%; top: 75%;
color: #ccc; color: #ccc;
font-size: 16px; font-size: 16px;
// justify-content: space-around; // justify-content: space-around;
div { div {
width: 17%; width: 17%;
@ -346,8 +375,10 @@ onMounted(async () => {
white-space: nowrap; white-space: nowrap;
} }
} }
.list-box { .list-box {
height: 82%; height: 82%;
.listStyle { .listStyle {
display: flex; display: flex;
align-items: center; align-items: center;
@ -357,34 +388,45 @@ onMounted(async () => {
margin-top: 0.5%; margin-top: 0.5%;
cursor: pointer; cursor: pointer;
background: rgba(0, 122, 255, 0.06); background: rgba(0, 122, 255, 0.06);
div { div {
width: 17%; width: 17%;
text-align: center; text-align: center;
white-space: nowrap; white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
} }
} }
.listStyle:hover { .listStyle:hover {
background: rgba(0, 122, 255, 0.43); background: rgba(0, 122, 255, 0.43);
} }
} }
} }
} }
.not-data {
top: 40%;
width: 30%;
left: 35%;
position: absolute;
text-align: center;
img {
width: 50%;
}
p {
color: #fff;
font-size: 14px;
}
}
} }
} }
.not-data {
width: 22%;
height: 50%;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
position: absolute;
text-align: center;
img {
width: 50%;
height: 100%;
}
p {
color: #fff;
font-size: 14px;
}
}
::v-deep .h-card .content { ::v-deep .h-card .content {
height: 80%; height: 80%;
margin-top: 1.8%; margin-top: 1.8%;

View File

@ -179,6 +179,7 @@ const activeIfo = reactive({
}); });
const randerInfo = reactive({ const randerInfo = reactive({
id: "radarMap2", id: "radarMap2",
fontSize: 12,
isLegend: "right", isLegend: "right",
radarCenter: ["34%", "50%"], radarCenter: ["34%", "50%"],
radius: "63%", radius: "63%",
@ -194,7 +195,7 @@ const randerInfo = reactive({
{ name: "人员风险概率", max: 1 }, { name: "人员风险概率", max: 1 },
{ name: "特殊作业风险概率", max: 1 }, { name: "特殊作业风险概率", max: 1 },
{ name: "月度安全评分", max: 1 }, { name: "月度安全评分", max: 1 },
{ name: "隐患未整改占比", max: 1 } { name: "隐患未闭合占比", max: 1 }
], ],
titleInfo: { titleInfo: {
titleLeft: "未来三天事故风险概率预测", titleLeft: "未来三天事故风险概率预测",
@ -231,6 +232,7 @@ const openDialogData = async () => {
res.result.forEach((item: any, index: number) => { res.result.forEach((item: any, index: number) => {
resultList.push({ resultList.push({
id: `list${index}`, id: `list${index}`,
fontSize: 12,
radius: "70%", radius: "70%",
isLegend: "top", isLegend: "top",
radarCenter: ["50%", "60%"], radarCenter: ["50%", "60%"],
@ -252,7 +254,7 @@ const openDialogData = async () => {
{ name: "人员风险概率", max: 1 }, { name: "人员风险概率", max: 1 },
{ name: "特殊作业风险概率", max: 1 }, { name: "特殊作业风险概率", max: 1 },
{ name: "月度安全评分", max: 1 }, { name: "月度安全评分", max: 1 },
{ name: "隐患未整改占比", max: 1 } { name: "隐患未闭合占比", max: 1 }
], ],
titleInfo: { titleInfo: {
titleLeft: "未来三天事故风险概率预测", titleLeft: "未来三天事故风险概率预测",

View File

@ -164,6 +164,7 @@ const store = GlobalStore();
const randerInfo = reactive({ const randerInfo = reactive({
id: "radarMap1", id: "radarMap1",
fontSize: 12,
isLegend: "right", isLegend: "right",
radarCenter: ["34%", "50%"], radarCenter: ["34%", "50%"],
radius: "65%", radius: "65%",
@ -180,7 +181,7 @@ const randerInfo = reactive({
{ name: "未闭合隐患", max: 1 }, { name: "未闭合隐患", max: 1 },
{ name: "特殊工种人员", max: 1 }, { name: "特殊工种人员", max: 1 },
{ name: "平均安全绩效评分", max: 1 }, { name: "平均安全绩效评分", max: 1 },
{ name: "平均培训通过率", max: 1 } { name: "平均培训通过率", max: 1 }
], ],
titleInfo: { titleInfo: {
titleLeft: "未来三天人员风险概率预测", titleLeft: "未来三天人员风险概率预测",
@ -208,12 +209,13 @@ const openDialogData = async () => {
res.result.forEach((item: any, index: number) => { res.result.forEach((item: any, index: number) => {
resultList.push({ resultList.push({
id: `list${index}`, id: `list${index}`,
radius: "70%", fontSize: 12,
radius: "60%",
isLegend: "top", isLegend: "top",
radarCenter: ["50%", "60%"], radarCenter: ["50%", "56%"],
dataList: [ dataList: [
{ {
value: [item.age, 1, item.safe, item.workerType, item.security, item.exam], value: [item.age, 1, item.security, item.workerType, item.safe, item.exam],
name: item.enterpriseName name: item.enterpriseName
// areaStyle: {} // areaStyle: {}
} }
@ -224,7 +226,7 @@ const openDialogData = async () => {
{ name: "未闭合隐患", max: 1 }, { name: "未闭合隐患", max: 1 },
{ name: "特殊工种人员", max: 1 }, { name: "特殊工种人员", max: 1 },
{ name: "平均安全绩效评分", max: 1 }, { name: "平均安全绩效评分", max: 1 },
{ name: "平均培训通过率", max: 1 } { name: "平均培训通过率", max: 1 }
], ],
titleInfo: { titleInfo: {
titleLeft: "未来三天人员风险概率预测", titleLeft: "未来三天人员风险概率预测",
@ -232,7 +234,7 @@ const openDialogData = async () => {
percentage: item.area percentage: item.area
}, },
workerFlag: true, workerFlag: true,
workerList: [item.age, item.total, item.safe, item.workerType, item.security, item.exam] workerList: [item.age, item.total, item.security, item.workerType, item.safe, item.exam]
}); });
}); });
} }
@ -507,17 +509,17 @@ const getWorkerRiskByProject = async (showLoading: boolean, val: number) => {
randerInfo.dataList[0].value = [ randerInfo.dataList[0].value = [
res.result.age, res.result.age,
1, 1,
res.result.safe,
res.result.workerType,
res.result.security, res.result.security,
res.result.workerType,
res.result.safe,
res.result.exam res.result.exam
]; ];
randerInfo.workerList = [ randerInfo.workerList = [
res.result.age, res.result.age,
res.result.total, res.result.total,
res.result.safe,
res.result.workerType,
res.result.security, res.result.security,
res.result.workerType,
res.result.safe,
res.result.exam res.result.exam
]; ];
randerInfo.titleInfo.percentage = res.result.area; randerInfo.titleInfo.percentage = res.result.area;

View File

@ -223,12 +223,13 @@ const openDialogData = async () => {
res.result.forEach((item: any, index: number) => { res.result.forEach((item: any, index: number) => {
resultList.push({ resultList.push({
id: `list${index}`, id: `list${index}`,
fontSize: 12,
radius: "60%", radius: "60%",
isLegend: "top", isLegend: "top",
radarCenter: ["50%", "55%"], radarCenter: ["50%", "55%"],
dataList: [ dataList: [
{ {
value: [item.security, item.safe, item.levelRisk, item.limitTime], value: [item.security, item.safe, item.levelRisk, item.total, item.limitTime],
name: item.enterpriseName name: item.enterpriseName
// areaStyle: {} // areaStyle: {}
} }
@ -237,6 +238,7 @@ const openDialogData = async () => {
{ name: "隐患未闭合", max: 1 }, { name: "隐患未闭合", max: 1 },
{ name: "平均安全绩效评分", max: 1 }, { name: "平均安全绩效评分", max: 1 },
{ name: "重大、较大隐患", max: 1 }, { name: "重大、较大隐患", max: 1 },
{ name: "总隐患数量", max: 1 },
{ name: "隐患超期整改", max: 1 } { name: "隐患超期整改", max: 1 }
], ],
titleInfo: { titleInfo: {
@ -245,7 +247,7 @@ const openDialogData = async () => {
percentage: item.area percentage: item.area
}, },
workerFlag: true, workerFlag: true,
workerList: [item.security, item.safe, item.levelRisk, item.limitTime] workerList: [item.security, item.safe, item.levelRisk, item.total, item.limitTime]
}); });
}); });
} }
@ -280,9 +282,10 @@ const activeInfo = reactive({
}); });
const randerInfo = reactive({ const randerInfo = reactive({
id: "radarMap3", id: "radarMap3",
fontSize: 10,
isLegend: "right", isLegend: "right",
radarCenter: ["34%", "50%"], radarCenter: ["34%", "50%"],
radius: "55%", radius: "68%",
dataList: [ dataList: [
{ {
value: [0, 0, 0, 0], value: [0, 0, 0, 0],
@ -306,9 +309,10 @@ const randerInfo = reactive({
}); });
const randerInfo2 = reactive({ const randerInfo2 = reactive({
id: "radarMap4", id: "radarMap4",
fontSize: 10,
isLegend: "right", isLegend: "right",
radarCenter: ["34%", "50%"], radarCenter: ["34%", "50%"],
radius: "55%", radius: "70%",
dataList: [ dataList: [
{ {
value: [0, 0, 0, 0, 0, 0, 0, 0], value: [0, 0, 0, 0, 0, 0, 0, 0],

View File

@ -1,6 +1,6 @@
<template> <template>
<div class="radarMapOption"> <div class="radarMapOption">
<div class="header"> <div class="header" :class="{ 'justify-center': !props.randerInfo.titleInfo.titleRight }">
<div style="display: flex"> <div style="display: flex">
<span>{{ props.randerInfo.titleInfo.titleLeft }}:</span> <span>{{ props.randerInfo.titleInfo.titleLeft }}:</span>
<div class="numberCard" v-for="(item, i) in props.randerInfo.titleInfo.percentage.toString()" :key="i"> <div class="numberCard" v-for="(item, i) in props.randerInfo.titleInfo.percentage.toString()" :key="i">
@ -58,15 +58,15 @@ function radarMapEchart() {
'<div style="display:flex;justify-content:space-between;"><div>' + '<div style="display:flex;justify-content:space-between;"><div>' +
props.randerInfo.indicator[index].name + props.randerInfo.indicator[index].name +
"" + "" +
item * 100 + (item * 100).toFixed(2) +
"%</div>"; "%</div>";
} else { } else {
htmlobj = "<div>" + props.randerInfo.indicator[index].name + "" + item * 100 + "%</div></div>"; htmlobj = "<div>" + props.randerInfo.indicator[index].name + "" + (item * 100).toFixed(2) + "%</div></div>";
} }
return htmlobj; return htmlobj;
}) })
.join(""); .join("");
console.log(11111111, textHTML); // console.log(11111111, textHTML);
return textHTML; return textHTML;
} }
} }
@ -85,12 +85,12 @@ function radarMapEchart() {
const itemUp = const itemUp =
props.randerInfo.workerList[index] > 1 props.randerInfo.workerList[index] > 1
? props.randerInfo.workerList[index] ? props.randerInfo.workerList[index]
: props.randerInfo.workerList[index] * 100 + "%"; : (props.randerInfo.workerList[index] * 100).toFixed(2) + "%";
htmlobj = "<div>" + props.randerInfo.indicator[index].name + "" + itemUp + "</div>"; htmlobj = "<div>" + props.randerInfo.indicator[index].name + "" + itemUp + "</div>";
return htmlobj; return htmlobj;
}) })
.join(""); .join("");
console.log(11111111, textHTML); // console.log(11111111, textHTML);
return textHTML; return textHTML;
} }
} }
@ -104,13 +104,13 @@ function radarMapEchart() {
position: "inside" position: "inside"
} }
: { top: "2%" }; : { top: "2%" };
console.log(props.randerInfo.dataList); console.log(props.randerInfo.dataList, props.randerInfo.fontSize);
let option = { let option = {
legend: { legend: {
...isLegend, ...isLegend,
textStyle: { textStyle: {
color: "#AAAAAA", color: "#AAAAAA",
fontSize: 10 fontSize: props.randerInfo.fontSize > 10 ? props.randerInfo.fontSize : 10
}, },
itemWidth: 20, itemWidth: 20,
itemHeight: 10, itemHeight: 10,
@ -134,8 +134,12 @@ function radarMapEchart() {
}, },
axisName: { axisName: {
color: "#AAAAAA", color: "#AAAAAA",
fontSize: 10 fontSize: props.randerInfo.fontSize ? props.randerInfo.fontSize : 10
}, },
name: {
fontSize: props.randerInfo.fontSize ? props.randerInfo.fontSize : 10
},
nameGap: 8,
splitArea: { splitArea: {
areaStyle: { areaStyle: {
color: ["#3F3C54", "#373551"], color: ["#3F3C54", "#373551"],
@ -146,7 +150,7 @@ function radarMapEchart() {
}, },
series: [ series: [
{ {
name: "Budget vs spending", // name: "Budget vs spending",
type: "radar", type: "radar",
data: props.randerInfo.dataList data: props.randerInfo.dataList
} }
@ -169,6 +173,9 @@ onMounted(async () => {
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.justify-center {
justify-content: center !important;
}
.radarMapOption { .radarMapOption {
width: 100%; width: 100%;
height: 100%; height: 100%;

View File

@ -103,13 +103,13 @@ const login = (formEl: FormInstance | undefined) => {
// console.log(COMPANY,666777) // console.log(COMPANY,666777)
if (COMPANY === "agjtCommand") { if (COMPANY === "agjtCommand") {
// menuList.value = AGJTCommandMenu; // menuList.value = AGJTCommandMenu;
// if (![5, 10].includes(result.accountType)) { if (![5, 10].includes(result.accountType)) {
// ElMessage({ ElMessage({
// message: "", message: "账号类型不匹配",
// type: "warning" type: "warning"
// }); });
// return; return;
// } }
router.push("/commandScreen"); router.push("/commandScreen");
} else if (COMPANY === "agjtProjectKanban") { } else if (COMPANY === "agjtProjectKanban") {
if (![5, 10].includes(result.accountType)) { if (![5, 10].includes(result.accountType)) {
@ -130,8 +130,14 @@ const login = (formEl: FormInstance | undefined) => {
return; return;
} }
router.push("/agjtLiveScreen"); router.push("/agjtLiveScreen");
} else if (COMPANY === "agjtOverview") {
} else if (COMPANY === "agjtOverviewScreen") { } else if (COMPANY === "agjtOverviewScreen") {
if (![5, 10].includes(result.accountType)) {
ElMessage({
message: "账号类型不匹配",
type: "warning"
});
return;
}
router.push("/overviewScreen"); router.push("/overviewScreen");
} else { } else {
router.push("/projectOverview"); router.push("/projectOverview");

View File

@ -658,8 +658,10 @@ function getManAnalysisEchart() {
}, },
legend: { legend: {
trigger: "item", trigger: "item",
type: "scroll", //legend
position: "inside", position: "inside",
top: "3%", top: "2%",
left: "1%",
x: "center", x: "center",
textStyle: { textStyle: {
color: "#fff" color: "#fff"
@ -667,7 +669,19 @@ function getManAnalysisEchart() {
itemWidth: 10, itemWidth: 10,
itemHeight: 10, itemHeight: 10,
icon: "roundRect", icon: "roundRect",
data: workerRegionInfo.workerRegionList.map((item: any) => item.regionName) data: workerRegionInfo.workerRegionList.map((item: any) => item.regionName),
formatter: function (data: any) {
if (workerRegionInfo.workerRegionList && workerRegionInfo.workerRegionList.length) {
for (let i = 0; i < workerRegionInfo.workerRegionList.length; i++) {
if (data === workerRegionInfo.workerRegionList[i].regionName) {
if (data == "无") return;
const newData = data.length > 5 ? data.substr(0, 5) + "..." : data;
return newData;
}
}
}
}
}, },
// color: ["#2BA5FF", "#F97766", "#1EF1FF", "#1EF1FF"], // color: ["#2BA5FF", "#F97766", "#1EF1FF", "#1EF1FF"],
grid: { grid: {