Compare commits

..

No commits in common. "48c2c26aecde8546da0406c74bdf15a6c3b5312b" and "b8ae2abd04473330c7331b364653edbfbd594179" have entirely different histories.

12 changed files with 59 additions and 100 deletions

View File

@ -136,7 +136,7 @@ export default {
visibleNumber: 3,
// index
currentNav: 0,
value: localStorage.getItem("data-theme") || 'default',
value: localStorage.getItem("data-theme"),
curTheme: 'default',
themeOptions: [
{
@ -201,10 +201,10 @@ export default {
mounted() {
// console.log("storeState", this.$store.state);
this.setVisibleNumber();
this.handleSwitchChange(this.value)
},
methods: {
handleSwitchChange(val) {
console.log('switch value', val);
const themeFilePathMap = {
'default': '/theme/default/elementui/index.css',
'redTheme': '/theme/redTheme/elementui/index.css',

View File

@ -179,7 +179,6 @@ export default {
</script>
<style lang="scss" scoped>
@import '@/theme/index.scss';
.dropdown-item-more {
position: relative;
font-size: 14px;
@ -207,7 +206,9 @@ export default {
}
}
.dropdown-item-more-right {
@include background_color(buttonBackgroundColor);
// background: $--custom-dropdown-background;
background: linear-gradient(to bottom, #04132a, #112144);
// border: 1px solid #1dc4e7;
border-radius: 6px;
width: 100px;
overflow: hidden;

View File

@ -12,7 +12,6 @@ $blueTheme: (
buttonFontColor: #000,
buttonActiveBackgroundColor:#013dac,
buttonActiveFontColor: #fff,
tableRowBackgroundColor: #ffffffaa,
// 定制颜色定制背景图
basicBackgroundColor: #000000,

View File

@ -12,7 +12,6 @@ $default: (
buttonFontColor: #7dabdc,
buttonActiveBackgroundColor: #42b983,
buttonActiveFontColor: #fff,
tableRowBackgroundColor: #000000b4,
// 定制颜色定制背景图
basicBackgroundColor: #000000,

View File

@ -12,7 +12,6 @@ $redTheme: (
buttonFontColor: #000,
buttonActiveBackgroundColor: #ad352f,
buttonActiveFontColor: #fff,
tableRowBackgroundColor: #ffffffb5,
// 定制颜色定制背景图
basicBackgroundColor: #000000,

View File

@ -214,7 +214,7 @@ export default {
<style lang="scss">
@import '@/theme/index.scss';
.color-row {
@include background_color(tableRowBackgroundColor);
background-color: #0b2d57 !important;
}
.header-row {
background: linear-gradient(180deg, #0b2357 0%, #2094dc 48%, #0b2357 100%);

View File

@ -133,10 +133,9 @@ export default {
},
};
</script>
<style lang="scss">
@import '@/theme/index.scss';
<style>
.color-row {
@include background_color(tableRowBackgroundColor);
background-color: #0b2d57 !important;
}
.header-row {
background: linear-gradient(180deg, #0b2357 0%, #2094dc 48%, #0b2357 100%);

View File

@ -133,10 +133,9 @@ export default {
},
};
</script>
<style lang="scss">
@import '@/theme/index.scss';
<style>
.color-row {
@include background_color(tableRowBackgroundColor);
background-color: #0b2d57 !important;
}
.header-row {
background: linear-gradient(180deg, #0b2357 0%, #2094dc 48%, #0b2357 100%);

View File

@ -133,10 +133,9 @@ export default {
},
};
</script>
<style lang="scss">
@import '@/theme/index.scss';
<style>
.color-row {
@include background_color(tableRowBackgroundColor);
background-color: #0b2d57 !important;
}
.header-row {
background: linear-gradient(180deg, #0b2357 0%, #2094dc 48%, #0b2357 100%);

View File

@ -191,9 +191,9 @@ export default {
};
</script>
<style lang="scss">
@import '@/theme/index.scss';
@import "@/theme/index.scss";
.color-row {
@include background_color(tableRowBackgroundColor);
background-color: #67c7ff !important;
}
.header-row {
background: linear-gradient(180deg, #0b2357 0%, #2094dc 48%, #0b2357 100%);

View File

@ -149,9 +149,9 @@ export default {
};
</script>
<style lang="scss">
@import '@/theme/index.scss';
@import "@/theme/index.scss";
.color-row {
@include background_color(tableRowBackgroundColor);
background-color: #67c7ff !important;
}
.header-row {
background: linear-gradient(180deg, #0b2357 0%, #2094dc 48%, #0b2357 100%);

View File

@ -3,22 +3,17 @@
<div class="grid-main-wrapper">
<div class="grid-item-wrapper">
<div class="card-item-wrapper">
<div class="card-big-title">{{ title1 }}数据监控</div>
<div class="card-big-title">R上辊操作侧数据监控</div>
<div class="card-sub-title">油膜轴承振动监测</div>
<div class="card-main-item-wrapper" id="chart1" style="height:calc(100% - 6.4rem);"></div>
</div>
</div>
<div class="grid-item-wrapper" style="grid-row: span 2;grid-column: span 2;padding: 2rem;">
<div class="device-image">
<div @click="handleTypeChange(['rtd', 'rto'])"></div>
<div @click="handleTypeChange(['rbd', 'rbo'])"></div>
<div @click="handleTypeChange(['ftd', 'fto'])"></div>
<div @click="handleTypeChange(['fbd', 'fbo'])"></div>
</div>
<div class="device-image"></div>
</div>
<div class="grid-item-wrapper">
<div class="card-item-wrapper">
<div class="card-big-title">{{ title2 }}数据监控</div>
<div class="card-big-title">R上棍传动侧数据监控</div>
<div class="card-sub-title">油膜轴承振动监测</div>
<div class="card-main-item-wrapper" id="chart2" style="height:calc(100% - 6.4rem);"></div>
</div>
@ -141,79 +136,51 @@ export default {
l2: 0,
r1: 0,
r2: 0,
title1: '',
title2: '',
timer: null,
queryParams: ['rtd', 'rto']
r2: 0
}
},
mounted() {
this.timer = setInterval(() => {
this.initData(this.queryParams)
}, 1000)
this.handleTypeChange(this.queryParams)
},
beforeDestroy() {
clearInterval(this.timer)
this.getDataResponse(['rtd', 'rto']).then(({ data }) => {
console.log('RREESS', data);
const { drive, operation } = data;
//
if (drive) {
const { xSensorData, vx, vy, vz } = drive;
this.initChart2(xSensorData, vx, vy, vz)
const { xPlcData, pz4, pz6, pz14, pz21 } = drive
this.initChart4(xPlcData, pz4, pz6, pz14, pz21)
const { ssat, rot, oip, ov, owc } = drive
this.initBottomR1(oip)
this.initBottomR2(ov)
this.initBottomR3(owc)
console.log('ssat', ssat);
this.r1 = ssat
this.r2 = rot
}
//
if (operation) {
const { xSensorData, vx, vy, vz } = operation;
this.initChart1(xSensorData, vx, vy, vz)
const { xPlcData, pz4, pz6, pz14, pz21 } = operation;
this.initChart3(xPlcData, pz4, pz6, pz14, pz21)
const { owc, ov, oip, rot, ssat } = operation
this.initBottomL1(owc)
this.initBottomL2(ov)
this.initBottomL3(oip)
this.l1 = rot
this.l2 = ssat
}
})
},
methods: {
handleTypeChange(params) {
this.queryParams = params
const titleMap = {
'rtd': 'R上辊传动侧',
'rto': 'R上辊操作侧',
'rbd': 'R下辊传动侧',
'rbo': 'R下辊操作侧',
'ftd': 'F上辊传动侧',
'fto': 'F上辊操作侧',
'fbd': 'F下辊传动侧',
'fbo': 'F下辊操作侧'
}
this.title1 = titleMap[params[0]]
this.title2 = titleMap[params[1]]
},
initData(params = []) {
this.getDataResponse(params).then(({ data }) => {
const { drive, operation } = data;
//
if (drive) {
const { xSensorData, vx, vy, vz } = drive;
this.initChart2(xSensorData, vx, vy, vz)
const { xPlcData, pz4, pz6, pz14, pz21 } = drive
this.initChart4(xPlcData, pz4, pz6, pz14, pz21)
const { ssat, rot, oip, ov, owc } = drive
this.initBottomR1(oip)
this.initBottomR2(ov)
this.initBottomR3(owc)
console.log('ssat', ssat);
this.r1 = ssat
this.r2 = rot
}
//
if (operation) {
const { xSensorData, vx, vy, vz } = operation;
this.initChart1(xSensorData, vx, vy, vz)
const { xPlcData, pz4, pz6, pz14, pz21 } = operation;
this.initChart3(xPlcData, pz4, pz6, pz14, pz21)
const { owc, ov, oip, rot, ssat } = operation
this.initBottomL1(owc)
this.initBottomL2(ov)
this.initBottomL3(oip)
this.l1 = rot
this.l2 = ssat
}
})
},
initChart1(xAxis = [], vx, vy, vz) {
const chartIns = echarts.init(document.getElementById("chart1"));
chartIns.setOption(this.generateOptions({
@ -813,9 +780,6 @@ export default {
background-size: contain;
background-repeat: no-repeat;
background-position: center center;
display: grid;
grid-template-columns: 1fr 1fr;
grid-template-rows: 1fr 1fr;
}
.bottom-grid-wrapper {