Merge branch 'main' of http://47.122.43.22:3000/wjn/mh-sms-web
This commit is contained in:
commit
81978ff082
@ -192,6 +192,7 @@ class BI001HomeDetail extends React.Component {
|
||||
{
|
||||
title: "车间",
|
||||
dataIndex: "shopName",
|
||||
onCell: () => this.renderSpeedColumn(),
|
||||
render: (value, record, index) => {
|
||||
const obj = {
|
||||
children: value,
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@ -36,9 +36,27 @@ class BI013RiskAnalysisModel extends React.Component {
|
||||
} else {
|
||||
currentMineType = localStorage.getItem("currentMineType");
|
||||
}
|
||||
this.getBaseInfoData(currentMineType);
|
||||
// this.getBaseInfoData(currentMineType);
|
||||
this.getBaseData();
|
||||
}
|
||||
|
||||
getBaseData = () => {
|
||||
this.setState({
|
||||
LEVEL1TOTAL: 0,
|
||||
LEVEL2TOTAL: 82,
|
||||
LEVEL3TOTAL: 381,
|
||||
LEVEL4TOTAL: 2212,
|
||||
HAZARDTOTALCOUNT: 50,
|
||||
RISKTOTALCOUNT: 2714,
|
||||
MEASURESTOTALCOUNT: 653,
|
||||
},()=>{
|
||||
this.chart1();
|
||||
this.chart2();
|
||||
this.chart4();
|
||||
});
|
||||
|
||||
};
|
||||
|
||||
//获取数据
|
||||
getBaseInfoData = (mineType) => {
|
||||
const json2 = initFilter(this.props.login.OrgId);
|
||||
@ -71,6 +89,7 @@ class BI013RiskAnalysisModel extends React.Component {
|
||||
RISKTOTALCOUNT: ret.Data.RISKTOTALCOUNT,
|
||||
MEASURESTOTALCOUNT: ret.Data.MEASURESTOTALCOUNT,
|
||||
});
|
||||
|
||||
// this.state.LEVEL1TOTAL = level1all;
|
||||
// this.state.LEVEL2TOTAL = level2all;
|
||||
// this.state.LEVEL3TOTAL = level3all;
|
||||
@ -108,295 +127,340 @@ class BI013RiskAnalysisModel extends React.Component {
|
||||
|
||||
let chart1s = document.getElementById("chartone");
|
||||
let myChart = echarts.init(chart1s);
|
||||
myChart.setOption({
|
||||
color: color,
|
||||
title: [
|
||||
{
|
||||
text: "风险分级占比1",
|
||||
left: "center",
|
||||
top: "2%",
|
||||
},
|
||||
{
|
||||
text: allNum,
|
||||
x: "26%",
|
||||
y: "center",
|
||||
textStyle: {
|
||||
fontSize: 26,
|
||||
fontWeight: "normal",
|
||||
color: ["#333"],
|
||||
myChart.setOption(
|
||||
{
|
||||
color: color,
|
||||
title: [
|
||||
{
|
||||
text: "风险分级占比1",
|
||||
left: "center",
|
||||
top: "2%",
|
||||
},
|
||||
},
|
||||
],
|
||||
tooltip: {
|
||||
trigger: "item",
|
||||
formatter: "{b}:({d}%)",
|
||||
},
|
||||
legend: {
|
||||
orient: "vartical",
|
||||
x: "left",
|
||||
top: "35%",
|
||||
left: "65%",
|
||||
bottom: "0%",
|
||||
data: showData,
|
||||
// itemWidth: 20,
|
||||
// itemHeight: 14,
|
||||
// itemGap :15,
|
||||
formatter: function (name) {
|
||||
//通过name获取到数组对象中的单个对象
|
||||
let singleData = showData.filter(function (item) {
|
||||
return item.name == name;
|
||||
});
|
||||
let countAll = 0;
|
||||
showData.map((item) => {
|
||||
countAll = countAll + item.value;
|
||||
});
|
||||
|
||||
return (
|
||||
name +
|
||||
" | " +
|
||||
singleData[0].value +
|
||||
" | " +
|
||||
Number((singleData[0].value / countAll) * 100).toFixed(2) +
|
||||
"%"
|
||||
);
|
||||
},
|
||||
},
|
||||
grid: {
|
||||
left: 30,
|
||||
containLabel: true,
|
||||
bottom: 10,
|
||||
top: 10,
|
||||
right: 30,
|
||||
},
|
||||
series: [
|
||||
{
|
||||
name: "访问来源",
|
||||
type: "pie",
|
||||
clockwise: false,
|
||||
// minAngle: 20,
|
||||
avoidLabelOverlap: false,
|
||||
radius: ["45%", "65%"],
|
||||
center: ["30%", "50%"],
|
||||
itemStyle: {
|
||||
//图形样式
|
||||
normal: {
|
||||
borderColor: "#ffffff",
|
||||
borderWidth: 1,
|
||||
padding: "0 20px",
|
||||
{
|
||||
text: allNum,
|
||||
x: "26%",
|
||||
y: "center",
|
||||
textStyle: {
|
||||
fontSize: 26,
|
||||
fontWeight: "normal",
|
||||
color: ["#333"],
|
||||
},
|
||||
},
|
||||
label: {
|
||||
show: false,
|
||||
},
|
||||
// color: color,
|
||||
data: showData,
|
||||
},
|
||||
],
|
||||
}, true);
|
||||
};
|
||||
chart2 = (data) => {
|
||||
let areaName = [];
|
||||
let areaCount = [];
|
||||
data.forEach((item) => {
|
||||
areaName.push(item.AREANAME);
|
||||
areaCount.push(item.AREACOUNT);
|
||||
});
|
||||
let chart2s = document.getElementById("chart2");
|
||||
if (chart2s) {
|
||||
let myChart = echarts.init(chart2s);
|
||||
myChart.setOption({
|
||||
title: {
|
||||
text: "风险区域统计",
|
||||
left: "center",
|
||||
top: "2%",
|
||||
},
|
||||
],
|
||||
tooltip: {
|
||||
trigger: "axis",
|
||||
axisPointer: {
|
||||
type: "shadow",
|
||||
trigger: "item",
|
||||
formatter: "{b}:({d}%)",
|
||||
},
|
||||
legend: {
|
||||
orient: "vartical",
|
||||
x: "left",
|
||||
top: "35%",
|
||||
left: "65%",
|
||||
bottom: "0%",
|
||||
data: showData,
|
||||
// itemWidth: 20,
|
||||
// itemHeight: 14,
|
||||
// itemGap :15,
|
||||
formatter: function (name) {
|
||||
//通过name获取到数组对象中的单个对象
|
||||
let singleData = showData.filter(function (item) {
|
||||
return item.name == name;
|
||||
});
|
||||
let countAll = 0;
|
||||
showData.map((item) => {
|
||||
countAll = countAll + item.value;
|
||||
});
|
||||
|
||||
return (
|
||||
name +
|
||||
" | " +
|
||||
singleData[0].value +
|
||||
" | " +
|
||||
Number((singleData[0].value / countAll) * 100).toFixed(2) +
|
||||
"%"
|
||||
);
|
||||
},
|
||||
},
|
||||
grid: {
|
||||
left: "3%",
|
||||
right: "4%",
|
||||
top: "10%",
|
||||
bottom: "1%",
|
||||
left: 30,
|
||||
containLabel: true,
|
||||
bottom: 10,
|
||||
top: 10,
|
||||
right: 30,
|
||||
},
|
||||
xAxis: {
|
||||
show: false,
|
||||
},
|
||||
yAxis: [
|
||||
series: [
|
||||
{
|
||||
triggerEvent: true,
|
||||
show: true,
|
||||
inverse: false,
|
||||
data: areaName,
|
||||
axisLine: {
|
||||
name: "访问来源",
|
||||
type: "pie",
|
||||
clockwise: false,
|
||||
// minAngle: 20,
|
||||
avoidLabelOverlap: false,
|
||||
radius: ["45%", "65%"],
|
||||
center: ["30%", "50%"],
|
||||
itemStyle: {
|
||||
//图形样式
|
||||
normal: {
|
||||
borderColor: "#ffffff",
|
||||
borderWidth: 1,
|
||||
padding: "0 20px",
|
||||
},
|
||||
},
|
||||
label: {
|
||||
show: false,
|
||||
},
|
||||
splitLine: {
|
||||
show: false,
|
||||
// color: color,
|
||||
data: showData,
|
||||
},
|
||||
],
|
||||
},
|
||||
true
|
||||
);
|
||||
};
|
||||
chart2 = (data) => {
|
||||
let areaName = [
|
||||
"破碎车间-粗碎单元",
|
||||
"综合回收车间-精多金属仓库单元",
|
||||
"磨重车间-脱泥单元",
|
||||
"食堂",
|
||||
"综合回收车间-精矿烘干单元",
|
||||
"尾矿库截渗池回水单元",
|
||||
"破碎车间-辊磨单元",
|
||||
"磨重车间-中矿再磨单元",
|
||||
"磨重车间-粗粒选别单元",
|
||||
"加油站-采场",
|
||||
"尾矿库截洪单元",
|
||||
"采场道路",
|
||||
"破碎车间-放矿运输单元",
|
||||
"卢家边回水单元",
|
||||
"钨细泥回收车间-回水单元",
|
||||
"综合回收车间-硫化矿综合回收单元",
|
||||
"磨重车间-细粒选别单元",
|
||||
"尾矿库库区",
|
||||
"磨重车间-磨矿分级单元",
|
||||
"截渗池回水单元",
|
||||
];
|
||||
let areaCount = [
|
||||
1, 2, 3, 3, 4, 4, 6, 9, 9, 11, 19, 20, 21, 22, 22, 23, 27, 31, 32, 32,
|
||||
];
|
||||
// data.forEach((item) => {
|
||||
// areaName.push(item.AREANAME);
|
||||
// areaCount.push(item.AREACOUNT);
|
||||
// });
|
||||
let chart2s = document.getElementById("chart2");
|
||||
if (chart2s) {
|
||||
let myChart = echarts.init(chart2s);
|
||||
myChart.setOption(
|
||||
{
|
||||
title: {
|
||||
text: "风险区域统计",
|
||||
left: "center",
|
||||
top: "2%",
|
||||
},
|
||||
tooltip: {
|
||||
trigger: "axis",
|
||||
axisPointer: {
|
||||
type: "shadow",
|
||||
},
|
||||
axisTick: {
|
||||
show: false,
|
||||
},
|
||||
axisLabel: {
|
||||
interval: 0,
|
||||
color: "#666",
|
||||
align: "right",
|
||||
margin: 20,
|
||||
fontSize: 13,
|
||||
},
|
||||
grid: {
|
||||
left: "3%",
|
||||
right: "4%",
|
||||
top: "10%",
|
||||
bottom: "1%",
|
||||
containLabel: true,
|
||||
},
|
||||
xAxis: {
|
||||
show: false,
|
||||
},
|
||||
yAxis: [
|
||||
{
|
||||
triggerEvent: true,
|
||||
show: true,
|
||||
inverse: false,
|
||||
data: areaName,
|
||||
axisLine: {
|
||||
show: false,
|
||||
},
|
||||
splitLine: {
|
||||
show: false,
|
||||
},
|
||||
axisTick: {
|
||||
show: false,
|
||||
},
|
||||
axisLabel: {
|
||||
interval: 0,
|
||||
color: "#666",
|
||||
align: "right",
|
||||
margin: 20,
|
||||
fontSize: 13,
|
||||
|
||||
rich: {
|
||||
idx0: {
|
||||
color: "#FB375E",
|
||||
backgroundColor: "#FFE8EC",
|
||||
borderRadius: 100,
|
||||
padding: [5, 8],
|
||||
},
|
||||
idx1: {
|
||||
color: "#FF9023",
|
||||
backgroundColor: "#FFEACF",
|
||||
borderRadius: 100,
|
||||
padding: [5, 8],
|
||||
},
|
||||
idx2: {
|
||||
color: "#01B599",
|
||||
backgroundColor: "#E1F7F3",
|
||||
borderRadius: 100,
|
||||
padding: [5, 8],
|
||||
},
|
||||
idx: {
|
||||
color: "#333",
|
||||
borderRadius: 100,
|
||||
padding: [5, 8],
|
||||
},
|
||||
title: {
|
||||
width: 165,
|
||||
rich: {
|
||||
idx0: {
|
||||
color: "#FB375E",
|
||||
backgroundColor: "#FFE8EC",
|
||||
borderRadius: 100,
|
||||
padding: [5, 8],
|
||||
},
|
||||
idx1: {
|
||||
color: "#FF9023",
|
||||
backgroundColor: "#FFEACF",
|
||||
borderRadius: 100,
|
||||
padding: [5, 8],
|
||||
},
|
||||
idx2: {
|
||||
color: "#01B599",
|
||||
backgroundColor: "#E1F7F3",
|
||||
borderRadius: 100,
|
||||
padding: [5, 8],
|
||||
},
|
||||
idx: {
|
||||
color: "#333",
|
||||
borderRadius: 100,
|
||||
padding: [5, 8],
|
||||
},
|
||||
title: {
|
||||
width: 165,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
triggerEvent: true,
|
||||
show: true,
|
||||
inverse: false,
|
||||
data: areaCount,
|
||||
axisLine: {
|
||||
{
|
||||
triggerEvent: true,
|
||||
show: true,
|
||||
inverse: false,
|
||||
data: areaCount,
|
||||
axisLine: {
|
||||
show: false,
|
||||
},
|
||||
splitLine: {
|
||||
show: false,
|
||||
},
|
||||
axisTick: {
|
||||
show: false,
|
||||
},
|
||||
axisLabel: {
|
||||
interval: 0,
|
||||
color: "#666",
|
||||
align: "left",
|
||||
margin: 20,
|
||||
fontSize: 12,
|
||||
},
|
||||
},
|
||||
],
|
||||
series: [
|
||||
{
|
||||
name: "数量",
|
||||
type: "bar",
|
||||
// label: {
|
||||
// show: true,
|
||||
// position: "insideRight",
|
||||
// color: "#fff",
|
||||
// formatter: "{c}",
|
||||
// fontSize: "12",
|
||||
// },
|
||||
barWidth: 10,
|
||||
itemStyle: {
|
||||
color: "#1990FF",
|
||||
barBorderRadius: 30,
|
||||
},
|
||||
// itemStyle: {
|
||||
// color: new echarts.graphic.LinearGradient(0, 0, 1, 0, [
|
||||
// { offset: 0, color: "#01AEF6" },
|
||||
// { offset: 1, color: "#9999FF" },
|
||||
// ]),
|
||||
// },
|
||||
data: areaCount,
|
||||
show: false,
|
||||
},
|
||||
splitLine: {
|
||||
show: false,
|
||||
},
|
||||
axisTick: {
|
||||
show: false,
|
||||
},
|
||||
axisLabel: {
|
||||
interval: 0,
|
||||
color: "#666",
|
||||
align: "left",
|
||||
margin: 20,
|
||||
fontSize: 12,
|
||||
},
|
||||
},
|
||||
],
|
||||
series: [
|
||||
{
|
||||
name: "数量",
|
||||
type: "bar",
|
||||
// label: {
|
||||
// show: true,
|
||||
// position: "insideRight",
|
||||
// color: "#fff",
|
||||
// formatter: "{c}",
|
||||
// fontSize: "12",
|
||||
// },
|
||||
barWidth: 10,
|
||||
itemStyle: {
|
||||
color: "#1990FF",
|
||||
barBorderRadius: 30,
|
||||
},
|
||||
// itemStyle: {
|
||||
// color: new echarts.graphic.LinearGradient(0, 0, 1, 0, [
|
||||
// { offset: 0, color: "#01AEF6" },
|
||||
// { offset: 1, color: "#9999FF" },
|
||||
// ]),
|
||||
// },
|
||||
data: areaCount,
|
||||
show: false,
|
||||
},
|
||||
],
|
||||
}, true);
|
||||
],
|
||||
},
|
||||
true
|
||||
);
|
||||
}
|
||||
};
|
||||
|
||||
chart4 = (data) => {
|
||||
let riskArr = [];
|
||||
let hazardArr = [];
|
||||
let dates = [];
|
||||
for (let i = 0; i < data.length; i++) {
|
||||
if (data[i].TYPE == 0) {
|
||||
riskArr.push(data[i].COUNT);
|
||||
dates.push(moment(data[i].DATE).format("YYYY/MM"));
|
||||
} else {
|
||||
hazardArr.push(data[i].COUNT);
|
||||
}
|
||||
}
|
||||
let currMonth = dates.length;
|
||||
for (let i = 1; i < 13 - currMonth; i++) {
|
||||
dates.push(
|
||||
moment(dates[dates.length]).add(i, "months").format("YYYY/MM")
|
||||
);
|
||||
}
|
||||
let riskArr = [2714, 2714, 2714, 2714];
|
||||
let hazardArr = [50, 50, 50, 50];
|
||||
let dates = [
|
||||
"2024/01",
|
||||
"2024/02",
|
||||
"2024/03",
|
||||
"2024/04",
|
||||
"2024/05",
|
||||
"2024/06",
|
||||
"2024/07",
|
||||
"2024/08",
|
||||
"2024/09",
|
||||
"2024/10",
|
||||
"2024/11",
|
||||
"2024/12",
|
||||
];
|
||||
// for (let i = 0; i < data.length; i++) {
|
||||
// if (data[i].TYPE == 0) {
|
||||
// riskArr.push(data[i].COUNT);
|
||||
// dates.push(moment(data[i].DATE).format("YYYY/MM"));
|
||||
// } else {
|
||||
// hazardArr.push(data[i].COUNT);
|
||||
// }
|
||||
// }
|
||||
// let currMonth = dates.length;
|
||||
// for (let i = 1; i < 13 - currMonth; i++) {
|
||||
// dates.push(
|
||||
// moment(dates[dates.length]).add(i, "months").format("YYYY/MM")
|
||||
// );
|
||||
// }
|
||||
let chart4s = document.getElementById("chart4");
|
||||
if (chart4s) {
|
||||
let myChart = echarts.init(chart4s);
|
||||
myChart.setOption({
|
||||
color: ["#72b85b", "#f6841a", "#cc0404"],
|
||||
grid: {
|
||||
left: "5%",
|
||||
right: "5%",
|
||||
},
|
||||
legend: {
|
||||
bottom: "0px",
|
||||
},
|
||||
title: {
|
||||
text: "月度风险辨识统计走势",
|
||||
left: "center",
|
||||
top: "2%",
|
||||
},
|
||||
tooltip: {
|
||||
trigger: "axis",
|
||||
axisPointer: {
|
||||
type: "shadow",
|
||||
myChart.setOption(
|
||||
{
|
||||
color: ["#72b85b", "#f6841a", "#cc0404"],
|
||||
grid: {
|
||||
left: "5%",
|
||||
right: "5%",
|
||||
},
|
||||
},
|
||||
xAxis: {
|
||||
type: "category",
|
||||
data: dates,
|
||||
axisLabel: {
|
||||
showMaxLabel: true,
|
||||
legend: {
|
||||
bottom: "0px",
|
||||
},
|
||||
},
|
||||
yAxis: {
|
||||
type: "value",
|
||||
},
|
||||
series: [
|
||||
{
|
||||
name: "危险源/风险库",
|
||||
data: riskArr,
|
||||
type: "line",
|
||||
smooth: true,
|
||||
title: {
|
||||
text: "月度风险辨识统计走势",
|
||||
left: "center",
|
||||
top: "2%",
|
||||
},
|
||||
{
|
||||
name: "职业危害库",
|
||||
data: hazardArr,
|
||||
type: "line",
|
||||
smooth: true,
|
||||
tooltip: {
|
||||
trigger: "axis",
|
||||
axisPointer: {
|
||||
type: "shadow",
|
||||
},
|
||||
},
|
||||
],
|
||||
}, true);
|
||||
xAxis: {
|
||||
type: "category",
|
||||
data: dates,
|
||||
axisLabel: {
|
||||
showMaxLabel: true,
|
||||
},
|
||||
},
|
||||
yAxis: {
|
||||
type: "value",
|
||||
},
|
||||
series: [
|
||||
{
|
||||
name: "危险源/风险库",
|
||||
data: riskArr,
|
||||
type: "line",
|
||||
smooth: true,
|
||||
},
|
||||
{
|
||||
name: "职业危害库",
|
||||
data: hazardArr,
|
||||
type: "line",
|
||||
smooth: true,
|
||||
},
|
||||
],
|
||||
},
|
||||
true
|
||||
);
|
||||
}
|
||||
};
|
||||
render() {
|
||||
@ -539,7 +603,10 @@ class BI013RiskAnalysisModel extends React.Component {
|
||||
// className="dashboard-div-style"
|
||||
style={{ border: "1px solid rgb(232,232,232)" }}
|
||||
>
|
||||
<div id="chartone" style={{ width: "100%", height: "430px" }}></div>
|
||||
<div
|
||||
id="chartone"
|
||||
style={{ width: "100%", height: "430px" }}
|
||||
></div>
|
||||
</div>
|
||||
</Col>
|
||||
<Col span={10} style={{ height: "430px" }}>
|
||||
@ -568,7 +635,7 @@ class BI013RiskAnalysisModel extends React.Component {
|
||||
alignItems: "center",
|
||||
justifyContent: "space-around",
|
||||
border: "1px #888 solid",
|
||||
padding: "8px 0px"
|
||||
padding: "8px 0px",
|
||||
}}
|
||||
>
|
||||
<div
|
||||
@ -658,9 +725,7 @@ class BI013RiskAnalysisModel extends React.Component {
|
||||
<Row gutter={10} style={{ marginTop: "20px" }}>
|
||||
<Col span={1}></Col>
|
||||
<Col span={22}>
|
||||
<div
|
||||
style={{ border: "1px solid rgb(232,232,232)" }}
|
||||
>
|
||||
<div style={{ border: "1px solid rgb(232,232,232)" }}>
|
||||
<div id="chart4" style={{ width: "100%", height: "350px" }}></div>
|
||||
</div>
|
||||
</Col>
|
||||
|
||||
@ -151,10 +151,6 @@ class BI051BSCompanyYear extends React.Component {
|
||||
}
|
||||
});
|
||||
// COUNTTOTAL
|
||||
console.log(
|
||||
data.listSafeCheckYear[data.listSafeCheckYear.length - 1],
|
||||
"data.listSafeCheckYeardata.listSafeCheckYear"
|
||||
);
|
||||
var colorList = [
|
||||
"#47A2FF ",
|
||||
"#53C8D1",
|
||||
|
||||
@ -72,17 +72,16 @@ class BI054HomeDetail extends React.Component {
|
||||
Parent: {
|
||||
DepartmentName: "穿爆车间",
|
||||
RowCount: 2,
|
||||
listCount: [51, 751, 0, 0, 0],
|
||||
listCount: [51, 751, 0, 0],
|
||||
},
|
||||
Percent: 0,
|
||||
RowCount: 1,
|
||||
listCount: [0, 350, 0, 0, 0],
|
||||
listCount: [0, 350, 0, 0],
|
||||
listName: [
|
||||
"巡回检查",
|
||||
"例行检查",
|
||||
"专业检查",
|
||||
"综合检查",
|
||||
"综合检查",
|
||||
],
|
||||
},
|
||||
{
|
||||
@ -92,17 +91,16 @@ class BI054HomeDetail extends React.Component {
|
||||
Parent: {
|
||||
DepartmentName: "穿爆车间",
|
||||
RowCount: 2,
|
||||
listCount: [51, 751, 0, 0, 0],
|
||||
listCount: [51, 751, 0, 0],
|
||||
},
|
||||
Percent: 0,
|
||||
RowCount: 1,
|
||||
listCount: [0, 350, 0, 0, 0],
|
||||
listCount: [0, 350, 0, 0],
|
||||
listName: [
|
||||
"巡回检查",
|
||||
"例行检查",
|
||||
"专业检查",
|
||||
"综合检查",
|
||||
"综合检查",
|
||||
],
|
||||
},
|
||||
{
|
||||
@ -114,17 +112,16 @@ class BI054HomeDetail extends React.Component {
|
||||
Parent: {
|
||||
DepartmentName: "生产技术科",
|
||||
RowCount: 1,
|
||||
listCount: [51, 522, 0, 0, 0],
|
||||
listCount: [51, 522, 0, 0],
|
||||
},
|
||||
Percent: 0,
|
||||
RowCount: 1,
|
||||
listCount: [0, 349, 0, 0, 0],
|
||||
listCount: [0, 349, 0, 0],
|
||||
listName: [
|
||||
"巡回检查",
|
||||
"例行检查",
|
||||
"专业检查",
|
||||
"综合检查",
|
||||
"综合检查",
|
||||
],
|
||||
},
|
||||
{
|
||||
@ -134,17 +131,16 @@ class BI054HomeDetail extends React.Component {
|
||||
Parent: {
|
||||
DepartmentName: "综合组",
|
||||
RowCount: 1,
|
||||
listCount: [0, 349, 0, 0, 0],
|
||||
listCount: [0, 349, 0, 0],
|
||||
},
|
||||
Percent: 0,
|
||||
RowCount: 1,
|
||||
listCount: [0, 349, 0, 0, 0],
|
||||
listCount: [0, 349, 0, 0],
|
||||
listName: [
|
||||
"巡回检查",
|
||||
"例行检查",
|
||||
"专业检查",
|
||||
"综合检查",
|
||||
"综合检查",
|
||||
],
|
||||
},
|
||||
{
|
||||
@ -154,17 +150,16 @@ class BI054HomeDetail extends React.Component {
|
||||
Parent: {
|
||||
DepartmentName: "试验化验室",
|
||||
RowCount: 2,
|
||||
listCount: [0, 0, 0, 0, 0],
|
||||
listCount: [0, 0, 0, 0],
|
||||
},
|
||||
Percent: 0,
|
||||
RowCount: 1,
|
||||
listCount: [0, 0, 0, 0, 0],
|
||||
listCount: [0, 0, 0, 0],
|
||||
listName: [
|
||||
"巡回检查",
|
||||
"例行检查",
|
||||
"专业检查",
|
||||
"综合检查",
|
||||
"综合检查",
|
||||
],
|
||||
},
|
||||
{
|
||||
@ -176,17 +171,16 @@ class BI054HomeDetail extends React.Component {
|
||||
Parent: {
|
||||
DepartmentName: "试验化验室",
|
||||
RowCount: 2,
|
||||
listCount: [0, 0, 0, 0, 0],
|
||||
listCount: [0, 0, 0, 0],
|
||||
},
|
||||
Percent: 0,
|
||||
RowCount: 1,
|
||||
listCount:[0, 0, 0, 0, 0],
|
||||
listCount:[0, 0, 0, 0],
|
||||
listName: [
|
||||
"巡回检查",
|
||||
"例行检查",
|
||||
"专业检查",
|
||||
"综合检查",
|
||||
"综合检查",
|
||||
],
|
||||
},
|
||||
{
|
||||
@ -198,17 +192,16 @@ class BI054HomeDetail extends React.Component {
|
||||
Parent: {
|
||||
DepartmentName: "金宇宁化分公司",
|
||||
RowCount: 4,
|
||||
listCount: [51, 1452, 0, 0, 0],
|
||||
listCount: [51, 1452, 0, 0],
|
||||
},
|
||||
Percent: 0,
|
||||
RowCount: 1,
|
||||
listCount: [0, 351, 0, 0, 0],
|
||||
listCount: [0, 351, 0, 0],
|
||||
listName: [
|
||||
"巡回检查",
|
||||
"例行检查",
|
||||
"专业检查",
|
||||
"综合检查",
|
||||
"综合检查",
|
||||
],
|
||||
},
|
||||
{
|
||||
@ -220,17 +213,16 @@ class BI054HomeDetail extends React.Component {
|
||||
Parent: {
|
||||
DepartmentName: "金宇宁化分公司",
|
||||
RowCount: 4,
|
||||
listCount: [51, 1452, 0, 0, 0],
|
||||
listCount: [51, 1452, 0, 0],
|
||||
},
|
||||
Percent: 0,
|
||||
RowCount: 1,
|
||||
listCount: [0, 350, 0, 0, 0],
|
||||
listCount: [0, 350, 0, 0],
|
||||
listName: [
|
||||
"巡回检查",
|
||||
"例行检查",
|
||||
"专业检查",
|
||||
"综合检查",
|
||||
"综合检查",
|
||||
],
|
||||
},
|
||||
{
|
||||
@ -242,17 +234,16 @@ class BI054HomeDetail extends React.Component {
|
||||
Parent: {
|
||||
DepartmentName: "金宇宁化分公司",
|
||||
RowCount: 4,
|
||||
listCount: [51, 1452, 0, 0, 0],
|
||||
listCount: [51, 1452, 0, 0],
|
||||
},
|
||||
Percent: 0,
|
||||
RowCount: 1,
|
||||
listCount: [0, 350, 0, 0, 0],
|
||||
listCount: [0, 350, 0, 0],
|
||||
listName: [
|
||||
"巡回检查",
|
||||
"例行检查",
|
||||
"专业检查",
|
||||
"综合检查",
|
||||
"综合检查",
|
||||
],
|
||||
},
|
||||
{
|
||||
@ -264,17 +255,16 @@ class BI054HomeDetail extends React.Component {
|
||||
Parent: {
|
||||
DepartmentName: "金宇宁化分公司",
|
||||
RowCount: 4,
|
||||
listCount: [51, 1452, 0, 0, 0],
|
||||
listCount: [51, 1452, 0, 0],
|
||||
},
|
||||
Percent: 0,
|
||||
RowCount: 1,
|
||||
listCount: [0, 350, 0, 0, 0],
|
||||
listCount: [0, 350, 0, 0],
|
||||
listName: [
|
||||
"巡回检查",
|
||||
"例行检查",
|
||||
"专业检查",
|
||||
"综合检查",
|
||||
"综合检查",
|
||||
],
|
||||
},
|
||||
{
|
||||
@ -286,17 +276,16 @@ class BI054HomeDetail extends React.Component {
|
||||
Parent: {
|
||||
DepartmentName: "安环科",
|
||||
RowCount: 1,
|
||||
listCount: [52, 400, 2, 1, 1],
|
||||
listCount: [52, 400, 2, 1],
|
||||
},
|
||||
Percent: 0,
|
||||
RowCount: 1,
|
||||
listCount: [0, 349, 0, 0, 0],
|
||||
listCount: [0, 349, 0, 0],
|
||||
listName: [
|
||||
"巡回检查",
|
||||
"例行检查",
|
||||
"专业检查",
|
||||
"综合检查",
|
||||
"综合检查",
|
||||
],
|
||||
},
|
||||
|
||||
@ -585,7 +574,6 @@ class BI054HomeDetail extends React.Component {
|
||||
[317, 330, 316, 330, 292, 286, 299, 286, 295, 299, 223, 201],
|
||||
[0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0],
|
||||
[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0],
|
||||
[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0],
|
||||
];
|
||||
for (let i = 0; i < 12; i++) {
|
||||
xData.unshift(getSixMonth(-i, "-", ""));
|
||||
@ -595,7 +583,6 @@ class BI054HomeDetail extends React.Component {
|
||||
"例行检查",
|
||||
"专业检查",
|
||||
"综合检查",
|
||||
"综合检查",
|
||||
];
|
||||
// data.map((item) => {
|
||||
// if (item.MONTH>9){
|
||||
|
||||
@ -621,9 +621,9 @@ class BI055HomeDetail extends React.Component {
|
||||
"100.00",
|
||||
],
|
||||
];
|
||||
let sourceName = [
|
||||
["按时整改隐患", "超期整改隐患", "未整改隐患", "隐患整改率"],
|
||||
];
|
||||
let sourceName =
|
||||
["按时整改隐患", "超期整改隐患", "未整改隐患", "隐患整改率"];
|
||||
|
||||
// if (this.state.ListC) {
|
||||
// this.state.ListC.map((item) => {
|
||||
// let name = item.NAME.split(",");
|
||||
@ -673,8 +673,8 @@ class BI055HomeDetail extends React.Component {
|
||||
},
|
||||
},
|
||||
grid: {
|
||||
left: "10%",
|
||||
// right: "10%",
|
||||
left: "5%",
|
||||
right: "5%",
|
||||
bottom: "15%",
|
||||
top: "5%",
|
||||
containLabel: true,
|
||||
|
||||
@ -390,9 +390,10 @@ function Header(props) {
|
||||
: "header__left-slogan"
|
||||
}`}
|
||||
>
|
||||
矿山安全生产标准化系统
|
||||
安全管理系统
|
||||
<span style={{ color: "#c99d03" }}>(SMS)</span>
|
||||
{baseConfig.SYS_NAME}{" "}
|
||||
{/* {baseConfig.SYS_NAME}{" "} */}
|
||||
-宁化行洛坑
|
||||
</span>
|
||||
)}
|
||||
</div>
|
||||
|
||||
@ -232,7 +232,9 @@ const Sider = (props) => {
|
||||
: "sider__shortMenuShowoverca-overc"
|
||||
}
|
||||
></Icon>
|
||||
<div className="sider__shortMenuShowoverca-title">{menu.Node.NAME}</div>
|
||||
<div className="sider__shortMenuShowoverca-title">
|
||||
{menu.Node.NAME}
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
})}
|
||||
@ -242,7 +244,8 @@ const Sider = (props) => {
|
||||
className="sider__shortMenuShowovercae"
|
||||
onClick={() => {
|
||||
setMenuShow(!MenuShow);
|
||||
if(mainSilder == 1){ //禁止mainsilder为1--首页状态
|
||||
if (mainSilder == 1) {
|
||||
//禁止mainsilder为1--首页状态
|
||||
setMainSilder(2);
|
||||
}
|
||||
// if (MenuShow) {
|
||||
@ -252,10 +255,18 @@ const Sider = (props) => {
|
||||
// }
|
||||
}}
|
||||
>
|
||||
<Icon
|
||||
type="import"
|
||||
className="sider__shortMenuShowoverca-overcd"
|
||||
></Icon>
|
||||
{MenuShow == true ? (
|
||||
<Icon
|
||||
type="import"
|
||||
className="sider__shortMenuShowoverca-overcd"
|
||||
></Icon>
|
||||
) : (
|
||||
<Icon
|
||||
type="import"
|
||||
className="sider__shortMenuShowoverca-overcd"
|
||||
style={{transform:'scaleX(-1)'}}
|
||||
></Icon>
|
||||
)}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -298,32 +309,32 @@ const Sider = (props) => {
|
||||
})}
|
||||
</div>
|
||||
) : ( */}
|
||||
<div className={`sider ${"shortMenuShow_ChildPadding"}`}>
|
||||
{menuCUR &&
|
||||
menuCUR.Children.map((menu2, index2) => {
|
||||
return (
|
||||
<div
|
||||
// key={`${menu2.ID}_${index2}`}
|
||||
className="sider__shortMenuShowFlex"
|
||||
>
|
||||
<div className="sider__shortMenuShowChildTwo">
|
||||
<Icon
|
||||
type={"caret-right"}
|
||||
className="sider__shortMenuShowChildTwo-iconri"
|
||||
/>
|
||||
<Icon
|
||||
type={
|
||||
menu2.Node.ICON ? menu2.Node.ICON : "file-text"
|
||||
}
|
||||
className="sider__shortMenuShowChildTwo-icon"
|
||||
/>
|
||||
<div className={`sider ${"shortMenuShow_ChildPadding"}`}>
|
||||
{menuCUR &&
|
||||
menuCUR.Children.map((menu2, index2) => {
|
||||
return (
|
||||
<div
|
||||
// key={`${menu2.ID}_${index2}`}
|
||||
className="sider__shortMenuShowFlex"
|
||||
>
|
||||
<div className="sider__shortMenuShowChildTwo">
|
||||
<Icon
|
||||
type={"caret-right"}
|
||||
className="sider__shortMenuShowChildTwo-iconri"
|
||||
/>
|
||||
<Icon
|
||||
type={
|
||||
menu2.Node.ICON ? menu2.Node.ICON : "file-text"
|
||||
}
|
||||
className="sider__shortMenuShowChildTwo-icon"
|
||||
/>
|
||||
|
||||
<span className="sider__shortMenuShowChildTwo-name">
|
||||
{menu2.Node.NAME}
|
||||
</span>
|
||||
</div>
|
||||
<div className="sider__shortMenuShowGrid">
|
||||
{menu2.Children.map((menu3, index3) => {
|
||||
<span className="sider__shortMenuShowChildTwo-name">
|
||||
{menu2.Node.NAME}
|
||||
</span>
|
||||
</div>
|
||||
<div className="sider__shortMenuShowGrid">
|
||||
{menu2.Children.map((menu3, index3) => {
|
||||
return (
|
||||
<div
|
||||
key={`${menu3.Node.ID}_${index3}`}
|
||||
@ -353,13 +364,11 @@ const Sider = (props) => {
|
||||
</div>
|
||||
);
|
||||
})}
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
);
|
||||
})}
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
})}
|
||||
</div>
|
||||
{/* // )} */}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@ -10,7 +10,7 @@ import {
|
||||
extendRule,
|
||||
extend,
|
||||
extendOrder,
|
||||
getSixMonth
|
||||
getSixMonth,
|
||||
} from "../utils/common";
|
||||
import "./home.less";
|
||||
// 组件库
|
||||
@ -197,35 +197,35 @@ class Home extends React.Component {
|
||||
},
|
||||
completeName: [
|
||||
{
|
||||
name: "张森友",
|
||||
name: "运输二班",
|
||||
value: 100,
|
||||
},
|
||||
{
|
||||
name: "李友军",
|
||||
name: "综合班组",
|
||||
value: 99,
|
||||
},
|
||||
{
|
||||
name: "洪虎林",
|
||||
name: "生产班",
|
||||
value: 97,
|
||||
},
|
||||
{
|
||||
name: "李彦斌",
|
||||
name: "维修班组",
|
||||
value: 95,
|
||||
},
|
||||
{
|
||||
name: "王志文",
|
||||
name: "民爆储存库班组",
|
||||
value: 93,
|
||||
},
|
||||
{
|
||||
name: "黄海林",
|
||||
name: "爆破班组",
|
||||
value: 90,
|
||||
},
|
||||
{
|
||||
name: "赵无极",
|
||||
name: "运输一班",
|
||||
value: 67,
|
||||
},
|
||||
{
|
||||
name: "林佑君",
|
||||
name: "金宇现场",
|
||||
value: 43,
|
||||
},
|
||||
],
|
||||
@ -1214,8 +1214,8 @@ class Home extends React.Component {
|
||||
};
|
||||
ExpandCancel = () => {};
|
||||
showDetailModal = (formCode) => {
|
||||
var titleTemp =''
|
||||
|
||||
var titleTemp = "";
|
||||
|
||||
if (formCode == "BI054_HOMEDETAIL") {
|
||||
titleTemp += "安全检查次数统计(近12月)";
|
||||
} else if (formCode == "BI055_HOMEDETAIL") {
|
||||
@ -2114,39 +2114,42 @@ class Home extends React.Component {
|
||||
style={{
|
||||
flex: 1,
|
||||
height: "100%",
|
||||
padding: "15px 20px 15px 50px",
|
||||
padding: "15px 40px 15px 40px",
|
||||
}}
|
||||
>
|
||||
{this.state.completeName.map((item, index) => {
|
||||
return (
|
||||
<div className="home-rank">
|
||||
{index == 0 ? (
|
||||
<img
|
||||
src={require("./../assets/home/4-1.png")}
|
||||
className="home-img"
|
||||
alt="4-1"
|
||||
/>
|
||||
) : index == 1 ? (
|
||||
<img
|
||||
src={require("./../assets/home/4-2.png")}
|
||||
className="home-img"
|
||||
alt="4-2"
|
||||
/>
|
||||
) : index == 2 ? (
|
||||
<img
|
||||
src={require("./../assets/home/4-3.png")}
|
||||
className="home-img"
|
||||
alt="4-3"
|
||||
/>
|
||||
) : (
|
||||
<div className="home-rank-index">{index + 1}</div>
|
||||
)}
|
||||
<div className="home-ranks">
|
||||
{index == 0 ? (
|
||||
<img
|
||||
src={require("./../assets/home/4-1.png")}
|
||||
className="home-img"
|
||||
alt="4-1"
|
||||
/>
|
||||
) : index == 1 ? (
|
||||
<img
|
||||
src={require("./../assets/home/4-2.png")}
|
||||
className="home-img"
|
||||
alt="4-2"
|
||||
/>
|
||||
) : index == 2 ? (
|
||||
<img
|
||||
src={require("./../assets/home/4-3.png")}
|
||||
className="home-img"
|
||||
alt="4-3"
|
||||
/>
|
||||
) : (
|
||||
<div className="home-rank-index">{index + 1}</div>
|
||||
)}
|
||||
|
||||
<div className="home-rank-name">{item.name}</div>
|
||||
</div>
|
||||
|
||||
<div className="home-rank-name">{item.name}</div>
|
||||
<Progress
|
||||
percent={item.value}
|
||||
status="active"
|
||||
style={{ width: "50%" }}
|
||||
style={{ width: "48%" }}
|
||||
></Progress>
|
||||
</div>
|
||||
);
|
||||
|
||||
@ -1,10 +1,32 @@
|
||||
/* 工作台调整样式 */
|
||||
:global(.redTableCell) {
|
||||
background: #e6f7ff;
|
||||
}
|
||||
:global(.redTableCell):hover {
|
||||
background: #e6f7ff !important;
|
||||
}
|
||||
:global(.bi001-table) {
|
||||
:global(
|
||||
.ant-table-tbody
|
||||
> tr:hover:not(.ant-table-expanded-row):not(.ant-table-row-selected)
|
||||
> td
|
||||
) {
|
||||
background: #fff;
|
||||
}
|
||||
}
|
||||
:global(.bi001-table) {
|
||||
:global(.ant-table-row:hover) {
|
||||
:global(.redTableCell) {
|
||||
background: #e6f7ff !important;
|
||||
}
|
||||
}
|
||||
}
|
||||
:global(.home-rate) {
|
||||
width: calc(50% - 10px);
|
||||
height: 100%;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
min-Width: "220px",
|
||||
min-width: "220px";
|
||||
}
|
||||
:global(.home-userInfo-tabs) {
|
||||
background-color: #eefff8;
|
||||
@ -54,7 +76,7 @@
|
||||
white-space: nowrap;
|
||||
/* margin-right: 20px; */
|
||||
}
|
||||
:global(.home-rate-divider){
|
||||
:global(.home-rate-divider) {
|
||||
height: 80%;
|
||||
}
|
||||
:global(.home-always-title) {
|
||||
@ -104,7 +126,7 @@
|
||||
background-color: #fafafa;
|
||||
padding: 8px;
|
||||
border-radius: 10px;
|
||||
box-shadow: 0px 0px 3px 0px rgba(0, 0, 0, 0.12) ;
|
||||
box-shadow: 0px 0px 3px 0px rgba(0, 0, 0, 0.12);
|
||||
}
|
||||
:global(.home-tech-icon) {
|
||||
font-size: 30px;
|
||||
@ -130,11 +152,18 @@
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
margin-bottom: 10px;
|
||||
justify-content: space-between;
|
||||
}
|
||||
:global(.home-ranks) {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
|
||||
}
|
||||
:global(.home-rank-index) {
|
||||
width: 30px;
|
||||
height: 30px;
|
||||
margin-right: 40px;
|
||||
margin-right: 30px;
|
||||
color: #eac088;
|
||||
font-size: 12px;
|
||||
display: flex;
|
||||
@ -151,7 +180,7 @@
|
||||
object-fit: contain;
|
||||
width: 30px;
|
||||
height: 30px;
|
||||
margin-right: 40px;
|
||||
margin-right: 30px;
|
||||
}
|
||||
:global(.home-rank > .ant-progress .ant-progress-text) {
|
||||
margin-left: 30px;
|
||||
@ -183,7 +212,7 @@
|
||||
background: url("./../assets/home/prepare2.png");
|
||||
background-size: cover;
|
||||
background-repeat: no-repeat;
|
||||
box-shadow: 0px 0px 3px 0px rgba(0, 0, 0, 0.12);
|
||||
box-shadow: 0px 0px 3px 0px rgba(0, 0, 0, 0.12);
|
||||
/* align-items: center; */
|
||||
}
|
||||
:global(.home-work-wrap-overtime) {
|
||||
@ -196,7 +225,7 @@
|
||||
background: url("./../assets/home/overtime.png");
|
||||
background-size: cover;
|
||||
background-repeat: no-repeat;
|
||||
box-shadow: 0px 0px 3px 0px rgba(0, 0, 0, 0.12);
|
||||
box-shadow: 0px 0px 3px 0px rgba(0, 0, 0, 0.12);
|
||||
/* align-items: center; */
|
||||
}
|
||||
:global(.home-work-wrap-over) {
|
||||
@ -209,7 +238,7 @@
|
||||
background: url("./../assets/home/over.png");
|
||||
background-size: cover;
|
||||
background-repeat: no-repeat;
|
||||
box-shadow: 0px 0px 3px 0px rgba(0, 0, 0, 0.12);
|
||||
box-shadow: 0px 0px 3px 0px rgba(0, 0, 0, 0.12);
|
||||
/* align-items: center; */
|
||||
}
|
||||
:global(.home-work-wrap-warn) {
|
||||
@ -222,7 +251,7 @@
|
||||
background: url("./../assets/home/warn.png");
|
||||
background-size: cover;
|
||||
background-repeat: no-repeat;
|
||||
box-shadow: 0px 0px 3px 0px rgba(0, 0, 0, 0.12);
|
||||
box-shadow: 0px 0px 3px 0px rgba(0, 0, 0, 0.12);
|
||||
/* align-items: center; */
|
||||
}
|
||||
:global(.home-work-more) {
|
||||
@ -230,7 +259,7 @@
|
||||
flex-direction: row;
|
||||
padding: 10px 25px;
|
||||
/* background-color: #fafafa; */
|
||||
box-shadow: 0px 0px 3px 0px rgba(0, 0, 0, 0.12);
|
||||
box-shadow: 0px 0px 3px 0px rgba(0, 0, 0, 0.12);
|
||||
margin-bottom: 20px;
|
||||
align-items: center;
|
||||
color: #2177d5;
|
||||
@ -245,8 +274,8 @@
|
||||
margin-left: 5px;
|
||||
}
|
||||
:global(.home-work-back):hover {
|
||||
background-color: #eef5ff;
|
||||
cursor: pointer;
|
||||
background-color: #eef5ff;
|
||||
cursor: pointer;
|
||||
}
|
||||
:global(.home-work-icon) {
|
||||
padding: 3px 5px;
|
||||
@ -345,8 +374,8 @@ cursor: pointer;
|
||||
border-radius: 5px;
|
||||
}
|
||||
:global(.risk-chart) {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
:global(.risk-model-tab) {
|
||||
display: flex;
|
||||
@ -371,9 +400,8 @@ flex-direction: column;
|
||||
font-size: 12px;
|
||||
margin: 0px 5px;
|
||||
cursor: pointer;
|
||||
background-color:#3c9cff ;
|
||||
background-color: #3c9cff;
|
||||
color: #fff;
|
||||
}
|
||||
:global() {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user