update
This commit is contained in:
parent
79b6f1d141
commit
d6b71ae0bb
@ -287,7 +287,7 @@ export default {
|
|||||||
"待机时长(min)": "Standby time(min)",
|
"待机时长(min)": "Standby time(min)",
|
||||||
"设备版本": "Version",
|
"设备版本": "Version",
|
||||||
"厂家电话": "MFR Phone",
|
"厂家电话": "MFR Phone",
|
||||||
"设备负责人": "Leader",
|
"负责人": "Leader",
|
||||||
"生产日期": "Produce Date",
|
"生产日期": "Produce Date",
|
||||||
"投产日期": "Start Date",
|
"投产日期": "Start Date",
|
||||||
"设备位置": "Location",
|
"设备位置": "Location",
|
||||||
@ -491,5 +491,41 @@ export default {
|
|||||||
'异常停机分类统计':'Exceptional Stop Classification',
|
'异常停机分类统计':'Exceptional Stop Classification',
|
||||||
'次':'times',
|
'次':'times',
|
||||||
'报警':'Alarm',
|
'报警':'Alarm',
|
||||||
|
'扫描速度':'Scan Speed',
|
||||||
|
'识别状态':'Recognition Status',
|
||||||
|
'扫描次数':'Scan Count',
|
||||||
|
'识别数量':'Recognition Count',
|
||||||
|
'总识别时长':'Total Recognition Time',
|
||||||
|
'耗电量':'Power Consumption',
|
||||||
|
'异常次数':'Exception Count',
|
||||||
|
'检测结果':'Detection Result',
|
||||||
|
'识别记录':'Recognition Record',
|
||||||
|
'工作记录':'Work Record',
|
||||||
|
'设备视图':'Device View',
|
||||||
|
'保养提醒':'Maintenance Reminder',
|
||||||
|
'花版名称':'Pattern Name',
|
||||||
|
'进度':'Progress',
|
||||||
|
'编码':'Code',
|
||||||
|
'保养内容':'Maintenance Content',
|
||||||
|
'图片名称':'Image Name',
|
||||||
|
'重新打开图片次数':'Reopen Image Count',
|
||||||
|
'裁片名称':'Cutting Name',
|
||||||
|
'总用时':'Total Time',
|
||||||
|
'修改次数':'Modify Count',
|
||||||
|
'检测结果占比':'Detection Result Ratio',
|
||||||
|
'检查结果':'Check Result',
|
||||||
|
'偏差值':'Deviation Value',
|
||||||
|
'检测时间':'Check Time',
|
||||||
|
'检测数量':'Check Count',
|
||||||
|
'报警内容':'Alarm Content',
|
||||||
|
'报警时间':'Alarm Time',
|
||||||
|
'总工作时长':'Total Working Time',
|
||||||
|
'总待机时长':'Total Standby Time',
|
||||||
|
'总停机时长':'Total Stop Time',
|
||||||
|
'总故障时长':'Total Fault Time',
|
||||||
|
'设备状态分析':'Device Status Analysis',
|
||||||
|
'总耗电量':'Total Power Consumption',
|
||||||
|
'产量统计':'Output Statistics'
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -486,5 +486,44 @@ export default {
|
|||||||
'异常停机分类统计':'异常停机分类统计',
|
'异常停机分类统计':'异常停机分类统计',
|
||||||
'次':'次',
|
'次':'次',
|
||||||
'报警':'报警',
|
'报警':'报警',
|
||||||
|
'扫描速度':'扫描速度',
|
||||||
|
'识别状态':'识别状态',
|
||||||
|
'扫描次数':'扫描次数',
|
||||||
|
'识别数量':'识别数量',
|
||||||
|
'总识别时长':'总识别时长',
|
||||||
|
'耗电量':'耗电量',
|
||||||
|
'异常次数':'异常次数',
|
||||||
|
'检测结果':'检测结果',
|
||||||
|
'识别记录':'识别记录',
|
||||||
|
'工作记录':'工作记录',
|
||||||
|
'设备视图':'设备视图',
|
||||||
|
'保养提醒':'保养提醒',
|
||||||
|
'花版名称':'花版名称',
|
||||||
|
'进度':'进度',
|
||||||
|
'编码':'编码',
|
||||||
|
'保养内容':'保养内容',
|
||||||
|
'图片名称':'图片名称',
|
||||||
|
'重新打开图片次数':'重新打开图片次数',
|
||||||
|
'裁片名称':'裁片名称',
|
||||||
|
'总用时':'总用时',
|
||||||
|
'修改次数':'修改次数',
|
||||||
|
'检测结果占比':'检测结果占比',
|
||||||
|
'检查结果':'检查结果',
|
||||||
|
'偏差值':'偏差值',
|
||||||
|
'检测时间':'检测时间',
|
||||||
|
'检测数量':'检测数量',
|
||||||
|
'报警内容':'报警内容',
|
||||||
|
'报警时间':'报警时间',
|
||||||
|
'总工作时长':'总工作时长',
|
||||||
|
'总待机时长':'总待机时长',
|
||||||
|
'总停机时长':'总停机时长',
|
||||||
|
'总故障时长':'总故障时长',
|
||||||
|
'设备状态分析':'设备状态分析',
|
||||||
|
'总耗电量':'总耗电量',
|
||||||
|
'产量统计':'产量统计'
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -61,9 +61,9 @@ let gridData = ref([
|
|||||||
function timeFrameChange(val) {
|
function timeFrameChange(val) {
|
||||||
timeFrame.value = val
|
timeFrame.value = val
|
||||||
if (val == 'd') {
|
if (val == 'd') {
|
||||||
router.push({ path: '/index' })
|
router.push({ path: '/index',query:route.query })
|
||||||
} else{
|
} else{
|
||||||
router.push({ path: '/history_'+val })
|
router.push({ path: '/history_'+val,query:route.query })
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="lc-container">
|
<div class="lc-container">
|
||||||
<div class="title">
|
<div class="title">
|
||||||
{{ tLang('common', '耗电量') }}
|
{{ tLang('message', '耗电量') }}
|
||||||
</div>
|
</div>
|
||||||
<div class="content">
|
<div class="content">
|
||||||
<div class="left">
|
<div class="left">
|
||||||
@ -18,7 +18,7 @@
|
|||||||
import { computed } from 'vue';
|
import { computed } from 'vue';
|
||||||
|
|
||||||
|
|
||||||
|
const {proxy} = getCurrentInstance();
|
||||||
const prop = defineProps({
|
const prop = defineProps({
|
||||||
totalElect: {
|
totalElect: {
|
||||||
type: Number,
|
type: Number,
|
||||||
@ -92,7 +92,7 @@ let left_option = computed(() => {
|
|||||||
data: [
|
data: [
|
||||||
{
|
{
|
||||||
value: prop.totalElect,
|
value: prop.totalElect,
|
||||||
name: '总耗电量'
|
name: proxy.tLang('message', '总耗电量')
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
@ -131,7 +131,7 @@ let line_option = computed(() => {
|
|||||||
// }
|
// }
|
||||||
// },
|
// },
|
||||||
grid: {
|
grid: {
|
||||||
left: '10%',
|
left: '15%',
|
||||||
bottom:'15%'
|
bottom:'15%'
|
||||||
},
|
},
|
||||||
xAxis: {
|
xAxis: {
|
||||||
@ -143,7 +143,7 @@ let line_option = computed(() => {
|
|||||||
},
|
},
|
||||||
yAxis: {
|
yAxis: {
|
||||||
type: 'value',
|
type: 'value',
|
||||||
name: '耗电量(kw·h)',
|
name: proxy.tLang('message','耗电量') + '(kw·h)',
|
||||||
splitLine: {
|
splitLine: {
|
||||||
show: true,
|
show: true,
|
||||||
lineStyle: {
|
lineStyle: {
|
||||||
@ -159,7 +159,7 @@ let line_option = computed(() => {
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
series: [{
|
series: [{
|
||||||
name: '耗电量',
|
name: proxy.tLang('message','耗电量'),
|
||||||
data: prop.lineData.series,
|
data: prop.lineData.series,
|
||||||
type: 'line',
|
type: 'line',
|
||||||
smooth: true,
|
smooth: true,
|
||||||
|
@ -3,6 +3,8 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
|
import { getCurrentInstance } from 'vue';
|
||||||
|
|
||||||
const prop = defineProps({
|
const prop = defineProps({
|
||||||
data: {
|
data: {
|
||||||
type: Object,
|
type: Object,
|
||||||
@ -15,6 +17,7 @@ const prop = defineProps({
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
const {proxy} = getCurrentInstance()
|
||||||
let line_option = computed(() => {
|
let line_option = computed(() => {
|
||||||
return {
|
return {
|
||||||
tooltip: {
|
tooltip: {
|
||||||
@ -59,7 +62,7 @@ let line_option = computed(() => {
|
|||||||
},
|
},
|
||||||
yAxis: {
|
yAxis: {
|
||||||
type: 'value',
|
type: 'value',
|
||||||
name: '产量',
|
name: proxy.tLang('home','产量'),
|
||||||
minInterval: 1,
|
minInterval: 1,
|
||||||
splitLine: {
|
splitLine: {
|
||||||
show: true,
|
show: true,
|
||||||
@ -76,7 +79,7 @@ let line_option = computed(() => {
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
series: [{
|
series: [{
|
||||||
name: '耗电量',
|
name: proxy.tLang('home','产量'),
|
||||||
data: prop.data.series,
|
data: prop.data.series,
|
||||||
type: 'line',
|
type: 'line',
|
||||||
smooth: true,
|
smooth: true,
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
<div class="left">
|
<div class="left">
|
||||||
<div class="lt box-bg-color">
|
<div class="lt box-bg-color">
|
||||||
<div class="title">
|
<div class="title">
|
||||||
{{ proxy.tLang('common', '设备状态分析') }}
|
{{ proxy.tLang('message', '设备状态分析') }}
|
||||||
</div>
|
</div>
|
||||||
<div class="content">
|
<div class="content">
|
||||||
<div class="status-list">
|
<div class="status-list">
|
||||||
@ -29,14 +29,14 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="right">
|
<div class="right">
|
||||||
<div class="rt box-bg-color">
|
<div class="rt box-bg-color">
|
||||||
<div class="title">{{ tLang('message', '维修记录') }}</div>
|
<div class="title">{{ tLang('menus', '维修记录') }}</div>
|
||||||
<div class="content">
|
<div class="content">
|
||||||
<BottomTable v-tableAutoScroll="{ delay: 15 }" :columns="repair_column" :tableData="repair_data">
|
<BottomTable v-tableAutoScroll="{ delay: 15 }" :columns="repair_column" :tableData="repair_data">
|
||||||
</BottomTable>
|
</BottomTable>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="rc box-bg-color">
|
<div class="rc box-bg-color">
|
||||||
<div class="title">{{ tLang('message', '保养记录') }}</div>
|
<div class="title">{{ tLang('pms', '保养记录') }}</div>
|
||||||
<div class="content">
|
<div class="content">
|
||||||
<BottomTable v-tableAutoScroll="{ delay: 15 }" :columns="remind_column" :tableData="remind_data">
|
<BottomTable v-tableAutoScroll="{ delay: 15 }" :columns="remind_column" :tableData="remind_data">
|
||||||
</BottomTable>
|
</BottomTable>
|
||||||
@ -53,7 +53,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
import { getCurrentInstance, onMounted, watch } from 'vue';
|
import { getCurrentInstance, onMounted, reactive, watch } from 'vue';
|
||||||
import { useRoute } from 'vue-router';
|
import { useRoute } from 'vue-router';
|
||||||
import StackBarChart from './components/stackBarChart.vue';
|
import StackBarChart from './components/stackBarChart.vue';
|
||||||
import Lcenter from './components/lcenter.vue';
|
import Lcenter from './components/lcenter.vue';
|
||||||
@ -69,7 +69,9 @@ let deviceStatusChartData = reactive({
|
|||||||
xAxis: [],
|
xAxis: [],
|
||||||
series: []
|
series: []
|
||||||
})
|
})
|
||||||
let devStorage = { "devCode": "3051502", "sn": "358284933" } //JSON.parse(localStorage.getItem('devStorage'))
|
|
||||||
|
|
||||||
|
let devStorage = reactive(JSON.parse(localStorage.getItem('devStorage')))
|
||||||
let codeList = {
|
let codeList = {
|
||||||
cp: '3051903',//裁片
|
cp: '3051903',//裁片
|
||||||
pb: '3051502',//平板扫描
|
pb: '3051502',//平板扫描
|
||||||
@ -77,18 +79,18 @@ let codeList = {
|
|||||||
fr: '334011' //缝纫
|
fr: '334011' //缝纫
|
||||||
}
|
}
|
||||||
let repair_column = [
|
let repair_column = [
|
||||||
{ prop: 'devCode', label: '编码', width: '60px' },
|
{ prop: 'devCode', label: proxy.tLang('message','编码'), width: '60px' },
|
||||||
{ prop: 'name', label: '设备名称', },
|
{ prop: 'name', label: proxy.tLang('device','设备名称'), },
|
||||||
{ prop: 'subject', label: '报警内容', },
|
{ prop: 'subject', label: proxy.tLang('message','报警内容'), },
|
||||||
{ prop: 'person', label: '负责人', width: '65px' },
|
{ prop: 'person', label: proxy.tLang('device','负责人'), width: '70px' },
|
||||||
{ prop: 'time', label: '报警时间', width: '80px' }
|
{ prop: 'time', label: proxy.tLang('message','报警时间'), width: '100px' }
|
||||||
]
|
]
|
||||||
let remind_column = [
|
let remind_column = [
|
||||||
{ prop: 'devCode', label: '编码', width: '60px' },
|
{ prop: 'devCode', label: proxy.tLang('message','编码'), width: '60px' },
|
||||||
{ prop: 'name', label: '设备名称', },
|
{ prop: 'name', label: proxy.tLang('device','设备名称'), },
|
||||||
{ prop: 'subject', label: '保养内容', },
|
{ prop: 'subject', label: proxy.tLang('message','保养内容'), },
|
||||||
{ prop: 'person', label: '负责人', width: '65px' },
|
{ prop: 'person', label: proxy.tLang('device','负责人'), width: '70px' },
|
||||||
{ prop: 'time', label: '保养时间', width: '80px' }
|
{ prop: 'time', label: proxy.tLang('pms','保养时间'), width: '100px' }
|
||||||
]
|
]
|
||||||
|
|
||||||
let tableTitle = ref('')
|
let tableTitle = ref('')
|
||||||
@ -102,10 +104,10 @@ let devTime = reactive({
|
|||||||
})
|
})
|
||||||
let infoList = computed(() => {
|
let infoList = computed(() => {
|
||||||
return [
|
return [
|
||||||
{ name: '总工作时长', value: devTime.workTime.toFixed(1) },
|
{ name: proxy.tLang('message','总工作时长'), value: devTime.workTime.toFixed(1) },
|
||||||
{ name: '总待机时长', value: devTime.waitTime.toFixed(1) },
|
{ name: proxy.tLang('message','总待机时长'), value: devTime.waitTime.toFixed(1) },
|
||||||
{ name: '总停机时长', value: devTime.stopTime.toFixed(1) },
|
{ name: proxy.tLang('message','总停机时长'), value: devTime.stopTime.toFixed(1) },
|
||||||
{ name: '总故障时长', value: devTime.faultTime.toFixed(1) },
|
{ name: proxy.tLang('message','总故障时长'), value: devTime.faultTime.toFixed(1) },
|
||||||
]
|
]
|
||||||
})
|
})
|
||||||
|
|
||||||
@ -192,19 +194,19 @@ const getDeviceStatusChart = async () => {
|
|||||||
deviceStatusChartData.xAxis = xAxis;
|
deviceStatusChartData.xAxis = xAxis;
|
||||||
deviceStatusChartData.series = []
|
deviceStatusChartData.series = []
|
||||||
deviceStatusChartData.series.push({
|
deviceStatusChartData.series.push({
|
||||||
name: proxy.tLang('common', '工作'),
|
name: proxy.tLang('home', '工作'),
|
||||||
data: series.work
|
data: series.work
|
||||||
})
|
})
|
||||||
deviceStatusChartData.series.push({
|
deviceStatusChartData.series.push({
|
||||||
name: proxy.tLang('common', '待机'),
|
name: proxy.tLang('home', '待机'),
|
||||||
data: series.wait
|
data: series.wait
|
||||||
})
|
})
|
||||||
// deviceStatusChartData.series.push({
|
// deviceStatusChartData.series.push({
|
||||||
// name: proxy.tLang('common', '停机'),
|
// name: proxy.tLang('home', '停机'),
|
||||||
// data: series.stop
|
// data: series.stop
|
||||||
// })
|
// })
|
||||||
deviceStatusChartData.series.push({
|
deviceStatusChartData.series.push({
|
||||||
name: proxy.tLang('common', '故障'),
|
name: proxy.tLang('message', '故障'),
|
||||||
data: series.fault
|
data: series.fault
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@ -214,11 +216,11 @@ let cpData = ref()
|
|||||||
function reqOKOrNGList() {
|
function reqOKOrNGList() {
|
||||||
getOKOrNGList({ devCode: devStorage.devCode, type: params.value }).then(res => {
|
getOKOrNGList({ devCode: devStorage.devCode, type: params.value }).then(res => {
|
||||||
columns.value = [
|
columns.value = [
|
||||||
{ prop: 'productCode', label: '产品编码' },
|
{ prop: 'productCode', label: proxy.tLang('product','产品编码'), width: '150px' },
|
||||||
{ prop: 'checkResult', label: '检查结果', slot: 'checkResult', width: '80px' },
|
{ prop: 'checkResult', label: proxy.tLang('message','检查结果'), slot: 'checkResult', width: '110px' },
|
||||||
{ prop: 'deviationValue', label: '偏差值' },
|
{ prop: 'deviationValue', label: proxy.tLang('message','偏差值') },
|
||||||
{ prop: 'ts', label: '检测时间' },
|
{ prop: 'ts', label: proxy.tLang('message','检测时间') },
|
||||||
{ prop: 'checkNum', label: '检测数量' },
|
{ prop: 'checkNum', label: proxy.tLang('message','检测数量') },
|
||||||
]
|
]
|
||||||
cpData.value = res.data
|
cpData.value = res.data
|
||||||
})
|
})
|
||||||
@ -229,10 +231,10 @@ function reqSewingList() {
|
|||||||
getSewingList({ devCode: devStorage.devCode, type: params.value }).then(res => {
|
getSewingList({ devCode: devStorage.devCode, type: params.value }).then(res => {
|
||||||
bottomData.value = res.data
|
bottomData.value = res.data
|
||||||
columns.value = [
|
columns.value = [
|
||||||
{ prop: 'fileName', label: '花样名称' },
|
{ prop: 'fileName', label: proxy.tLang('product','花样名称') },
|
||||||
{ prop: 'patternCount', label: '针数'},
|
{ prop: 'patternCount', label: proxy.tLang('product','针数')},
|
||||||
{ prop: 'workTime', label: '工作时长', slot: 'workTime' },
|
{ prop: 'workTime', label: proxy.tLang('device','工作时长'), slot: 'workTime' },
|
||||||
{ prop: 'total', label: '产量' },
|
{ prop: 'total', label: proxy.tLang('home','产量') },
|
||||||
]
|
]
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@ -242,12 +244,12 @@ function reqScanList() {
|
|||||||
getScanList({ devCode: devStorage.devCode, type: params.value }).then(res => {
|
getScanList({ devCode: devStorage.devCode, type: params.value }).then(res => {
|
||||||
bottomData.value = res.data
|
bottomData.value = res.data
|
||||||
columns.value = [
|
columns.value = [
|
||||||
{ prop: 'fileName', label: '图片名称' },
|
{ prop: 'fileName', label: proxy.tLang('message','图片名称') },
|
||||||
{ prop: 'repeatOpen', label: '重新打开图片次数'},
|
{ prop: 'repeatOpen', label: proxy.tLang('message','重新打开图片次数')},
|
||||||
{ prop: 'fileNameNew', label: '裁片名称'},
|
{ prop: 'fileNameNew', label: proxy.tLang('message','裁片名称')},
|
||||||
{ prop: 'cutNum', label: '识别数量'},
|
{ prop: 'cutNum', label: proxy.tLang('message','识别数量')},
|
||||||
{ prop: 'totalTime', label: '总用时', slot: 'totalTime' },
|
{ prop: 'totalTime', label: proxy.tLang('message','总用时'), slot: 'totalTime' },
|
||||||
{ prop: 'totalAlterNum', label: '修改次数' },
|
{ prop: 'totalAlterNum', label: proxy.tLang('message','修改次数') },
|
||||||
]
|
]
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@ -273,6 +275,11 @@ function init() {
|
|||||||
|
|
||||||
}
|
}
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
|
if (route.query.devCode) {
|
||||||
|
devStorage.devCode = route.query.devCode
|
||||||
|
} else {
|
||||||
|
devStorage.devCode = localStorage.getItem('devStorage') ? JSON.parse(localStorage.getItem('devStorage')).devCode : ""
|
||||||
|
}
|
||||||
init()
|
init()
|
||||||
})
|
})
|
||||||
</script>
|
</script>
|
||||||
|
@ -13,8 +13,11 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
|
import { getCurrentInstance } from 'vue'
|
||||||
|
|
||||||
|
|
||||||
let fileUrl = import.meta.env.VITE_APP_BASE_API
|
let fileUrl = import.meta.env.VITE_APP_BASE_API
|
||||||
|
const {proxy} = getCurrentInstance()
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
isRate: {
|
isRate: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
@ -34,8 +37,8 @@ const props = defineProps({
|
|||||||
|
|
||||||
let list = computed(() => {
|
let list = computed(() => {
|
||||||
return [
|
return [
|
||||||
{ name: '花版名称', value: props.data.fileName },
|
{ name: proxy.tLang('message','花版名称'), value: props.data.fileName },
|
||||||
{ name: '进度', value: props.data.schedule + '%' },
|
{ name: proxy.tLang('message','进度'), value: props.data.schedule + '%' },
|
||||||
]
|
]
|
||||||
})
|
})
|
||||||
</script>
|
</script>
|
||||||
|
@ -161,7 +161,7 @@ function ignoreError(item) {
|
|||||||
margin: 0 20px;
|
margin: 0 20px;
|
||||||
}
|
}
|
||||||
.text1 {
|
.text1 {
|
||||||
font-size: 18px;
|
font-size: 14px;
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: flex-start;
|
justify-content: flex-start;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
|
@ -77,6 +77,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
|
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
oeeData:{
|
oeeData:{
|
||||||
type: Object,
|
type: Object,
|
||||||
@ -126,9 +127,11 @@ let options = computed(() => {
|
|||||||
{
|
{
|
||||||
name: '',
|
name: '',
|
||||||
type: 'pie',
|
type: 'pie',
|
||||||
radius: ['40%', '70%'],
|
radius: ['40%', '65%'],
|
||||||
avoidLabelOverlap: false,
|
avoidLabelOverlap: true,
|
||||||
padAngle: 5,
|
padAngle: 5,
|
||||||
|
top:5,
|
||||||
|
Bottom:5,
|
||||||
itemStyle: {
|
itemStyle: {
|
||||||
borderRadius: 10
|
borderRadius: 10
|
||||||
},
|
},
|
||||||
@ -336,7 +339,7 @@ let oeeOption = computed(() => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.text1 {
|
.text1 {
|
||||||
font-size: 18px;
|
font-size: 14px;
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: flex-start;
|
justify-content: flex-start;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="rbottom-container">
|
<div class="rbottom-container">
|
||||||
<div class="title">{{ tLang('device', '检测结果占比') }}</div>
|
<div class="title">{{ tLang('message', '检测结果占比') }}</div>
|
||||||
<div class="content">
|
<div class="content">
|
||||||
<div class="chart">
|
<div class="chart">
|
||||||
<v-chart autoresize :option="options" theme="dark" style="width: 100%;height: 100%;" />
|
<v-chart autoresize :option="options" theme="dark" style="width: 100%;height: 100%;" />
|
||||||
|
@ -9,21 +9,24 @@
|
|||||||
<div class="lc">
|
<div class="lc">
|
||||||
<Lcenter1 v-if="devCode == codeList.cp || devCode == codeList.pb" :abnormalData="abnormalData"
|
<Lcenter1 v-if="devCode == codeList.cp || devCode == codeList.pb" :abnormalData="abnormalData"
|
||||||
:errorList="errorList" @ignoreError="ignoreError"></Lcenter1>
|
:errorList="errorList" @ignoreError="ignoreError"></Lcenter1>
|
||||||
<Lcenter2 v-else :oeeData="oeeData" :abnormalData="abnormalData" :errorList="errorList" @ignoreError="ignoreError"></Lcenter2>
|
<Lcenter2 v-else :oeeData="oeeData" :abnormalData="abnormalData" :errorList="errorList"
|
||||||
|
@ignoreError="ignoreError"></Lcenter2>
|
||||||
</div>
|
</div>
|
||||||
<div class="lb box-bg-color">
|
<div class="lb box-bg-color">
|
||||||
<bottomTable title="检测结果" v-if="devCode == codeList.cp" :columns="columns" :table-data="tableData">
|
<bottomTable :title="tLang('message', '检测结果')" v-if="devCode == codeList.cp" :columns="columns"
|
||||||
|
:table-data="tableData">
|
||||||
<template #checkResult="scope">
|
<template #checkResult="scope">
|
||||||
<span v-if="scope.row.checkResult == 'NG'" style="color: red">{{ scope.row.checkResult }}</span>
|
<span v-if="scope.row.checkResult == 'NG'" style="color: red">{{ scope.row.checkResult }}</span>
|
||||||
<span v-else style="color: #17C27B;">{{ scope.row.checkResult }}</span>
|
<span v-else style="color: #17C27B;">{{ scope.row.checkResult }}</span>
|
||||||
</template>
|
</template>
|
||||||
</bottomTable>
|
</bottomTable>
|
||||||
<bottomTable title="识别记录" v-else-if="devCode == codeList.pb" :columns="columns" :table-data="tableData">
|
<bottomTable :title="tLang('message', '识别记录')" v-else-if="devCode == codeList.pb" :columns="columns"
|
||||||
|
:table-data="tableData">
|
||||||
<template #totalTime="scope">
|
<template #totalTime="scope">
|
||||||
{{ (scope.row.totalTime / 60).toFixed(1) }} min
|
{{ (scope.row.totalTime / 60).toFixed(1) }} min
|
||||||
</template>
|
</template>
|
||||||
</bottomTable>
|
</bottomTable>
|
||||||
<bottomTable title="工作记录" v-else :columns="columns" :table-data="tableData">
|
<bottomTable :title="tLang('message', '工作记录')" v-else :columns="columns" :table-data="tableData">
|
||||||
<template #workTime="scope">
|
<template #workTime="scope">
|
||||||
{{ (scope.row.workTime / 60).toFixed(1) }} min
|
{{ (scope.row.workTime / 60).toFixed(1) }} min
|
||||||
</template>
|
</template>
|
||||||
@ -40,7 +43,8 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="rb box-bg-color">
|
<div class="rb box-bg-color">
|
||||||
<Rbottom1 v-if="devCode == codeList.cp" :data="reqOKOrNGCount"></Rbottom1>
|
<Rbottom1 v-if="devCode == codeList.cp" :data="reqOKOrNGCount"></Rbottom1>
|
||||||
<bottomTable v-else title="保养提醒" :columns="remind_column" :table-data="remind_data"></bottomTable>
|
<bottomTable v-else :title="tLang('message', '保养提醒')" :columns="remind_column" :table-data="remind_data">
|
||||||
|
</bottomTable>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -60,8 +64,10 @@ import Rbottom1 from './components/rbottom1.vue'
|
|||||||
import { connectWebsocket, closeWebsocket } from "@/utils/websocket";
|
import { connectWebsocket, closeWebsocket } from "@/utils/websocket";
|
||||||
import { device, deviceCheck, getOKOrNGList, abnormalShutdown, getSewingList, oee, getScanList } from '@/api/pms/device'
|
import { device, deviceCheck, getOKOrNGList, abnormalShutdown, getSewingList, oee, getScanList } from '@/api/pms/device'
|
||||||
import { computed, onUnmounted, reactive, ref } from 'vue'
|
import { computed, onUnmounted, reactive, ref } from 'vue'
|
||||||
|
import { useRoute } from 'vue-router'
|
||||||
|
|
||||||
let devCode = ref('3051502')
|
let devCode = ref('')
|
||||||
|
let route = useRoute()
|
||||||
let codeList = {
|
let codeList = {
|
||||||
cp: '3051903',//裁片
|
cp: '3051903',//裁片
|
||||||
pb: '3051502',//平板扫描
|
pb: '3051502',//平板扫描
|
||||||
@ -70,15 +76,15 @@ let codeList = {
|
|||||||
}
|
}
|
||||||
let is_rate = ref(false)
|
let is_rate = ref(false)
|
||||||
const columns = ref([])
|
const columns = ref([])
|
||||||
|
const { proxy } = getCurrentInstance()
|
||||||
|
|
||||||
|
|
||||||
let remind_column = [
|
let remind_column = [
|
||||||
{ prop: 'devCode', label: '编码', width: '60px' },
|
{ prop: 'devCode', label: proxy.tLang('message', '编码'), width: '60px' },
|
||||||
{ prop: 'name', label: '设备名称', },
|
{ prop: 'name', label: proxy.tLang('device', '设备名称'), },
|
||||||
{ prop: 'subject', label: '保养内容', },
|
{ prop: 'subject', label: proxy.tLang('message', '保养内容'), },
|
||||||
{ prop: 'person', label: '负责人', width: '60px' },
|
{ prop: 'person', label: proxy.tLang('device', '负责人'), width: '65px' },
|
||||||
{ prop: 'time', label: '保养时间', width: '75px' }
|
{ prop: 'time', label: proxy.tLang('pms', '保养时间'), width: '100px' }
|
||||||
]
|
]
|
||||||
let remind_data = ref()
|
let remind_data = ref()
|
||||||
let tableData = ref([
|
let tableData = ref([
|
||||||
@ -137,11 +143,11 @@ let reqOKOrNGCount = reactive({
|
|||||||
function reqOKOrNGList() {
|
function reqOKOrNGList() {
|
||||||
getOKOrNGList({ devCode: devCode.value, type: 'd' }).then(res => {
|
getOKOrNGList({ devCode: devCode.value, type: 'd' }).then(res => {
|
||||||
columns.value = [
|
columns.value = [
|
||||||
{ prop: 'productCode', label: '产品编码' },
|
{ prop: 'productCode', label: proxy.tLang('product', '产品编码'), width: '150px' },
|
||||||
{ prop: 'checkResult', label: '检查结果', slot: 'checkResult', width: '80px' },
|
{ prop: 'checkResult', label: proxy.tLang('message', '检查结果'), slot: 'checkResult', width: '110px' },
|
||||||
{ prop: 'deviationValue', label: '偏差值' },
|
{ prop: 'deviationValue', label: proxy.tLang('message', '偏差值') },
|
||||||
{ prop: 'ts', label: '检测时间' },
|
{ prop: 'ts', label: proxy.tLang('message', '检测时间') },
|
||||||
{ prop: 'checkNum', label: '检测数量' },
|
{ prop: 'checkNum', label: proxy.tLang('message', '检测数量') },
|
||||||
]
|
]
|
||||||
tableData.value = res.data.accessData
|
tableData.value = res.data.accessData
|
||||||
reqOKOrNGCount.ok = res.data.okNum
|
reqOKOrNGCount.ok = res.data.okNum
|
||||||
@ -155,10 +161,10 @@ function reqSewingList() {
|
|||||||
getSewingList({ devCode: devCode.value, type: 'd' }).then(res => {
|
getSewingList({ devCode: devCode.value, type: 'd' }).then(res => {
|
||||||
tableData.value = res.data
|
tableData.value = res.data
|
||||||
columns.value = [
|
columns.value = [
|
||||||
{ prop: 'fileName', label: '花样名称' },
|
{ prop: 'fileName', label: proxy.tLang('product', '花样名称') },
|
||||||
{ prop: 'patternCount', label: '针数'},
|
{ prop: 'patternCount', label: proxy.tLang('product', '针数') },
|
||||||
{ prop: 'workTime', label: '工作时长', slot: 'workTime' },
|
{ prop: 'workTime', label: proxy.tLang('device', '工作时长'), slot: 'workTime' },
|
||||||
{ prop: 'total', label: '产量' },
|
{ prop: 'total', label: proxy.tLang('home', '产量') },
|
||||||
]
|
]
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@ -167,12 +173,12 @@ function reqScanList() {
|
|||||||
getScanList({ devCode: devCode.value, type: 'd' }).then(res => {
|
getScanList({ devCode: devCode.value, type: 'd' }).then(res => {
|
||||||
tableData.value = res.data
|
tableData.value = res.data
|
||||||
columns.value = [
|
columns.value = [
|
||||||
{ prop: 'fileName', label: '图片名称' },
|
{ prop: 'fileName', label: proxy.tLang('message', '图片名称') },
|
||||||
{ prop: 'repeatOpen', label: '重新打开图片次数'},
|
{ prop: 'repeatOpen', label: proxy.tLang('message', '重新打开图片次数') },
|
||||||
{ prop: 'fileNameNew', label: '裁片名称'},
|
{ prop: 'fileNameNew', label: proxy.tLang('message', '裁片名称') },
|
||||||
{ prop: 'cutNum', label: '识别数量'},
|
{ prop: 'cutNum', label: proxy.tLang('message', '识别数量') },
|
||||||
{ prop: 'totalTime', label: '总用时', slot: 'totalTime' },
|
{ prop: 'totalTime', label: proxy.tLang('message', '总用时'), slot: 'totalTime' },
|
||||||
{ prop: 'totalAlterNum', label: '修改次数' },
|
{ prop: 'totalAlterNum', label: proxy.tLang('message', '修改次数') },
|
||||||
]
|
]
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@ -225,7 +231,7 @@ function getWebsocket(val) {
|
|||||||
try {
|
try {
|
||||||
let data = JSON.parse(val);
|
let data = JSON.parse(val);
|
||||||
|
|
||||||
if (data.type == "status" && data.msg.devCode == devCode.value) {
|
if (data.type == "status" && data.msg.devCode == devCode.value) {//设备状态更新
|
||||||
info.state = data.msg.status
|
info.state = data.msg.status
|
||||||
if (data.msg.status == 0) {
|
if (data.msg.status == 0) {
|
||||||
info.visionState = 0
|
info.visionState = 0
|
||||||
@ -284,7 +290,11 @@ function init() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
// devCode.value = localStorage.getItem('devStorage')?JSON.parse(localStorage.getItem('devStorage')).devCode:""
|
if (route.query.devCode) {
|
||||||
|
devCode.value = route.query.devCode
|
||||||
|
} else {
|
||||||
|
devCode.value = localStorage.getItem('devStorage') ? JSON.parse(localStorage.getItem('devStorage')).devCode : ""
|
||||||
|
}
|
||||||
|
|
||||||
init()
|
init()
|
||||||
if (devCode.value == '33202006') {
|
if (devCode.value == '33202006') {
|
||||||
|
Loading…
Reference in New Issue
Block a user