Browse Source

更改事件控制分析bug

wangqin
zhangzhang 2 years ago
parent
commit
e3d9fce678
  1. 106
      ruoyi-ui/src/views/JiHeExpressway/pages/control/event/dispatch/data.js
  2. 83
      ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/auditAnalytics/StatsDialogVisible/index.vue
  3. 339
      ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/channelAnalytics/assets/charts copy.js
  4. 176
      ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/channelAnalytics/assets/charts.js
  5. 7
      ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/channelAnalytics/index.vue
  6. 227
      ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/eventTypeAnalysis/assets/charts.js
  7. 6
      ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/eventTypeAnalysis/index.vue
  8. 40
      ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/postTrendsDay/assets/charts.js
  9. 33
      ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/postTrendsMonth/assets/charts.js
  10. 76
      ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/postTrendsMonth/assets/charts2.js
  11. 35
      ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/postTrendsMonth/assets/charts3.js
  12. 608
      ruoyi-ui/src/views/JiHeExpressway/pages/perception/trafficSituation/components/IndicatorAnalysis/components/trafficIndicators/index.vue
  13. 8
      ruoyi-ui/src/views/JiHeExpressway/scss/el-reset.scss

106
ruoyi-ui/src/views/JiHeExpressway/pages/control/event/dispatch/data.js

@ -1,7 +1,8 @@
import * as PresetFormItems from "@screen/pages/control/event/event/FormEvent/PresetFormItems.js"; import * as PresetFormItems from "@screen/pages/control/event/event/FormEvent/PresetFormItems.js";
import { merge, cloneDeep } from "lodash"; import { merge, cloneDeep } from "lodash";
export const searchFormList = [{ export const searchFormList = [
{
label: "事件状态:", label: "事件状态:",
key: "eventState", key: "eventState",
type: "RadioGroup", type: "RadioGroup",
@ -22,58 +23,57 @@ export const searchFormList = [{
], ],
}, },
}, },
PresetFormItems.eventSources, PresetFormItems.eventSources,
PresetFormItems.eventType, PresetFormItems.eventType,
{ {
label: "方向:", label: "方向:",
key: "direction", key: "direction",
type: "RadioGroup", type: "RadioGroup",
options: { options: {
options: [ options: [
{ {
key: "济南方向", key: "济南方向",
label: "济南方向", label: "济南方向",
}, },
{ {
key: "菏泽方向", key: "菏泽方向",
label: "菏泽方向", label: "菏泽方向",
}, },
{ {
key: "双向", key: "双向",
label: "双向", label: "双向",
}, },
], ],
},
}, },
{ },
label: "时间范围:", {
key: "daterange", label: "时间范围:",
required: false, key: "daterange",
type: "datePicker", required: false,
options: { type: "datePicker",
type: "daterange", options: {
format: 'yyyy-MM-dd HH:mm:ss', type: "daterange",
valueFormat: 'yyyy-MM-dd HH:mm:ss' format: "yyyy-MM-dd HH:mm:ss",
}, valueFormat: "yyyy-MM-dd HH:mm:ss",
}, },
{ },
...PresetFormItems.station, {
label: "开始桩号:", ...PresetFormItems.station,
required: false, label: "开始桩号:",
required: false,
},
merge(cloneDeep(PresetFormItems.station), {
options: {
options: [
{
key: "endStakeMark[0]",
},
{
key: "endStakeMark[1]",
},
],
}, },
merge(cloneDeep(PresetFormItems.station), { label: "结束桩号:",
options: { required: false,
options: [ }),
{ ];
key: "endStakeMark[0]",
},
{
key: "endStakeMark[1]",
},
],
},
label: "结束桩号:",
required: false,
}
)
];

83
ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/auditAnalytics/StatsDialogVisible/index.vue

