You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

468 lines
10 KiB
Vue

2 years ago
<template>
<div class="app-container">
2 years ago
<div class="headTitle">内胆数据监控平台</div>
<div class="topNum team">{{ team }}</div>
<div class="topNum planNum">{{ planNum }}</div>
<div class="topNum practicalNum">{{ practicalNum }}</div>
<div class="topNum differenceValue">{{ differenceValue }}</div>
<div class="title" v-for="(i,k) in title"
:style="'top:'+(titlePosition[k]&&titlePosition[k].top||0)+'%;left:'+(titlePosition[k]&&titlePosition[k].left||0)+'%'">
{{ i }}
</div>
<div class="scrollTable">
2 years ago
<div style="background-color: #09417066">
2 years ago
<div class="scrollTableItem" style="font-weight: bold;">
2 years ago
产品型号
2 years ago
</div>
<div class="scrollTableItem" style="font-weight: bold;">
计划数量
</div>
<div class="scrollTableItem" style="font-weight: bold;">
2 years ago
完成数量
2 years ago
</div>
<div class="scrollTableItem" style="font-weight: bold;">
2 years ago
生产进度
2 years ago
</div>
<div class="scrollTableItem" style="font-weight: bold;">
2 years ago
开始时间
2 years ago
</div>
</div>
<vue-seamless-scroll
:class-option="scrollTableOption"
:data="scrollTableData"
class="case-item"
style="height: 84%;overflow: hidden;"
>
<div
v-for="(item, index) in scrollTableData"
:key="index"
>
2 years ago
<div :style='"background-color:" + ((index % 2 === 0)? "#05346066":"#032d5766") '>
2 years ago
<div
class="scrollTableItem">
{{ item.name }}
</div>
<div
class="scrollTableItem">
{{ item.value }}
</div>
<div
class="scrollTableItem">
{{ item.value2 }}
</div>
<div
class="scrollTableItem">
{{ item.value2 }}
</div>
<div
class="scrollTableItem">
{{ item.value2 }}
</div>
</div>
</div>
</vue-seamless-scroll>
</div>
<div class="chart1">
<Chart ref="chart1"></Chart>
</div>
<div class="chart2">
<Chart ref="chart2"></Chart>
</div>
<div class="chart3">
<Chart ref="chart3"></Chart>
</div>
2 years ago
</div>
</template>
<script>
2 years ago
import vueSeamlessScroll from "vue-seamless-scroll";
import Chart from "../../../components/board/Chart";
import * as echarts from 'echarts'
2 years ago
export default {
2 years ago
components: {
vueSeamlessScroll,
Chart
},
2 years ago
name: "Liner",
data() {
return {
2 years ago
title: [
'工单计划',
'出入库统计',
'库存状态',
'发泡夹具状态',
],
titlePosition: [
{
top: 19.8,
left: 5.5
},
{
top: 19.8,
left: 53
},
{
top: 70.5,
left: 5.5
},
{
top: 70.5,
left: 53
},
],
team: '白班',
planNum: 1000,
practicalNum: 1000,
differenceValue: 1000,
scrollTableOption: {
step: 0.5, // 数值越大速度滚动越快
limitMoveNum: 5, // 开始无缝滚动的数据量 this.dataList.length
hoverStop: true, // 是否开启鼠标悬停stop
direction: 1, // 0向下 1向上 2向左 3向右
openWatch: true, // 开启数据实时监控刷新dom
singleHeight: 0, // 单步运动停止的高度(默认值0是无缝不停止的滚动) direction => 0/1
singleWidth: 0, // 单步运动停止的宽度(默认值0是无缝不停止的滚动) direction => 2/3
waitTime: 0,
},
scrollTableData: [
{
value: 1,
value2: 1,
name: '1',
},
{
value: 1,
value2: 1,
name: '1',
},
{
value: 1,
value2: 1,
name: '1',
},
{
value: 1,
value2: 1,
name: '1',
},
{
value: 1,
value2: 1,
name: '1',
},
],
2 years ago
}
},
2 years ago
mounted() {
this.$refs.chart1.setData({
tooltip: {
trigger: "axis",
axisPointer: {
// 坐标轴指示器,坐标轴触发有效
type: "shadow", // 默认为直线,可选为:'line' | 'shadow'
},
},
grid: {
left: "0",
right: "4%",
bottom: "0",
top: "5%",
containLabel: true,
},
legend: {
data: ["入库", "出库"],
right: 'center',
top: 0,
textStyle: {
color: "#fff",
},
itemWidth: 12,
itemHeight: 10,
// itemGap: 35
},
xAxis: {
type: "category",
data: ["01:00", "02:00", "03:00", "04:00", "05:00", "06:00", "07:00", "08:00"],
axisLine: {
lineStyle: {
color: "white",
},
},
axisLabel: {
// interval: 0,
// rotate: 40,
textStyle: {
fontFamily: "Microsoft YaHei",
},
},
},
yAxis: {
type: "value",
axisLine: {
show: false,
lineStyle: {
color: "white",
},
},
splitLine: {
show: false,
},
axisLabel: {},
},
series: [
{
name: "入库",
type: "bar",
2 years ago
barWidth: "30%",
barMaxWidth: 50,
2 years ago
itemStyle: {
normal: {
color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
{
offset: 0,
color: "#39ffff",
},
{
offset: 1,
color: "#5affa6",
},
]),
},
},
data: [400, 400, 300, 300, 300, 400, 400, 400],
},
{
name: "出库",
type: "bar",
2 years ago
barWidth: "30%",
barMaxWidth: 50,
2 years ago
itemStyle: {
normal: {
color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
{
offset: 0,
color: "#4adfff",
},
{
offset: 1,
color: "#3d7aff",
},
]),
},
},
data: [400, 500, 500, 500, 500, 400, 400, 500],
},
],
})
this.$refs.chart2.setData({
tooltip: {
trigger: "axis",
axisPointer: {
// 坐标轴指示器,坐标轴触发有效
type: "shadow", // 默认为直线,可选为:'line' | 'shadow'
},
},
grid: {
left: "0",
right: "4%",
bottom: "0",
top: "5%",
containLabel: true,
},
legend: {
data: ["内胆", "箱壳"],
right: 'center',
top: 0,
textStyle: {
color: "#fff",
},
itemWidth: 12,
itemHeight: 10,
// itemGap: 35
},
xAxis: {
type: "category",
data: ["A-01", "A-02", "A-03", "A-04", "A-05", "A-06", "A-07", "A-08"],
axisLine: {
lineStyle: {
color: "white",
},
},
axisLabel: {
// interval: 0,
// rotate: 40,
textStyle: {
fontFamily: "Microsoft YaHei",
},
},
},
yAxis: {
type: "value",
axisLine: {
show: false,
lineStyle: {
color: "white",
},
},
splitLine: {
show: false,
},
axisLabel: {},
},
series: [
{
name: "内胆",
type: "bar",
2 years ago
barWidth: "30%",
barMaxWidth: 50,
2 years ago
itemStyle: {
normal: {
color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
{
offset: 0,
color: "#39ffff",
},
{
offset: 1,
color: "#5affa6",
},
]),
},
},
data: [400, 400, 300, 300, 300, 400, 400, 400],
},
{
name: "箱壳",
type: "bar",
2 years ago
barWidth: "30%",
barMaxWidth: 50,
2 years ago
itemStyle: {
normal: {
color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
{
offset: 0,
color: "#4adfff",
},
{
offset: 1,
color: "#3d7aff",
},
]),
},
},
data: [400, 500, 500, 500, 500, 400, 400, 500],
},
],
})
2 years ago
},
methods: {}
};
</script>
<style scoped>
.app-container {
background-image: url("../../../assets/board/liner.jpg");
background-repeat: no-repeat;
background-size: 100% 100%;
width: 100%;
height: 100%;
position: absolute;
top: 0;
left: 0;
}
2 years ago
.headTitle {
position: absolute;
top: 5%;
left: 50%;
transform: translate(-50%, -100%);
font-size: 1.5vw;
color: #d6eaed;
letter-spacing: 10px;
}
.title {
position: absolute;
transform: translateY(-50%);
color: #5db9e8;
font-size: 0.9vw;
}
.topNum {
position: absolute;
transform: translate(-50%, -50%);
color: #5db9e8;
top: 11.7%;
letter-spacing: 0.5vw;
}
.team {
font-size: 1.5vw;
left: 16.8%;
}
.planNum {
font-size: 1.7vw;
left: 41.2%;
}
.practicalNum {
left: 66.2%;
font-size: 1.7vw;
}
.differenceValue {
font-size: 1.7vw;
left: 90.7%;
}
.scrollTable {
position: absolute;
top: 23%;
left: 4%;
width: 45%;
height: 18%;
}
.scrollTableItem {
color: rgb(185, 186, 192);
margin: auto 0px;
padding: 4px 0;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
text-align: center;
display: inline-block;
2 years ago
width: 20%;
2 years ago
}
.chart1 {
position: absolute;
top: 24%;
left: 51%;
width: 45%;
height: 17%;
}
.chart2 {
position: absolute;
top: 74%;
left: 3.6%;
width: 45.5%;
height: 20.7%;
}
.chart3 {
position: absolute;
top: 74%;
left: 51%;
width: 45.5%;
height: 20.7%;
}
2 years ago
</style>