@ -51,6 +51,7 @@ import Dialog from "@screen/components/Dialog/index";
import InputSearch from '@screen/components/InputSearch/index.vue'; import InputSearch from '@screen/components/InputSearch/index.vue';
import Table from "@screen/components/Table.vue"; import Table from "@screen/components/Table.vue";
import { selectTollStation } from "@/api/event/governanceAnalysis" import { selectTollStation } from "@/api/event/governanceAnalysis"
import options from "../assets/charts";
export default { export default {
name: 'StatsDetail', name: 'StatsDetail',
components: { components: {
@ -67,17 +68,82 @@ export default {
}, },
data() { data() {
return { return {
num: 0,
tableData: [], tableData: [],
weatherNum: [], weatherNum: [],
startTime: "", startTime: "",
endTime: "", endTime: "",
pickerOptions: {
disabledDate(time) {
return time.getTime() > Date.now();
},
},
searchFormList: [ searchFormList: [
{
label: "查询条件:",
key: "a",
required: true,
isAlone: true,
type: "RadioGroup",
options: {
type: 'circle',
options: [
{
key: "0",
label: "站点",
},
{
key: "1",
label: "原因",
}
],
}
},
{
label: "事件类型:",
key: "b",
required: true,
type: "RadioGroup",
options: {
type: 'circle',
options: [{
key: 1,
label: "收费站封闭",
},
{
key: 2,
label: "收费站限行",
}]
}
},
{
label: "选择站点:",
key: "c",
required: true,
type: "RadioGroup",
options: {
type: 'circle',
options: [{
key: 1,
label: "收费站封闭",
},
{
key: 2,
label: "收费站限行",
}]
}
},
{ {
label: "日期:", label: "日期:",
key: "date", key: "date",
required: true, required: true,
type: "datePicker", type: "datePicker",
options: { options: {
pickerOptions: {
disabledDate(time) {
return time.getTime() > Date.now();
},
},
valueFormat: "yyyy-MM-dd", valueFormat: "yyyy-MM-dd",
type: "daterange" type: "daterange"
} }
@ -99,11 +165,15 @@ export default {
methods: { methods: {
handleSearch(data) { handleSearch(data) {
console.log("data", data)
this.getSelectTollStation(data) this.getSelectTollStation(data)
}, },
arraySpanMethod({ row, column, rowIndex, columnIndex }) { arraySpanMethod({ row, column, rowIndex, columnIndex }) {
// console.log("+++++++", row, column, rowIndex, columnIndex) console.log("+++++++", row, column, rowIndex, columnIndex)
if (!row.causeTypeName) { if (!row.causeTypeName) {
console.log("11111111111")
if (columnIndex === 0) { if (columnIndex === 0) {
return [1, 2]; return [1, 2];
} }
@ -112,6 +182,7 @@ export default {
} }
}; };
if (row.controlCauseName === '恶劣天气') { if (row.controlCauseName === '恶劣天气') {
console.log("222222222222")
if (columnIndex === 0) { if (columnIndex === 0) {
console.log(this.weatherNum.length) console.log(this.weatherNum.length)
if (rowIndex === 0) { if (rowIndex === 0) {
@ -141,9 +212,10 @@ export default {
// } // }
} }
// this.weatherNum = 0
} }
}, },
getSelectTollStation(data) { getSelectTollStation(data) {
console.log(45, data) console.log(45, data)
@ -164,6 +236,7 @@ export default {
let weatherData = [] let weatherData = []
let otherData = [] let otherData = []
selectTollStation(formData).then((res) => { selectTollStation(formData).then((res) => {
this.weatherNum = []
res.data.forEach(item => { res.data.forEach(item => {
if (item.causeTypeName) { if (item.causeTypeName) {
this.weatherNum.push(item.causeTypeName) this.weatherNum.push(item.causeTypeName)
@ -178,7 +251,11 @@ export default {
} }
}, },
mounted() { mounted() {
this.getSelectTollStation() let date = moment().format('YYYY-MM-DD')
let data = {
date: [date + " 00:00:00", date + " 23:59:59"]
}
this.getSelectTollStation(data)
} }
} }
</script> </script>

339
ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/channelAnalytics/assets/charts copy.js

@ -0,0 +1,339 @@
var res = [
{ value: 20, name: "交通事故" },
{ value: 1, name: "" },
{ value: 20, name: "车辆故障" },
{ value: 1, name: "" },
{ value: 15, name: "路障清除" },
{ value: 1, name: "" },
{ value: 10, name: "交通管制" },
{ value: 1, name: "" },
{ value: 5, name: "道路拥堵" },
{ value: 1, name: "" },
{ value: 5, name: "异常天气" },
];
let angle = 0; //角度,用来做简单的动画效果的
//获取圆上面某点的坐标(x0,y0表示坐标,r半径,angle角度)
function getCirlPoint(x0, y0, r, angle) {
let x1 = x0 + r * Math.cos((angle * Math.PI) / 180);
let y1 = y0 + r * Math.sin((angle * Math.PI) / 180);
return {
x: x1,
y: y1,
};
}
let color = [
"#4278F8F9",
"transparent",
"#5372C4",
"transparent",
"#0046FFF9",
"transparent",
"#FB9434F9",
"transparent",
"#854101F9",
"transparent",
"#05E599F9",
"transparent",
"#219F73F9",
"transparent",
"#7CEDD5F9",
"transparent",
];
let colorend = [
"#4278F800",
"transparent",
"#5372C400",
"transparent",
"#0046FF00",
"transparent",
"#FB943400",
"transparent",
"#85410100",
"transparent",
"#05E59900",
"transparent",
"#219F7300",
"transparent",
"#7CEDD500",
"transparent",
];
// var res = this.evaluatedCountList;
var data1 = [],
data2 = [],
data3 = [],
legendData = [];
var curIndex = 0;
var index = 0;
for (var i = 0; i < res.length; i++) {
// data1.push({
// value: res[i].value,
// name: res[i].name,
// });
// data2.push({
// value: res[i].value,
// name: res[i].name,
// itemStyle: {
// opacity: 0.4,
// },
// });
// data3.push({
// value: res[i].value,
// name: res[i].name,
// itemStyle: {
// opacity: 0.1,
// },
// });
if (res[i].name != "") legendData.push(res[i].name);
}
var options = {
color: [
"#2867FF",
"transparent",
"#58C3FF",
"transparent",
"#FF6A3B",
"transparent",
"#FDA474",
"transparent",
"#FEE58F",
"transparent",
"#8DFEBF",
"transparent",
"#66F4DC",
"transparent",
"#33E27D",
"transparent",
"#5D8CFE",
"transparent",
],
title: [
{
text: "999",
top: "25%",
textAlign: "center",
left: "48%",
textStyle: {
color: "#ffffff",
fontSize: 30,
fontFamily: "SourceHanSansCN",
},
},
{
text: "总数",
top: "38%",
textAlign: "center",
left: "48%",
textStyle: {
color: "rgba(242, 252, 253, 0.84)",
fontSize: 16,
fontFamily: "SourceHanSansCN",
},
},
],
grid: {
top: "38%",
left: "6%",
right: "6%",
bottom: "3%",
containLabel: true,
},
tooltip: {
show: false,
trigger: "item",
formatter: "{b} : {c}:{d}",
},
legend: {
orient: "",
left: "10%",
top: "68%",
itemWidth: 10,
itemHeight: 10,
icon: "circle",
textStyle: {
color: "#ffffff",
fontSize: 14,
lineHeight: 22,
rich: {
text: {
marginLeft: 32,
fontSize: 14,
},
number: {
fontSize: 14,
color: "#37E7FF",
marginLeft: 32,
fontWeight: "bold",
},
unit: {
fontSize: 14,
},
},
},
data: legendData,
// formatter(name) {
// const newData = res;
// let tarValue = 0;
// let total = 0;
// for (let i = 0; i < newData.length; i++) {
// total += newData[i].value;
// if (newData[i].name === name) {
// tarValue = newData[i].value;
// }
// }
// var percert = total == 0 ? 0 : ((tarValue / total) * 100).toFixed(2);
// const arr = name + " " + tarValue;
// return `{text|${name}} {number|${percert}%}`;
// },
},
series: [
/** 饼图上刻度 */
{
type: "gauge",
center: ["50%", "35%"],
radius: "46%", // 错位调整此处
startAngle: 0,
endAngle: 360,
splitNumber: 52,
axisLine: { show: false },
splitLine: {
// length: 39,
length: "2",
lineStyle: {
width: 5,
color: "#5CC5FF",
},
},
axisTick: { show: false },
axisLabel: { show: false },
},
{
name: "中心效果圆",
type: "gauge",
radius: "30%",
center: ["50%", "35%"],
startAngle: 0,
endAngle: 360,
axisLine: {
lineStyle: {
color: [[1, "#0AFFE950"]],
width: 1,
},
},
axisTick: {
show: false,
},
splitLine: {
show: false,
},
axisLabel: {
show: false,
},
detail: {
show: false,
},
pointer: {
show: false,
},
progress: {
show: true,
width: 80,
itemStyle: {
color: {
type: "radial",
x: 0.5,
y: 0.5,
r: 0.5,
colorStops: [
{
offset: 0,
color: "rgb(0, 224, 205, 0)",
},
{
offset: 0.7,
color: "rgba(0, 224, 205, 0)",
},
{
offset: 1,
color: "rgba(10, 255, 233, 0.5)",
},
],
},
},
},
data: [
{
value: 100,
},
],
},
{
type: "pie",
radius: ["50%", "40%"],
center: ["50%", "35%"],
z: 10,
label: {
show: false,
position: "center",
formatter: (params) => {
return params.name + "\r\n" + params.value;
},
rich: {
total: {
fontSize: 16,
color: "#04F5FE",
},
efficiency: {
fontSize: 12,
color: "#00FD6D",
},
},
color: "#FFFFFF",
fontSize: 12,
lineHeight: 16,
},
data: res,
labelLine: {
show: false,
},
itemStyle: {
normal: {
borderRadius: "5",
borderWidth: 0,
borderType: "solid",
borderCap: "round",
borderJoin: "round",
borderColor: "#064258",
borderMiterLimit: "20",
color: function (params) {
return {
type: "linear",
x: 0,
y: 0,
x2: 1,
y2: 1,
colorStops: [
{
offset: 0,
color: color[params.dataIndex], // 0% 处的颜色
},
{
offset: 1,
color: colorend[params.dataIndex], // 100% 处的颜色
},
],
globalCoord: false, // 缺省为 false
};
},
},
},
},
],
};
export default options;

176
ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/channelAnalytics/assets/charts.js

@ -1,116 +1,36 @@
var res = [ let colors = [
{ value: 20, name: "交通事故" }, "#68F4DD",
{ value: 1, name: "" }, "#1785C0",
{ value: 20, name: "车辆故障" }, "#476DBC",
{ value: 1, name: "" }, "#B55233",
{ value: 15, name: "路障清除" }, "#B0862C",
{ value: 1, name: "" }, "#35AD6B",
{ value: 10, name: "交通管制" }, "#219F73",
{ value: 1, name: "" }, "#7CEDD5",
{ value: 5, name: "道路拥堵" },
{ value: 1, name: "" },
{ value: 5, name: "异常天气" },
];
let angle = 0; //角度,用来做简单的动画效果的
//获取圆上面某点的坐标(x0,y0表示坐标,r半径,angle角度)
function getCirlPoint(x0, y0, r, angle) {
let x1 = x0 + r * Math.cos((angle * Math.PI) / 180);
let y1 = y0 + r * Math.sin((angle * Math.PI) / 180);
return {
x: x1,
y: y1,
};
}
let color = [
"#4278F8F9",
"transparent",
"#5372C4",
"transparent",
"#0046FFF9",
"transparent",
"#FB9434F9",
"transparent",
"#854101F9",
"transparent",
"#05E599F9",
"transparent",
"#219F73F9",
"transparent",
"#7CEDD5F9",
"transparent",
]; ];
let colorend = [ let colorend = [
"#4278F800", "#4278F8",
"transparent", "#5372C4",
"#5372C400", "#0046FF",
"transparent", "#FB9434",
"#0046FF00", "#854101",
"transparent", "#05E599",
"#FB943400", "#219F73",
"transparent", "#7CEDD5",
"#85410100",
"transparent",
"#05E59900",
"transparent",
"#219F7300",
"transparent",
"#7CEDD500",
"transparent",
]; ];
var legendData = [];
// var res = this.evaluatedCountList;
var data1 = [],
data2 = [],
data3 = [],
legendData = [];
var curIndex = 0;
var index = 0;
for (var i = 0; i < res.length; i++) {
// data1.push({
// value: res[i].value,
// name: res[i].name,
// });
// data2.push({
// value: res[i].value,
// name: res[i].name,
// itemStyle: {
// opacity: 0.4,
// },
// });
// data3.push({
// value: res[i].value,
// name: res[i].name,
// itemStyle: {
// opacity: 0.1,
// },
// });
if (res[i].name != "") legendData.push(res[i].name);
}
var options = { var options = {
color: [ color: [
"#2867FF", "#2867FF",
"transparent",
"#58C3FF", "#58C3FF",
"transparent",
"#FF6A3B", "#FF6A3B",
"transparent",
"#FDA474", "#FDA474",
"transparent",
"#FEE58F", "#FEE58F",
"transparent",
"#8DFEBF", "#8DFEBF",
"transparent",
"#66F4DC", "#66F4DC",
"transparent",
"#33E27D", "#33E27D",
"transparent",
"#5D8CFE", "#5D8CFE",
"transparent",
], ],
title: [ title: [
{ {
@ -144,23 +64,24 @@ var options = {
containLabel: true, containLabel: true,
}, },
tooltip: { tooltip: {
show: false, show: true,
trigger: "item", trigger: "item",
formatter: "{b} : {c}:{d}", // formatter: "{b} : {c}",
}, },
legend: { legend: {
orient: "", width: "300px",
left: "10%", height: "120px",
top: "68%", orient: "vertical",
top: "60%",
itemWidth: 10, itemWidth: 10,
itemHeight: 10, itemHeight: 10,
icon: "circle",
textStyle: { textStyle: {
color: "#ffffff", color: "#ffffff",
fontSize: 14, fontSize: 14,
lineHeight: 22, lineHeight: 22,
rich: { rich: {
text: { text: {
width: 100,
marginLeft: 32, marginLeft: 32,
fontSize: 14, fontSize: 14,
}, },
@ -176,20 +97,13 @@ var options = {
}, },
}, },
data: legendData, data: legendData,
// formatter(name) { pageIconColor: "#fff",
// const newData = res; pageIconSize: 10,
// let tarValue = 0; pageTextStyle: {
// let total = 0; color: "#fff",
// for (let i = 0; i < newData.length; i++) { },
// total += newData[i].value; type: "scroll",
// if (newData[i].name === name) { pageButtonPosition: "end",
// tarValue = newData[i].value;
// }
// }
// var percert = total == 0 ? 0 : ((tarValue / total) * 100).toFixed(2);
// const arr = name + " " + tarValue;
// return `{text|${name}} {number|${percert}%}`;
// },
}, },
series: [ series: [
/** 饼图上刻度 */ /** 饼图上刻度 */
@ -213,7 +127,7 @@ var options = {
axisLabel: { show: false }, axisLabel: { show: false },
}, },
{ {
name: "中心效果圆", name: "总数",
type: "gauge", type: "gauge",
radius: "30%", radius: "30%",
center: ["50%", "35%"], center: ["50%", "35%"],
@ -271,6 +185,7 @@ var options = {
value: 100, value: 100,
}, },
], ],
// tooltip: false,
}, },
{ {
type: "pie", type: "pie",
@ -279,25 +194,8 @@ var options = {
z: 10, z: 10,
label: { label: {
show: false, show: false,
position: "center",
formatter: (params) => {
return params.name + "\r\n" + params.value;
},
rich: {
total: {
fontSize: 16,
color: "#04F5FE",
},
efficiency: {
fontSize: 12,
color: "#00FD6D",
},
},
color: "#FFFFFF",
fontSize: 12,
lineHeight: 16,
}, },
data: res, data: [],
labelLine: { labelLine: {
show: false, show: false,
}, },
@ -320,11 +218,11 @@ var options = {
colorStops: [ colorStops: [
{ {
offset: 0, offset: 0,
color: color[params.dataIndex], // 0% 处的颜色 color: "transparent", // 0% 处的颜色
}, },
{ {
offset: 1, offset: 1,
color: colorend[params.dataIndex], // 100% 处的颜色 color: colors[params.dataIndex], // 100% 处的颜色
}, },
], ],
globalCoord: false, // 缺省为 false globalCoord: false, // 缺省为 false

7
ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/channelAnalytics/index.vue

@ -43,9 +43,9 @@ export default {
} }
console.log("total", total) console.log("total", total)
for (let i = 0; i < data.length; i++) { for (let i = 0; i < data.length; i++) {
if (i % 2 === 0) { // if (i % 2 === 0) {
data.splice(i + 1, 0, newObj) // data.splice(i + 1, 0, newObj)
} // }
if (data[i].name != "") { if (data[i].name != "") {
nameData.push(data[i].name) nameData.push(data[i].name)
} }
@ -63,6 +63,7 @@ export default {
}; };
chartsStatistics.legend.data = nameData; chartsStatistics.legend.data = nameData;
chartsStatistics.title[0].text = total; chartsStatistics.title[0].text = total;
// chartsStatistics.series[1].data[0].value = total;
chartsStatistics.series[2].data = data; chartsStatistics.series[2].data = data;
}) })
} }

227
ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/eventTypeAnalysis/assets/charts.js

@ -1,146 +1,52 @@
var res = [ let colors = [
{ value: 20, name: "交通事故" }, "#4278F8",
{ value: 1, name: "" },
{ value: 20, name: "车辆故障" },
{ value: 1, name: "" },
{ value: 15, name: "路障清除" },
{ value: 1, name: "" },
{ value: 10, name: "交通管制" },
{ value: 1, name: "" },
{ value: 5, name: "道路拥堵" },
{ value: 1, name: "" },
{ value: 5, name: "异常天气" },
{ value: 1, name: "" },
{ value: 20, name: "交通事故2" },
{ value: 1, name: "" },
{ value: 20, name: "车辆故障2" },
{ value: 1, name: "" },
{ value: 15, name: "路障清除2" },
{ value: 1, name: "" },
{ value: 10, name: "交通管制2" },
{ value: 1, name: "" },
{ value: 5, name: "道路拥堵2" },
{ value: 1, name: "" },
{ value: 5, name: "异常天气2" },
{ value: 1, name: "" },
];
let angle = 0; //角度,用来做简单的动画效果的
//获取圆上面某点的坐标(x0,y0表示坐标,r半径,angle角度)
function getCirlPoint(x0, y0, r, angle) {
let x1 = x0 + r * Math.cos((angle * Math.PI) / 180);
let y1 = y0 + r * Math.sin((angle * Math.PI) / 180);
return {
x: x1,
y: y1,
};
}
let color = [
"#4278F8F9",
"transparent",
"#5372C4", "#5372C4",
"transparent", "#0046FF",
"#0046FFF9", "#FB9434",
"transparent", "#854101",
"#FB9434F9", "#05E599",
"transparent", "#219F73",
"#854101F9", "#7CEDD5",
"transparent", "#854101",
"#05E599F9", "#05E599",
"transparent", "#219F73",
"#219F73F9", "#7CEDD5",
"transparent",
"#7CEDD5F9",
"transparent",
"#854101F9",
"transparent",
"#05E599F9",
"transparent",
"#219F73F9",
"transparent",
"#7CEDD5F9",
"transparent",
]; ];
let colorend = [ let colorend = [
"#4278F800", "#4278F8",
"transparent", "#5372C4",
"#5372C400", "#0046FF",
"transparent", "#FB9434",
"#0046FF00", "#854101",
"transparent", "#05E599",
"#FB943400", "#219F73",
"transparent", "#7CEDD5",
"#85410100", "#854101",
"transparent", "#05E599",
"#05E59900", "#219F73",
"transparent", "#7CEDD5",
"#219F7300",
"transparent",
"#7CEDD500",
"transparent",
"#854101F9",
"transparent",
"#05E599F9",
"transparent",
"#219F73F9",
"transparent",
"#7CEDD5F9",
"transparent",
]; ];
// var res = this.evaluatedCountList; let legendData = [];
var data1 = [],
data2 = [],
data3 = [],
legendData = [];
var curIndex = 0;
var index = 0;
for (var i = 0; i < res.length; i++) {
data1.push({
value: res[i].value,
name: res[i].name,
});
// data2.push({
// value: res[i].value,
// name: res[i].name,
// itemStyle: {
// opacity: 0.4,
// },
// })
// data3.push({
// value: res[i].value,
// name: res[i].name,
// itemStyle: {
// opacity: 0.1,
// },
// })
if (res[i].name != "") legendData.push(res[i].name);
}
var options = { var options = {
color: [ // color: [
"#2867FF", // "#2867FF",
"transparent", // "#58C3FF",
"#58C3FF", // "#FF6A3B",
"transparent", // "#FDA474",
"#FF6A3B", // "#FEE58F",
"transparent", // "#8DFEBF",
"#FDA474", // "#66F4DC",
"transparent", // "#33E27D",
"#FEE58F", // "#5D8CFE",
"transparent", // "#FDA474",
"#8DFEBF", // "#FEE58F",
"transparent", // "#8DFEBF",
"#66F4DC", // "#66F4DC",
"transparent", // "#33E27D",
"#33E27D", // "#5D8CFE",
"transparent", // ],
"#5D8CFE",
"transparent",
],
title: [ title: [
{ {
text: "999", text: "999",
@ -173,28 +79,24 @@ var options = {
containLabel: true, containLabel: true,
}, },
tooltip: { tooltip: {
show: false, show: true,
trigger: "item", trigger: "item",
formatter: "{b} : {c}:{d}", // formatter: "{b} : {c}:{d}",
}, },
legend: { legend: {
type: "scroll", width: "300px",
show: true, height: "120px",
// width: 200, orient: "vertical",
orient: "", top: "60%",
left: "10%",
top: "68%",
// right: "30%",
itemWidth: 10, itemWidth: 10,
itemHeight: 10, itemHeight: 10,
icon: "circle",
textStyle: { textStyle: {
color: "#ffffff", color: "#ffffff",
fontSize: 14, fontSize: 14,
lineHeight: 22, lineHeight: 22,
overflow: "auto",
rich: { rich: {
text: { text: {
width: 100,
marginLeft: 32, marginLeft: 32,
fontSize: 14, fontSize: 14,
}, },
@ -210,7 +112,13 @@ var options = {
}, },
}, },
data: legendData, data: legendData,
formatter(params) {}, pageIconColor: "#fff",
pageIconSize: 10,
pageTextStyle: {
color: "#fff",
},
type: "scroll",
pageButtonPosition: "end",
}, },
series: [ series: [
/** 饼图上刻度 */ /** 饼图上刻度 */
@ -300,25 +208,8 @@ var options = {
z: 10, z: 10,
label: { label: {
show: false, show: false,
position: "center",
formatter: (params) => {
return params.name + "\r\n" + params.value;
},
rich: {
total: {
fontSize: 16,
color: "#04F5FE",
},
efficiency: {
fontSize: 12,
color: "#00FD6D",
},
},
color: "#FFFFFF",
fontSize: 12,
lineHeight: 16,
}, },
data: res, data: [],
labelLine: { labelLine: {
show: false, show: false,
}, },
@ -341,11 +232,11 @@ var options = {
colorStops: [ colorStops: [
{ {
offset: 0, offset: 0,
color: color[params.dataIndex], // 0% 处的颜色 color: "transparent", // 0% 处的颜色
}, },
{ {
offset: 1, offset: 1,
color: colorend[params.dataIndex], // 100% 处的颜色 color: colors[params.dataIndex], // 100% 处的颜色
}, },
], ],
globalCoord: false, // 缺省为 false globalCoord: false, // 缺省为 false

6
ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/eventTypeAnalysis/index.vue

@ -43,9 +43,9 @@ export default {
} }
console.log("total88", total) console.log("total88", total)
for (let i = 0; i < data.length; i++) { for (let i = 0; i < data.length; i++) {
if (i % 2 === 0) { // if (i % 2 === 0) {
data.splice(i + 1, 0, newObj) // data.splice(i + 1, 0, newObj)
} // }
if (data[i].name != "") { if (data[i].name != "") {
nameData.push(data[i].name) nameData.push(data[i].name)
} }

40
ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/postTrendsDay/assets/charts.js

@ -1,7 +1,15 @@
/* 数据 */ /* 数据 */
var options = { var options = {
tooltip: {
show: true,
trigger: "axis",
textStyle: {
// color: "#fff",
fontSize: 10,
},
// formatter: "{b}:{c}人",
},
legend: { legend: {
// orient: 'vertical',
icon: "circle", icon: "circle",
itemHeight: 8, itemHeight: 8,
itemWidth: 8, itemWidth: 8,
@ -16,7 +24,7 @@ var options = {
grid: { grid: {
top: "15%", //上边距 top: "15%", //上边距
right: "0", //右边距 right: "0", //右边距
left: "0", //左边距 left: "1px", //左边距
bottom: "10%", //下边距 bottom: "10%", //下边距
containLabel: true, containLabel: true,
}, },
@ -28,7 +36,7 @@ var options = {
}, },
axisLine: { axisLine: {
lineStyle: { lineStyle: {
color: "rgba(49, 217, 255, 0.8)", color: "#2A6278",
}, },
}, },
axisLabel: { axisLabel: {
@ -41,17 +49,19 @@ var options = {
yAxis: [ yAxis: [
{ {
type: "value", type: "value",
name: "", name: "(件)",
max: 1200,
min: 0,
splitNumber: 5,
nameTextStyle: { nameTextStyle: {
color: "#BDC4C7", color: "#E5E7E8",
fontSize: 10, fomtSize: 10,
fontFamily: "Source Han Sans CN-Regular",
align: "left",
verticalAlign: "center",
}, },
// splitNumber: 5,
// nameTextStyle: {
// color: "#BDC4C7",
// fontSize: 10,
// fontFamily: "Source Han Sans CN-Regular",
// align: "left",
// verticalAlign: "center",
// },
axisLabel: { axisLabel: {
fontSize: 10, fontSize: 10,
color: "#E5E7E8", color: "#E5E7E8",
@ -65,7 +75,7 @@ var options = {
}, },
splitLine: { splitLine: {
lineStyle: { lineStyle: {
color: "rgba(49, 217, 255, 0.5)", color: "#2A6278",
}, },
}, },
}, },
@ -101,7 +111,7 @@ var options = {
width: 2, width: 2,
}, },
data: [], // 折线图的数据 data: [5, 20, 40, 15, 20], // 折线图的数据
}, },
{ {
name: "交通事件", name: "交通事件",
@ -133,7 +143,7 @@ var options = {
global: false, global: false,
}, },
}, },
data: [], // 折线图的数据 data: [5, 20, 30, 15, 20], // 折线图的数据
}, },
], ],
}; };

33
ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/postTrendsMonth/assets/charts.js

@ -17,19 +17,19 @@ let data2 = [120, 340, 750, 600, 400, 700, 900, 200];
let data3 = [200, 530, 920, 400, 600, 700, 300, 800]; let data3 = [200, 530, 920, 400, 600, 700, 300, 800];
let options = { let options = {
tooltip: { tooltip: {
show: false, show: true,
trigger: "axis", trigger: "axis",
axisPointer: { axisPointer: {
// 坐标轴指示器,坐标轴触发有效 // 坐标轴指示器,坐标轴触发有效
type: "shadow", // 默认为直线,可选为:'line' | 'shadow' type: "shadow", // 默认为直线,可选为:'line' | 'shadow'
}, },
textStyle: { textStyle: {
color: "#fff", // color: "#fff",
fontSize: 12, fontSize: 10,
}, },
backgroundColor: "rgba(3, 31, 71, .0)", //设置背景颜色 // backgroundColor: "rgba(3, 31, 71, .0)", //设置背景颜色
borderColor: "rgba(3, 31, 71, .0)", // borderColor: "rgba(3, 31, 71, .0)",
formatter: "健康监测<br>{b1}:{c1}人", // formatter: "健康监测<br>{b}:{c}人",
}, },
grid: { grid: {
left: "0", left: "0",
@ -65,9 +65,9 @@ let options = {
}, },
yAxis: [ yAxis: [
{ {
max: 900, // max: 900,
min: 0, // min: 0,
interval: 100, // interval: 100,
axisLine: { axisLine: {
lineStyle: { lineStyle: {
color: "#1C82C5", color: "#1C82C5",
@ -91,16 +91,17 @@ let options = {
}, },
}, },
{ {
max: 90, // max: 90,
min: 0, // min: 60,
interval: 10, // interval: 10,
axisLine: { axisLine: {
lineStyle: { show: false,
color: "#1C82C5", // lineStyle: {
}, // color: "#1C82C5",
// },
}, },
splitLine: { splitLine: {
show: true, show: false,
lineStyle: { lineStyle: {
color: "#2A6278", color: "#2A6278",
type: "solid", type: "solid",

76
ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/postTrendsMonth/assets/charts2.js

@ -3,13 +3,13 @@ let lc = [450, 500, 250, 340, 450, 500];
let lc2 = [400, 550, 200, 140, 400, 550]; let lc2 = [400, 550, 200, 140, 400, 550];
let options = { let options = {
tooltip: { tooltip: {
show: false, show: true,
trigger: "axis", trigger: "axis",
backgroundColor: "rgba(17,95,182,0.5)", //设置背景颜色 // backgroundColor: "rgba(17,95,182,0.5)", //设置背景颜色
textStyle: { textStyle: {
color: "#fff", // color: "#fff",
fontSize: 10,
}, },
fontSize: 12,
// formatter: "{b}:{c}人", // formatter: "{b}:{c}人",
}, },
grid: { grid: {
@ -22,7 +22,7 @@ let options = {
xAxis: { xAxis: {
type: "category", type: "category",
boundaryGap: true, boundaryGap: true,
data: [], data: zData,
axisLabel: { axisLabel: {
interval: 0, interval: 0,
textStyle: { textStyle: {
@ -48,16 +48,12 @@ let options = {
yAxis: [ yAxis: [
{ {
type: "value", type: "value",
// splitNumber: 6,
name: "(起) ", name: "(起) ",
nameTextStyle: { nameTextStyle: {
color: "#E5E7E8", color: "#E5E7E8",
left: 10, left: 10,
fomtSize: 10, fomtSize: 10,
}, },
min: 0,
max: 900,
interval: 100,
axisLabel: { axisLabel: {
show: true, show: true,
textStyle: { textStyle: {
@ -80,21 +76,17 @@ let options = {
}, },
{ {
type: "value", type: "value",
// splitNumber: 6,
name: " (分钟)", name: " (分钟)",
nameTextStyle: { nameTextStyle: {
color: "#E5E7E8", color: "#E5E7E8",
fomtSize: 10, fomtSize: 10,
}, },
min: 0,
max: 90,
interval: 10,
axisLabel: { axisLabel: {
show: true, show: true,
textStyle: { textStyle: {
color: "#fff", color: "#fff",
fontSize: 10, fontSize: 10,
formatter: "{value} °C", // formatter: "{value} °C",
}, },
}, },
// axisLine: { // axisLine: {
@ -104,7 +96,7 @@ let options = {
// show: false, // show: false,
// }, // },
splitLine: { splitLine: {
show: true, show: false,
lineStyle: { lineStyle: {
color: "#2A6278", color: "#2A6278",
}, },
@ -155,16 +147,16 @@ let options = {
name: "事件数量", name: "事件数量",
type: "pictorialBar", type: "pictorialBar",
stack: "数量", stack: "数量",
label: { // label: {
normal: { // normal: {
show: false, // show: false,
position: "top", // position: "top",
textStyle: { // textStyle: {
color: "#FFFFFF", // color: "#FFFFFF",
fontSize: 16, // fontSize: 16,
}, // },
}, // },
}, // },
itemStyle: { itemStyle: {
normal: { normal: {
color: { color: {
@ -189,7 +181,7 @@ let options = {
}, },
symbol: symbol:
"path://M48 0 L49 17 C52 72 68 125 96 173 H0 C25 125 41 73 46 19 L48 0Z", "path://M48 0 L49 17 C52 72 68 125 96 173 H0 C25 125 41 73 46 19 L48 0Z",
data: [], data: lc,
}, },
{ {
name: "去年同期数量", name: "去年同期数量",
@ -197,16 +189,16 @@ let options = {
stack: "else", stack: "else",
barGap: "10%", barGap: "10%",
boundaryGap: "100%", boundaryGap: "100%",
label: { // label: {
normal: { // normal: {
show: false, // show: false,
position: "top", // position: "top",
textStyle: { // textStyle: {
color: "#FFFFFF", // color: "#FFFFFF",
fontSize: 16, // fontSize: 16,
}, // },
}, // },
}, // },
itemStyle: { itemStyle: {
normal: { normal: {
color: { color: {
@ -231,18 +223,19 @@ let options = {
}, },
symbol: symbol:
"path://M48 0 L49 17 C52 72 68 125 96 173 H0 C25 125 41 73 46 19 L48 0Z", "path://M48 0 L49 17 C52 72 68 125 96 173 H0 C25 125 41 73 46 19 L48 0Z",
data: [], data: lc2,
}, },
{ {
name: "平均处置时长", name: "平均处置时长",
yAxisIndex: 1, yAxisIndex: 1,
data: [], data: lc2,
type: "line", type: "line",
symbol: "none", symbol: "none",
symbolSize: 20, symbolSize: 20,
smooth: true, smooth: true,
color: "#E2BA74",
lineStyle: { lineStyle: {
color: "#FB6D07", color: "#E2BA74",
width: 1, width: 1,
type: "dashed", type: "dashed",
// dashOffset:50 // dashOffset:50
@ -251,13 +244,14 @@ let options = {
{ {
name: "去年同期平均处置时长", name: "去年同期平均处置时长",
yAxisIndex: 1, yAxisIndex: 1,
data: [], data: lc,
type: "line", type: "line",
symbol: "none", symbol: "none",
symbolSize: 20, symbolSize: 20,
smooth: true, smooth: true,
color: "#FB6D07",
lineStyle: { lineStyle: {
color: "#E2BA74", color: "#FB6D07",
width: 1, width: 1,
type: "dashed", type: "dashed",
// dashOffset:50 // dashOffset:50

35
ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/postTrendsMonth/assets/charts3.js

@ -1,5 +1,5 @@
// const sxnja = [400, 400, 400]; const sxnja = [400, 400, 400];
// const sxnja2 = [700, 700, 700]; const sxnja2 = [700, 700, 700];
// const minNumber = 90; // const minNumber = 90;
// const minArray = []; // const minArray = [];
@ -22,10 +22,15 @@ var options = {
}, },
}, },
tooltip: { tooltip: {
valueFormatter: function (value) { show: true,
return value; textStyle: {
// return (value + minNumber).toFixed(2) + " %"; // color: "#fff",
fontSize: 10,
}, },
// valueFormatter: function (value) {
// return value;
// // return (value + minNumber).toFixed(2) + " %";
// },
}, },
legend: { legend: {
// orient: 'vertical', // orient: 'vertical',
@ -68,11 +73,6 @@ var options = {
yAxis: [ yAxis: [
{ {
type: "value", type: "value",
min: 0,
max: 900,
interval: 100,
splitNumber: 9,
// max: yAxisMax,
axisLine: { axisLine: {
show: false, show: false,
lineStyle: { lineStyle: {
@ -101,21 +101,12 @@ var options = {
}, },
}, },
{ {
// type: 'value',
// min: function (value) {
// return value.min*0.9;
// },
type: "value", type: "value",
min: 0,
max: 90,
interval: 10,
splitNumber: 9,
// max: yAxisMax,
axisLine: { axisLine: {
show: false, show: false,
}, },
splitLine: { splitLine: {
show: true, show: false,
lineStyle: { lineStyle: {
color: "#2A6278", color: "#2A6278",
opacity: 0.3, opacity: 0.3,
@ -138,7 +129,7 @@ var options = {
series: [ series: [
{ {
name: "事件数量(起)", name: "事件数量(起)",
data: [], data: sxnja2,
type: "pictorialBar", type: "pictorialBar",
symbol: "roundRect", symbol: "roundRect",
symbolRepeat: true, symbolRepeat: true,
@ -153,7 +144,7 @@ var options = {
barGap: "10%", barGap: "10%",
name: "平均处置时长(分钟)", name: "平均处置时长(分钟)",
yAxisIndex: 1, yAxisIndex: 1,
data: [], data: sxnja,
type: "pictorialBar", type: "pictorialBar",
symbol: "roundRect", symbol: "roundRect",
symbolRepeat: true, symbolRepeat: true,

608
ruoyi-ui/src/views/JiHeExpressway/pages/perception/trafficSituation/components/IndicatorAnalysis/components/trafficIndicators/index.vue

@ -1,8 +1,8 @@
<template> <template>
<div class='congestion'> <div class='congestion'>
<WgtTitle :title="'交通指标分析'" ></WgtTitle> <WgtTitle :title="'交通指标分析'"></WgtTitle>
<div class="board"> <div class="board">
<!-- <div class="searchPanel"> <!-- <div class="searchPanel">
<el-select v-model="area" size="mini" class="selectRoad" placeholder="请选择"> <el-select v-model="area" size="mini" class="selectRoad" placeholder="请选择">
<el-option <el-option
v-for="item in areaOptions" v-for="item in areaOptions"
@ -33,398 +33,432 @@
<el-button type="primary" size="mini" class="btnSearch" icon="el-icon-search">查询</el-button> <el-button type="primary" size="mini" class="btnSearch" icon="el-icon-search">查询</el-button>
<el-button class="btnReset" size="mini" icon="el-icon-refresh-left" >重置</el-button> <el-button class="btnReset" size="mini" icon="el-icon-refresh-left" >重置</el-button>
</div> --> </div> -->
<ProgressBar :dataList="dataList" class="keep-ratio progressbar" :selectIndex="7" /> <ProgressBar :dataList="dataList" class="keep-ratio progressbar" :selectIndex="7" />
<div class="body" > <div class="body">
<div style="width:70%" > <div style="width:70%">
<div class="searchPanel_1" > <div class="searchPanel_1">
<!-- <el-from ref="form"> -->
<RadioGroup :options="[{ key: '1', label: '菏泽' }, { key: '3', label: '济南' }]" v-model="direction"
type="button" />
<el-select v-model="type" size="mini" class="selectRoad" placeholder="请选择">
<el-option v-for="item in typeOptions" :key="item.value" :label="item.label" :value="item.value">
</el-option>
</el-select>
<el-select v-model="quarter" size="medium" v-if="type == '3'" class="selectRoad-medium" placeholder="请选择">
<el-option v-for="item in quarterOptions" :key="item.value" :label="item.label" :value="item.value">
</el-option>
</el-select>
<!-- <el-quarter-picker size="mini" class="selectRoad" style="width:180px;" v-if="type == '3'" v-model="dateTime"
aria-placeholder="请选季度" /> -->
<el-date-picker size="mini" v-if="type != '3'" class="selectRoad" v-model="dateTime" style="width:140px;"
:type="type == 1 ? 'date' : type == 2 ? 'month' : type == 4 ? 'year' : ''" placeholder="请选择" />
<el-button type="primary" size="mini" class="btnSearch" @click="searchQuery"
icon="el-icon-search">查询</el-button>
<el-button class="btnReset" size="mini" icon="el-icon-refresh-left" @click="handleClear">重置</el-button>
<!-- </el-from> -->
</div>
<!-- <div class="searchPanel_1">
<el-select v-model="area" size="mini" class="selectRoad" placeholder="请选择"> <el-select v-model="area" size="mini" class="selectRoad" placeholder="请选择">
<el-option <el-option v-for="item in areaOptions" :key="item.value" :label="item.label" :value="item.value">
v-for="item in areaOptions" </el-option>
:key="item.value" </el-select>
:label="item.label" <el-select v-model="year" size="mini" class="selectRoad" placeholder="请选择">
:value="item.value"> <el-option v-for="item in yearOptions" :key="item.value" :label="item.label" :value="item.value">
</el-option> </el-option>
</el-select> </el-select>
<el-select v-model="year" size="mini" class="selectRoad" placeholder="请选择"> <el-date-picker size="mini" v-if="year != 'quarter'" class="selectRoad" v-model="dateTime"
<el-option style="width:140px;" :type="year" placeholder="请选择" />
v-for="item in yearOptions" <el-quarter-picker size="mini" class="selectRoad" style="width:180px;" v-if="year == 'quarter'"
:key="item.value" v-model="quarter" aria-placeholder="请选季度" />
:label="item.label"
:value="item.value">
</el-option>
</el-select>
<el-date-picker
size="mini"
v-if="year != 'quarter'"
class="selectRoad"
v-model="dateTime"
style="width:140px;"
:type="year"
placeholder="请选择"
/>
<el-quarter-picker size="mini" class="selectRoad" style="width:180px;" v-if="year == 'quarter'" v-model="quarter" aria-placeholder="请选季度" />
<el-button type="primary" size="mini" class="btnSearch" icon="el-icon-search">查询</el-button> <el-button type="primary" size="mini" class="btnSearch" icon="el-icon-search">查询</el-button>
<el-button class="btnReset" size="mini" icon="el-icon-refresh-left" >重置</el-button> <el-button class="btnReset" size="mini" icon="el-icon-refresh-left">重置</el-button>
</div> -->
<div id="chart1" class="keep-ratio"></div>
</div> </div>
<div id="chart1" class="keep-ratio" ></div> <div class="chartOrg">
<div class="itemChart">
<div class="title">上月指标</div>
<div id="chart2" class="keep-ratio"></div>
</div> </div>
<div class="chartOrg" > <div class="itemChart">
<div class="itemChart" > <div class="title">上月指标</div>
<div class="title">上月指标</div> <div id="chart3" class="keep-ratio"></div>
<div id="chart2" class="keep-ratio" ></div>
</div>
<div class="itemChart" >
<div class="title">上月指标</div>
<div id="chart3" class="keep-ratio" ></div>
</div>
</div> </div>
</div> </div>
</div>
</div>
</div> </div>
</template>
</div>
<script> </template>
import WgtTitle from '../../../../../widgets/title' <script>
import ProgressBar from './progressBar.vue'; import RadioGroup from '@screen/components/FormConfig/components/RadioGroup/index.vue';
import * as echarts from "echarts"; import WgtTitle from '../../../../../widgets/title'
import chart1 from "./assets/charts"; import ProgressBar from './progressBar.vue';
import chart2 from "./assets/charts2"; import * as echarts from "echarts";
import chart3 from "./assets/charts3"; import chart1 from "./assets/charts";
import ElQuarterPicker from './ElQuarterPicker' import chart2 from "./assets/charts2";
import chart3 from "./assets/charts3";
const drawRoundRect = ( ctx, x, y, width, height, radius ,gr) => { import ElQuarterPicker from './ElQuarterPicker'
const drawRoundRect = (ctx, x, y, width, height, radius, gr) => {
// ctx, x, y, , , // ctx, x, y, , ,
ctx.beginPath(); ctx.beginPath();
ctx.fillStyle = gr; ctx.fillStyle = gr;
ctx.arc(x + radius, y + radius, radius, Math.PI, Math.PI * 3 / 2); ctx.arc(x + radius, y + radius, radius, Math.PI, Math.PI * 3 / 2);
ctx.lineTo(width - radius + x, y); ctx.lineTo(width - radius + x, y);
ctx.arc(width - radius + x, radius + y, radius, Math.PI * 3 / 2, Math.PI * 2); ctx.arc(width - radius + x, radius + y, radius, Math.PI * 3 / 2, Math.PI * 2);
ctx.lineTo(width + x, height + y - radius); ctx.lineTo(width + x, height + y - radius);
ctx.arc(width - radius + x, height - radius + y, radius, 0, Math.PI * 1 / 2); ctx.arc(width - radius + x, height - radius + y, radius, 0, Math.PI * 1 / 2);
ctx.lineTo(radius + x, height +y); ctx.lineTo(radius + x, height + y);
ctx.arc(radius + x, height - radius + y, radius, Math.PI * 1 / 2, Math.PI); ctx.arc(radius + x, height - radius + y, radius, Math.PI * 1 / 2, Math.PI);
ctx.closePath(); ctx.closePath();
//ctx.stroke(); //ctx.stroke();
ctx.fill() ctx.fill()
} }
export default { export default {
name: 'EventQuery', name: 'EventQuery',
components: { components: {
WgtTitle, RadioGroup,
ProgressBar, WgtTitle,
ElQuarterPicker ProgressBar,
}, ElQuarterPicker
data() { },
return { data() {
yearOptions:[ return {
direction: "1",
type: "1",
typeOptions: [
{
label: '年',
value: '4'
},
{
label: '月',
value: '2'
},
{
label: '日',
value: '1'
},
{
label: '季',
value: '3'
}
],
quarter: '1',
quarterOptions: [
{
label: "第一季度",
value: "1"
},
{ {
value: 'year', label: "第二季度",
label: '年' value: "2"
},{
value: 'month',
label: '月'
}, },
{ {
value: 'date', label: "第三季度",
label: '日' value: "3"
}, },
{ {
value: 'quarter', label: "第四季度",
label: '季' value: "4"
},], }
areaOptions: [{ ],
value: '济南', dateTime: "2024-01-01 00:00:00",
label: '济南' dataList: [
}, {
value: '菏泽',
label: '菏泽'
}],
dateTime:"",
area: '济南',
dataList:[
{ {
title:"殷家林枢纽" title: "殷家林枢纽"
}, },
{ {
title:"大学城立交" title: "大学城立交"
}, },
{ {
title:"长清立交" title: "长清立交"
}, },
{ {
title:"松竹枢纽" title: "松竹枢纽"
}, },
{ {
title:"孝里立交" title: "孝里立交"
}, },
{ {
title:"平阴立交" title: "平阴立交"
}, },
{ {
title:"孔村枢纽" title: "孔村枢纽"
}, },
{ {
title:"平阴南立交" title: "平阴南立交"
}, },
{ {
title:"魏雪枢纽" title: "魏雪枢纽"
}, },
{ {
title:"东平立交" title: "东平立交"
}, },
{ {
title:"东平湖枢纽" title: "东平湖枢纽"
}, },
{ {
title:"韩岗立交" title: "韩岗立交"
}, },
{ {
title:"梁山立交" title: "梁山立交"
}, },
{ {
title:"鄄郓枢纽" title: "鄄郓枢纽"
}, },
{ {
title:"嘉祥西立交" title: "嘉祥西立交"
}, },
{ {
title:"王官屯枢纽" title: "王官屯枢纽"
} }
], ],
quarter:"", quarter: "",
year:"", year: "",
list:[ list: [
{name:'大学城-长清', direction:'济南方向', state:"正常",speed:'108.14km/h', follow:'161'}, { name: '大学城-长清', direction: '济南方向', state: "正常", speed: '108.14km/h', follow: '161' },
{name:'大学城-长清', direction:'济南方向', state:"正常",speed:'108.14km/h', follow:'161'}, { name: '大学城-长清', direction: '济南方向', state: "正常", speed: '108.14km/h', follow: '161' },
{name:'大学城-长清', direction:'济南方向', state:"正常",speed:'108.14km/h', follow:'161'}, { name: '大学城-长清', direction: '济南方向', state: "正常", speed: '108.14km/h', follow: '161' },
{name:'大学城-长清', direction:'济南方向', state:"正常",speed:'108.14km/h', follow:'161'}, { name: '大学城-长清', direction: '济南方向', state: "正常", speed: '108.14km/h', follow: '161' },
{name:'大学城-长清', direction:'济南方向', state:"正常",speed:'108.14km/h', follow:'161'}, { name: '大学城-长清', direction: '济南方向', state: "正常", speed: '108.14km/h', follow: '161' },
{name:'大学城-长清', direction:'济南方向', state:"正常",speed:'108.14km/h', follow:'161'} { name: '大学城-长清', direction: '济南方向', state: "正常", speed: '108.14km/h', follow: '161' }
] ]
} }
}, },
created() { created() {
}, },
methods: { methods: {
}, },
mounted() { mounted() {
setTimeout(() => { setTimeout(() => {
this.$nextTick(() => { this.$nextTick(() => {
var myChart1 = echarts.init(document.getElementById('chart1')); var myChart1 = echarts.init(document.getElementById('chart1'));
myChart1.setOption(chart1); myChart1.setOption(chart1);
var myChart2 = echarts.init(document.getElementById('chart2')); var myChart2 = echarts.init(document.getElementById('chart2'));
myChart2.setOption(chart2); myChart2.setOption(chart2);
var myChart3 = echarts.init(document.getElementById('chart3')); var myChart3 = echarts.init(document.getElementById('chart3'));
myChart3.setOption(chart2); myChart3.setOption(chart2);
const domMap = document.getElementById("chart2"); const domMap = document.getElementById("chart2");
let parentDiv = domMap.firstChild; let parentDiv = domMap.firstChild;
// canvas // canvas
let canvas = document.createElement('canvas'); let canvas = document.createElement('canvas');
canvas.width = parentDiv.offsetWidth; canvas.width = parentDiv.offsetWidth;
canvas.height =parentDiv.offsetHeight; canvas.height = parentDiv.offsetHeight;
parentDiv.appendChild(canvas); parentDiv.appendChild(canvas);
const context = canvas.getContext('2d'); const context = canvas.getContext('2d');
// //
var gr = context.createLinearGradient(247, 63, 450, 0); var gr = context.createLinearGradient(247, 63, 450, 0);
// //
gr.addColorStop(1, 'rgba(92,197,255,0)'); gr.addColorStop(1, 'rgba(92,197,255,0)');
gr.addColorStop(0, 'rgba(92,197,255,0.5)'); gr.addColorStop(0, 'rgba(92,197,255,0.5)');
context.lineWidth = 1; // 线 context.lineWidth = 1; // 线
// //
drawRoundRect(context, 300, 78, 160, 24, 12,gr) drawRoundRect(context, 300, 78, 160, 24, 12, gr)
var gr = context.createLinearGradient(240, 63, 450, 0); var gr = context.createLinearGradient(240, 63, 450, 0);
// //
gr.addColorStop(1, 'rgba(92,197,255,0)'); gr.addColorStop(1, 'rgba(92,197,255,0)');
gr.addColorStop(0, 'rgba(92,197,255,0.5)'); gr.addColorStop(0, 'rgba(92,197,255,0.5)');
drawRoundRect(context, 300, 148, 160, 24, 12,gr) drawRoundRect(context, 300, 148, 160, 24, 12, gr)
var gr = context.createLinearGradient(240, 63, 450, 0); var gr = context.createLinearGradient(240, 63, 450, 0);
// //
gr.addColorStop(1, 'rgba(92,197,255,0)'); gr.addColorStop(1, 'rgba(92,197,255,0)');
gr.addColorStop(0, 'rgba(92,197,255,0.5)'); gr.addColorStop(0, 'rgba(92,197,255,0.5)');
drawRoundRect(context, 300, 218, 160, 24, 12,gr) drawRoundRect(context, 300, 218, 160, 24, 12, gr)
var gr = context.createLinearGradient(400, 63, 450, 0); var gr = context.createLinearGradient(400, 63, 450, 0);
// //
gr.addColorStop(1, 'rgba(92,197,255,0)'); gr.addColorStop(1, 'rgba(92,197,255,0)');
gr.addColorStop(0, 'rgba(92,197,255,0.5)'); gr.addColorStop(0, 'rgba(92,197,255,0.5)');
drawRoundRect(context, 460, 78, 160, 24, 12,gr)
drawRoundRect(context, 460, 78, 160, 24, 12, gr)
var gr = context.createLinearGradient(350, 63, 450, 0); var gr = context.createLinearGradient(350, 63, 450, 0);
// //
gr.addColorStop(1, 'rgba(92,197,255,0)'); gr.addColorStop(1, 'rgba(92,197,255,0)');
gr.addColorStop(0, 'rgba(92,197,255,0.5)'); gr.addColorStop(0, 'rgba(92,197,255,0.5)');
drawRoundRect(context, 460, 148, 160, 24, 12,gr) drawRoundRect(context, 460, 148, 160, 24, 12, gr)
var gr = context.createLinearGradient(300, 63, 450, 0); var gr = context.createLinearGradient(300, 63, 450, 0);
// //
gr.addColorStop(1, 'rgba(92,197,255,0)'); gr.addColorStop(1, 'rgba(92,197,255,0)');
gr.addColorStop(0, 'rgba(92,197,255,0.5)'); gr.addColorStop(0, 'rgba(92,197,255,0.5)');
drawRoundRect(context, 460, 218, 160, 24, 12,gr) drawRoundRect(context, 460, 218, 160, 24, 12, gr)
});
}); });
}, });
} },
</script> }
</script>
<style lang='scss' scoped> <style lang='scss' scoped>
.progressbar { .progressbar {
margin:10px; margin: 10px;
}
.congestion { }
.congestion {
width: 100%;
.body {
display: flex;
flex-direction: row;
align-items: center;
height: 395px;
width: 100%; width: 100%;
.body { font-size: 14px;
display: flex;
flex-direction: row;
align-items: center;
height: 395px;
width:100%;
font-size: 14px;
> div {
display: inline-flex;
flex-direction: column;
height:100%;
width:33%;
margin-right:20px;
border: 1px solid;
border-image: linear-gradient(360deg, rgba(55, 231, 255,0.1), rgba(55, 231, 255, 0)) 1 1;
background: linear-gradient(180deg, rgba(6,66,88,0) 0%, #064258 100%);
padding: 10px;
}
.chartOrg {
flex-direction: row !important;
>div {
display: inline-flex;
flex-direction: column;
width:50%;
height:100%;
}
.itemChart { >div {
display: inline-flex;
>.title { flex-direction: column;
display: inline-flex; height: 100%;
width:100%; width: 33%;
height:30px; margin-right: 20px;
font-size: 16px; border: 1px solid;
font-family: PingFang SC, PingFang SC; border-image: linear-gradient(360deg, rgba(55, 231, 255, 0.1), rgba(55, 231, 255, 0)) 1 1;
font-weight: 500; background: linear-gradient(180deg, rgba(6, 66, 88, 0) 0%, #064258 100%);
color: #30BFEC; padding: 10px;
} }
#chart2 { .chartOrg {
display: inline-flex; flex-direction: row !important;
width:100%;
height:100%; >div {
} display: inline-flex;
flex-direction: column;
#chart3 { width: 50%;
display: inline-flex; height: 100%;
width:100%; }
height:100%;
} .itemChart {
}
>.title {
display: inline-flex;
width: 100%;
height: 30px;
font-size: 16px;
font-family: PingFang SC, PingFang SC;
font-weight: 500;
color: #30BFEC;
} }
#chart1 { #chart2 {
display: inline-flex; display: inline-flex;
height:100%; width: 100%;
width:100%; height: 100%;
}
#chart3 {
display: inline-flex;
width: 100%;
height: 100%;
} }
} }
}
.board{ #chart1 {
height:320px; display: inline-flex;
height: 100%;
width: 100%; width: 100%;
padding:10px 0px; }
}
border-radius: 5px 5px 5px 5px;
opacity: 1; .board {
height: 320px;
width: 100%;
padding: 10px 0px;
border-radius: 5px 5px 5px 5px;
opacity: 1;
display: flex;
justify-content: space-between;
align-items: center;
flex-direction: column;
.searchPanel_1 {
position: absolute;
display: flex; display: flex;
justify-content: space-between;
align-items: center; align-items: center;
flex-direction: column; height: 40px;
width: 100%;
font-size: 14px;
margin-bottom: 10px;
z-index: 1000;
div {
.searchPanel_1{ white-space: nowrap;
position:absolute; margin-right: 4px;
display: flex; }
align-items: center;
height: 40px; .inputZh {
width:100%; width: 47px;
font-size: 14px;
margin-bottom: 10px; ::v-deep {
z-index: 1000; .el-input__inner {
background-color: #064258 !important;
div{ border-width: 0px !important;
white-space: nowrap; }
margin-right: 4px;
}
.inputZh{
width: 47px;
::v-deep{
.el-input__inner{
background-color: #064258 !important;
border-width: 0px !important;
} }
} }
}
.inputJl{ .inputJl {
margin-left: 5px; margin-left: 5px;
margin-right: 10px; margin-right: 10px;
} }
.selectRoad{
width:89px; .selectRoad {
border:1px solid #00B3CC; width: 89px;
::v-deep{ border: 1px solid #00B3CC;
.el-input__inner{
background-color: #064258 !important; ::v-deep {
border-width: 0px !important; .el-input__inner {
background-color: #064258 !important;
border-width: 0px !important;
}
} }
} }
}
.btnSearch{
background: linear-gradient(180deg, #005C79 0%, #009BCC 100%);
margin-left: 10px;
border-color: transparent;
}
.btnReset{
background: linear-gradient(180deg, #005C79 0%, #009BCC 100%);;
border-color: transparent;
color: white;
}
}
.btnSearch {
background: linear-gradient(180deg, #005C79 0%, #009BCC 100%);
margin-left: 10px;
border-color: transparent;
}
.btnReset {
background: linear-gradient(180deg, #005C79 0%, #009BCC 100%);
;
border-color: transparent;
color: white;
}
} }
} }
.charts { }
height:100px;
width: 100%; .charts {
} height: 100px;
width: 100%;
</style> }
</style>

8
ruoyi-ui/src/views/JiHeExpressway/scss/el-reset.scss

@ -167,6 +167,14 @@ div.el-date-editor {
div.el-popover:has(> .el-date-picker), div.el-popover:has(> .el-date-picker),
div.el-picker-panel.el-date-picker.el-popper, div.el-picker-panel.el-date-picker.el-popper,
div.el-picker-panel.el-date-range-picker.el-popper { div.el-picker-panel.el-date-range-picker.el-popper {
.disabled{
div{
span{
color: #5E8998!important;
}background: #1B586D;
}
}
.next-month, .next-month,
.prev-month { .prev-month {
span { span {

Loading…
Cancel
Save