Compare commits
17 Commits
21f7542695
...
1c0dba7dbb
Author | SHA1 | Date | |
---|---|---|---|
1c0dba7dbb | |||
f844834453 | |||
a8531c95d6 | |||
|
b593bcee5a | ||
|
a750e565e2 | ||
d92d9fd594 | |||
17b4d5f812 | |||
|
d5a645e6f1 | ||
|
3823c3cb3e | ||
906b05ef51 | |||
|
bcadc83725 | ||
|
649be9a18b | ||
f9447912d9 | |||
|
95abfcf158 | ||
|
ba2aa7b1b8 | ||
4b29eede9d | |||
35bd7ab57e |
4
.env.dev
4
.env.dev
@ -1,7 +1,7 @@
|
|||||||
###
|
###
|
||||||
# @Author: Do not edit
|
# @Author: Do not edit
|
||||||
# @Date: 2023-08-29 09:40:39
|
# @Date: 2023-08-29 09:40:39
|
||||||
# @LastEditTime: 2024-03-22 14:18:33
|
# @LastEditTime: 2024-03-25 15:59:53
|
||||||
# @LastEditors: zhp
|
# @LastEditors: zhp
|
||||||
# @Description:
|
# @Description:
|
||||||
###
|
###
|
||||||
@ -25,7 +25,7 @@ VUE_APP_BASE_API = 'http://192.168.0.33:48082'
|
|||||||
# VUE_APP_BASE_API = 'http://192.168.1.78:48082'
|
# VUE_APP_BASE_API = 'http://192.168.1.78:48082'
|
||||||
# VUE_APP_BASE_API = 'http://192.168.1.47:48082'
|
# VUE_APP_BASE_API = 'http://192.168.1.47:48082'
|
||||||
# socket地址
|
# socket地址
|
||||||
VUE_APP_Socket_API = 'ws://192.168.0.33:48082'
|
VUE_APP_Socket_API = 'ws://10.70.2.2:8080'
|
||||||
VUE_APP_Socket_Dcs_API = 'ws://10.70.180.10:8081'
|
VUE_APP_Socket_Dcs_API = 'ws://10.70.180.10:8081'
|
||||||
|
|
||||||
# 积木报表指向地址
|
# 积木报表指向地址
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<!--
|
<!--
|
||||||
* @Author: zhp
|
* @Author: zhp
|
||||||
* @Date: 2024-01-29 16:50:26
|
* @Date: 2024-01-29 16:50:26
|
||||||
* @LastEditTime: 2024-03-13 09:07:37
|
* @LastEditTime: 2024-03-25 18:33:48
|
||||||
* @LastEditors: zhp
|
* @LastEditors: zhp
|
||||||
* @Description:
|
* @Description:
|
||||||
-->
|
-->
|
||||||
@ -793,11 +793,11 @@ export default {
|
|||||||
// formatDate(item.planStartTime) || '',
|
// formatDate(item.planStartTime) || '',
|
||||||
// `<span style="color:rgba(255,255,255,0.5)" >${item.line || ''}
|
// `<span style="color:rgba(255,255,255,0.5)" >${item.line || ''}
|
||||||
// </span>`,
|
// </span>`,
|
||||||
`<span style="color:rgba(255,255,255,0.5)">${item.name || ''}</span>`,
|
`<span style="color:rgba(255,255,255,0.5)">${ele.name || ''}</span>`,
|
||||||
// `<span style="color:rgba(255,255,255,0.5)">${item.code || ''}</span>`,
|
// `<span style="color:rgba(255,255,255,0.5)">${item.code || ''}</span>`,
|
||||||
`<span style="color:rgba(255,255,255,0.5)">${item.run || ''}</span>`,
|
`<span style="color:rgba(255,255,255,0.5)">${ele.run || ''}</span>`,
|
||||||
// `<span style="color:rgba(255,255,255,0.5)">${item.error || ''}</span>`,
|
// `<span style="color:rgba(255,255,255,0.5)">${item.error || ''}</span>`,
|
||||||
]);
|
])
|
||||||
}
|
}
|
||||||
this.realEqConfig.data = this.realEqList
|
this.realEqConfig.data = this.realEqList
|
||||||
this.$refs['realEqScrollBoard'].updateRows(this.realEqList)
|
this.$refs['realEqScrollBoard'].updateRows(this.realEqList)
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<!--
|
<!--
|
||||||
* @Author: zhp
|
* @Author: zhp
|
||||||
* @Date: 2023-09-21 09:06:28
|
* @Date: 2023-09-21 09:06:28
|
||||||
* @LastEditTime: 2024-01-29 15:39:59
|
* @LastEditTime: 2024-03-25 18:34:58
|
||||||
* @LastEditors: zhp
|
* @LastEditors: zhp
|
||||||
* @Description:
|
* @Description:
|
||||||
-->
|
-->
|
||||||
@ -158,7 +158,7 @@ export default {
|
|||||||
legend: {
|
legend: {
|
||||||
itemWidth: 10,
|
itemWidth: 10,
|
||||||
itemHeight: 10,
|
itemHeight: 10,
|
||||||
top: '1%',
|
top: '20',
|
||||||
// right: '20px',
|
// right: '20px',
|
||||||
data: ['产线产量', '产线良品率'],
|
data: ['产线产量', '产线良品率'],
|
||||||
textStyle: {
|
textStyle: {
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<div :id="id" :class="className" :style="{ height: height + 'px', width: width }" />
|
<div :id="id" :class="className" :style="{ height: '420px', width: width }" />
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@ -19,7 +19,7 @@ export default {
|
|||||||
},
|
},
|
||||||
className: {
|
className: {
|
||||||
type: String,
|
type: String,
|
||||||
default: 'chart'
|
default: 'enChart'
|
||||||
},
|
},
|
||||||
width: {
|
width: {
|
||||||
type: String,
|
type: String,
|
||||||
@ -84,7 +84,7 @@ export default {
|
|||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
initChart(nameList, dataList) {
|
initChart(nameList, dataList) {
|
||||||
console.log('1111', dataList);
|
// console.log('1111', dataList);
|
||||||
// console.log(1)
|
// console.log(1)
|
||||||
this.chart = echarts.init(document.getElementById(this.id))
|
this.chart = echarts.init(document.getElementById(this.id))
|
||||||
// if (dataList.length !== 0) {
|
// if (dataList.length !== 0) {
|
||||||
@ -123,13 +123,7 @@ export default {
|
|||||||
type: 'shadow' // 默认为直线,可选为:'line' | 'shadow'
|
type: 'shadow' // 默认为直线,可选为:'line' | 'shadow'
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
grid: {
|
grid: { top: 90, right: 60, bottom: 20, left: 90 },
|
||||||
top: 30,
|
|
||||||
left: '2%',
|
|
||||||
right: '2%',
|
|
||||||
bottom: '3%',
|
|
||||||
containLabel: true
|
|
||||||
},
|
|
||||||
// legend: {
|
// legend: {
|
||||||
// itemWidth: 10,
|
// itemWidth: 10,
|
||||||
// itemHeight: 10,
|
// itemHeight: 10,
|
||||||
@ -205,4 +199,11 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
<style>
|
||||||
|
.enChart {
|
||||||
|
position: absolute;
|
||||||
|
height: 100%;
|
||||||
|
width: 100%;
|
||||||
|
top: -30px;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<!--
|
<!--
|
||||||
* @Author: zhp
|
* @Author: zhp
|
||||||
* @Date: 2023-12-27 13:54:52
|
* @Date: 2023-12-27 13:54:52
|
||||||
* @LastEditTime: 2024-03-13 09:04:11
|
* @LastEditTime: 2024-03-25 18:37:26
|
||||||
* @LastEditors: zhp
|
* @LastEditors: zhp
|
||||||
* @Description:
|
* @Description:
|
||||||
-->
|
-->
|
||||||
@ -92,6 +92,8 @@ export default {
|
|||||||
methods: {
|
methods: {
|
||||||
initChart(nameList, topNameList, nameWasteList, passRateList, wasteList) {
|
initChart(nameList, topNameList, nameWasteList, passRateList, wasteList) {
|
||||||
let rawData = []
|
let rawData = []
|
||||||
|
let colors = ['#0fdedb', '#2359ec']
|
||||||
|
if (passRateList && wasteList) {
|
||||||
rawData.push(passRateList, wasteList)
|
rawData.push(passRateList, wasteList)
|
||||||
// console.log(1)
|
// console.log(1)
|
||||||
const totalData = [];
|
const totalData = [];
|
||||||
@ -102,8 +104,8 @@ export default {
|
|||||||
}
|
}
|
||||||
totalData.push(sum);
|
totalData.push(sum);
|
||||||
}
|
}
|
||||||
let colors = ['#0fdedb', '#2359ec' ]
|
|
||||||
console.log('total', totalData);
|
console.log('total', totalData);
|
||||||
|
}
|
||||||
this.chart = echarts.init(document.getElementById(this.id))
|
this.chart = echarts.init(document.getElementById(this.id))
|
||||||
const series = [
|
const series = [
|
||||||
'良品',
|
'良品',
|
||||||
@ -123,9 +125,9 @@ export default {
|
|||||||
formatter: (params) => Math.round(params.value * 1000) / 10 + '%'
|
formatter: (params) => Math.round(params.value * 1000) / 10 + '%'
|
||||||
},
|
},
|
||||||
color:colors[sid],
|
color:colors[sid],
|
||||||
data: rawData[sid].map((d, did) =>
|
data: rawData.length != 0 ? rawData[sid].map((d, did) =>
|
||||||
totalData[did] <= 0 ? 0 : d / totalData[did]
|
totalData[did] <= 0 ? 0 : d / totalData[did]
|
||||||
)
|
) : []
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
// let series = [
|
// let series = [
|
||||||
@ -172,6 +174,7 @@ export default {
|
|||||||
legend: {
|
legend: {
|
||||||
itemWidth: 12,
|
itemWidth: 12,
|
||||||
itemHeight: 12,
|
itemHeight: 12,
|
||||||
|
top:'10',
|
||||||
icon: 'rect',
|
icon: 'rect',
|
||||||
textStyle: {
|
textStyle: {
|
||||||
color: '#ffffff'
|
color: '#ffffff'
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* @Author: zwq
|
* @Author: zwq
|
||||||
* @Date: 2021-07-19 15:18:30
|
* @Date: 2021-07-19 15:18:30
|
||||||
* @LastEditors: zhp
|
* @LastEditors: zhp
|
||||||
* @LastEditTime: 2024-03-21 16:07:39
|
* @LastEditTime: 2024-03-25 16:54:49
|
||||||
* @Description:
|
* @Description:
|
||||||
-->
|
-->
|
||||||
<template>
|
<template>
|
||||||
@ -605,10 +605,7 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
// this.fetchList('exception-alarm')
|
this.getData()
|
||||||
// this.fetchList('inAndOutOfEachLine')
|
|
||||||
// this.fetchList('order-process')
|
|
||||||
// this.fetchList('line-chart-data')
|
|
||||||
this.init()
|
this.init()
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
window.location.reload()
|
window.location.reload()
|
||||||
@ -671,6 +668,22 @@ export default {
|
|||||||
// removeEventListener('resize', resizeFun)
|
// removeEventListener('resize', resizeFun)
|
||||||
// },
|
// },
|
||||||
methods: {
|
methods: {
|
||||||
|
getData() {
|
||||||
|
let processArr = qualityMonthList.map((item, index) => [
|
||||||
|
// console.log(item)
|
||||||
|
`<span style="color:rgba(255,255,255,0.5)" >${index + 1 || ''}
|
||||||
|
</span>`,
|
||||||
|
// formatDate(item.planStartTime) || '',
|
||||||
|
`
|
||||||
|
<span style="color:rgba(255,255,255,0.5)" >${item.productionLineName || ''}
|
||||||
|
</span>`,
|
||||||
|
`<span style="color:rgba(255,255,255,0.5)">${item.sectionName || ''}</span>`,
|
||||||
|
`<span style="color:rgba(255,255,255,0.5)">${item.count || ''}</span>`,
|
||||||
|
`<span style="color:rgba(255,255,255,0.5)">${item.inspectionTypeName || ''}</span>`,
|
||||||
|
])
|
||||||
|
this.processConfig.data = processArr
|
||||||
|
this.$refs['processScrollBoard'].updateRows(processArr)
|
||||||
|
},
|
||||||
// getList() {
|
// getList() {
|
||||||
// // this.$axios.get(
|
// // this.$axios.get(
|
||||||
// // 'base/core-production-line/listAll',
|
// // 'base/core-production-line/listAll',
|
||||||
@ -867,20 +880,6 @@ export default {
|
|||||||
// this.$nextTick(() => {
|
// this.$nextTick(() => {
|
||||||
this.$refs.productLineChart.initChart(nameList, passRateList, outputNumList)
|
this.$refs.productLineChart.initChart(nameList, passRateList, outputNumList)
|
||||||
} else if (this.SJGInitWebSocket === 'inspection') {
|
} else if (this.SJGInitWebSocket === 'inspection') {
|
||||||
let processArr = qualityMonthList.map((item, index) => [
|
|
||||||
// console.log(item)
|
|
||||||
`<span style="color:rgba(255,255,255,0.5)" >${index + 1 || ''}
|
|
||||||
</span>`,
|
|
||||||
// formatDate(item.planStartTime) || '',
|
|
||||||
`
|
|
||||||
<span style="color:rgba(255,255,255,0.5)" >${item.productionLineName || ''}
|
|
||||||
</span>`,
|
|
||||||
`<span style="color:rgba(255,255,255,0.5)">${item.sectionName || ''}</span>`,
|
|
||||||
`<span style="color:rgba(255,255,255,0.5)">${item.count || ''}</span>`,
|
|
||||||
`<span style="color:rgba(255,255,255,0.5)">${item.inspectionTypeName || ''}</span>`,
|
|
||||||
])
|
|
||||||
this.processConfig.data = processArr
|
|
||||||
this.$refs['processScrollBoard'].updateRows(processArr)
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
// 数据发送
|
// 数据发送
|
||||||
|
@ -79,10 +79,9 @@ const tableProps = [
|
|||||||
align: 'right',
|
align: 'right',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
prop: 'enabledTime',
|
prop: 'time',
|
||||||
label: '生效时间',
|
label: '生效时间',
|
||||||
filter: parseTime,
|
width: 235,
|
||||||
width: 150,
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
prop: 'remark',
|
prop: 'remark',
|
||||||
|
@ -2,42 +2,18 @@
|
|||||||
<div class="app-container">
|
<div class="app-container">
|
||||||
|
|
||||||
<!-- 搜索工作栏 -->
|
<!-- 搜索工作栏 -->
|
||||||
<search-bar
|
<search-bar :formConfigs="formConfig" ref="searchBarForm" @headBtnClick="buttonClick" />
|
||||||
:formConfigs="formConfig"
|
|
||||||
ref="searchBarForm"
|
|
||||||
@headBtnClick="buttonClick"
|
|
||||||
/>
|
|
||||||
<!-- 列表 -->
|
<!-- 列表 -->
|
||||||
<base-table
|
<base-table :page="queryParams.pageNo" :limit="queryParams.pageSize" :table-props="tableProps" :table-data="list"
|
||||||
:page="queryParams.pageNo"
|
:max-height="tableH">
|
||||||
:limit="queryParams.pageSize"
|
<method-btn v-if="tableBtn.length" slot="handleBtn" :width="80" label="操作" :method-list="tableBtn"
|
||||||
:table-props="tableProps"
|
@clickBtn="handleClick" />
|
||||||
:table-data="list"
|
|
||||||
:max-height="tableH"
|
|
||||||
>
|
|
||||||
<method-btn
|
|
||||||
v-if="tableBtn.length"
|
|
||||||
slot="handleBtn"
|
|
||||||
:width="80"
|
|
||||||
label="操作"
|
|
||||||
:method-list="tableBtn"
|
|
||||||
@clickBtn="handleClick"
|
|
||||||
/>
|
|
||||||
</base-table>
|
</base-table>
|
||||||
<pagination
|
<pagination :page.sync="queryParams.pageNo" :limit.sync="queryParams.pageSize" :total="total"
|
||||||
:page.sync="queryParams.pageNo"
|
@pagination="getList" />
|
||||||
:limit.sync="queryParams.pageSize"
|
|
||||||
:total="total"
|
|
||||||
@pagination="getList"
|
|
||||||
/>
|
|
||||||
<!-- 新增 -->
|
<!-- 新增 -->
|
||||||
<base-dialog
|
<base-dialog :dialogTitle="addOrEditTitle" :dialogVisible="centervisible" @cancel="handleCancel"
|
||||||
:dialogTitle="addOrEditTitle"
|
@confirm="handleConfirm" :before-close="handleCancel">
|
||||||
:dialogVisible="centervisible"
|
|
||||||
@cancel="handleCancel"
|
|
||||||
@confirm="handleConfirm"
|
|
||||||
:before-close="handleCancel"
|
|
||||||
>
|
|
||||||
<energy-plc-add ref="energyPlc" @successSubmit="successSubmit" />
|
<energy-plc-add ref="energyPlc" @successSubmit="successSubmit" />
|
||||||
</base-dialog>
|
</base-dialog>
|
||||||
</div>
|
</div>
|
||||||
@ -50,7 +26,8 @@ import EnergyPlcAdd from './components/energyPlcAdd.vue'
|
|||||||
const tableProps = [
|
const tableProps = [
|
||||||
{
|
{
|
||||||
prop: 'plcTableName',
|
prop: 'plcTableName',
|
||||||
label: '关联表名'
|
label: '关联表名',
|
||||||
|
showOverflowtooltip: true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
prop: 'code',
|
prop: 'code',
|
||||||
@ -60,7 +37,9 @@ const tableProps = [
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
prop: 'name',
|
prop: 'name',
|
||||||
label: '标识名'
|
label: '标识名',
|
||||||
|
minWidth: 150,
|
||||||
|
showOverflowtooltip: true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
prop: 'enName',
|
prop: 'enName',
|
||||||
|
@ -2,47 +2,23 @@
|
|||||||
<div class="app-container">
|
<div class="app-container">
|
||||||
|
|
||||||
<!-- 搜索工作栏 -->
|
<!-- 搜索工作栏 -->
|
||||||
<search-bar
|
<search-bar :formConfigs="formConfig" ref="searchBarForm" @headBtnClick="buttonClick" />
|
||||||
:formConfigs="formConfig"
|
|
||||||
ref="searchBarForm"
|
|
||||||
@headBtnClick="buttonClick"
|
|
||||||
/>
|
|
||||||
<!-- 列表 -->
|
<!-- 列表 -->
|
||||||
<base-table
|
<base-table :page="queryParams.pageNo" :limit="queryParams.pageSize" :table-props="tableProps" :table-data="list"
|
||||||
:page="queryParams.pageNo"
|
:max-height="tableH">
|
||||||
:limit="queryParams.pageSize"
|
<method-btn v-if="tableBtn.length" slot="handleBtn" :width="160" label="操作" :method-list="tableBtn"
|
||||||
:table-props="tableProps"
|
@clickBtn="handleClick" />
|
||||||
:table-data="list"
|
|
||||||
:max-height="tableH"
|
|
||||||
>
|
|
||||||
<method-btn
|
|
||||||
v-if="tableBtn.length"
|
|
||||||
slot="handleBtn"
|
|
||||||
:width="160"
|
|
||||||
label="操作"
|
|
||||||
:method-list="tableBtn"
|
|
||||||
@clickBtn="handleClick"
|
|
||||||
/>
|
|
||||||
</base-table>
|
</base-table>
|
||||||
<pagination
|
<pagination :page.sync="queryParams.pageNo" :limit.sync="queryParams.pageSize" :total="total"
|
||||||
:page.sync="queryParams.pageNo"
|
@pagination="getList" />
|
||||||
:limit.sync="queryParams.pageSize"
|
|
||||||
:total="total"
|
|
||||||
@pagination="getList"
|
|
||||||
/>
|
|
||||||
<!-- 新增 -->
|
<!-- 新增 -->
|
||||||
<base-dialog
|
<base-dialog :dialogTitle="addOrEditTitle" :dialogVisible="centervisible" @cancel="handleCancel"
|
||||||
:dialogTitle="addOrEditTitle"
|
@confirm="handleConfirm" :before-close="handleCancel" width='30%'>
|
||||||
:dialogVisible="centervisible"
|
|
||||||
@cancel="handleCancel"
|
|
||||||
@confirm="handleConfirm"
|
|
||||||
:before-close="handleCancel"
|
|
||||||
width='30%'
|
|
||||||
>
|
|
||||||
<energy-plc-connect-add ref="energyPlcConnect" :objList="objList" @successSubmit="successSubmit" />
|
<energy-plc-connect-add ref="energyPlcConnect" :objList="objList" @successSubmit="successSubmit" />
|
||||||
</base-dialog>
|
</base-dialog>
|
||||||
<!-- 参数绑定/查看 -->
|
<!-- 参数绑定/查看 -->
|
||||||
<energy-plc-param v-if="paramVisible" ref="plcParam" @closeDrawer="closeDrawer" :energyTypeList="energyTypeList"></energy-plc-param>
|
<energy-plc-param v-if="paramVisible" ref="plcParam" @closeDrawer="closeDrawer"
|
||||||
|
:energyTypeList="energyTypeList"></energy-plc-param>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@ -69,11 +45,14 @@ const tableProps = [
|
|||||||
{
|
{
|
||||||
prop: 'plcTableCode',
|
prop: 'plcTableCode',
|
||||||
label: '关联表编码',
|
label: '关联表编码',
|
||||||
|
minWidth: 150,
|
||||||
showOverflowtooltip: true
|
showOverflowtooltip: true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
prop: 'cnName',
|
prop: 'cnName',
|
||||||
label: '标识名'
|
label: '标识名',
|
||||||
|
minWidth: 150,
|
||||||
|
showOverflowtooltip: true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
prop: 'varNum',
|
prop: 'varNum',
|
||||||
|
@ -2,11 +2,11 @@
|
|||||||
* @Author: zwq
|
* @Author: zwq
|
||||||
* @Date: 2021-11-18 14:16:25
|
* @Date: 2021-11-18 14:16:25
|
||||||
* @LastEditors: zhp
|
* @LastEditors: zhp
|
||||||
* @LastEditTime: 2024-03-20 09:18:30
|
* @LastEditTime: 2024-03-22 17:11:55
|
||||||
* @Description:
|
* @Description:
|
||||||
-->
|
-->
|
||||||
<template>
|
<template>
|
||||||
<el-drawer :visible.sync="visible" :show-close="false" :wrapper-closable="false" class="drawer" size="50%">
|
<el-drawer :visible.sync="visible" :show-close="false" :wrapper-closable="true" class="drawer" size="50%">
|
||||||
<small-title slot="title" :no-padding="true">
|
<small-title slot="title" :no-padding="true">
|
||||||
{{ isdetail ? '详情' : !dataForm.id ? '新增' : '编辑' }}
|
{{ isdetail ? '详情' : !dataForm.id ? '新增' : '编辑' }}
|
||||||
</small-title>
|
</small-title>
|
||||||
@ -75,7 +75,7 @@
|
|||||||
:limit.sync="listQuery.pageSize" :page-sizes="[5, 10, 15]" @pagination="getList" />
|
:limit.sync="listQuery.pageSize" :page-sizes="[5, 10, 15]" @pagination="getList" />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="drawer-body__footer">
|
<div v-if="!isdetail" class="drawer-body__footer">
|
||||||
<el-button style="" @click="goback()">取消</el-button>
|
<el-button style="" @click="goback()">取消</el-button>
|
||||||
<el-button type="primary" @click="dataFormSubmit()">确定</el-button>
|
<el-button type="primary" @click="dataFormSubmit()">确定</el-button>
|
||||||
</div>
|
</div>
|
||||||
@ -198,7 +198,7 @@ export default {
|
|||||||
}
|
}
|
||||||
// 修改的提交
|
// 修改的提交
|
||||||
if (this.dataForm.id) {
|
if (this.dataForm.id) {
|
||||||
this.urlOptions.updateURL(this.dataForm).then(response => {
|
this.urlOptions.updateURL(this.dataForm).then(res => {
|
||||||
this.$modal.msgSuccess("修改成功");
|
this.$modal.msgSuccess("修改成功");
|
||||||
this.visible = false;
|
this.visible = false;
|
||||||
this.$emit("refreshDataList");
|
this.$emit("refreshDataList");
|
||||||
@ -206,7 +206,7 @@ export default {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
// 添加的提交
|
// 添加的提交
|
||||||
this.urlOptions.createURL(this.dataForm).then(response => {
|
this.urlOptions.createURL(this.dataForm).then(res => {
|
||||||
this.$modal.msgSuccess("新增成功");
|
this.$modal.msgSuccess("新增成功");
|
||||||
this.idAttrShow = true;
|
this.idAttrShow = true;
|
||||||
this.dataForm.id = res.data
|
this.dataForm.id = res.data
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* @Author: zwq
|
* @Author: zwq
|
||||||
* @Date: 2021-11-18 14:16:25
|
* @Date: 2021-11-18 14:16:25
|
||||||
* @LastEditors: zhp
|
* @LastEditors: zhp
|
||||||
* @LastEditTime: 2024-03-22 09:01:30
|
* @LastEditTime: 2024-03-25 14:07:31
|
||||||
* @Description:
|
* @Description:
|
||||||
-->
|
-->
|
||||||
<template>
|
<template>
|
||||||
@ -289,7 +289,7 @@ export default {
|
|||||||
}
|
}
|
||||||
// 修改的提交
|
// 修改的提交
|
||||||
if (this.dataForm.id) {
|
if (this.dataForm.id) {
|
||||||
this.urlOptions.updateURL(this.dataForm).then(response => {
|
this.urlOptions.updateURL(this.dataForm).then(res => {
|
||||||
this.$modal.msgSuccess("修改成功");
|
this.$modal.msgSuccess("修改成功");
|
||||||
this.visible = false;
|
this.visible = false;
|
||||||
this.$emit("refreshDataList");
|
this.$emit("refreshDataList");
|
||||||
@ -297,7 +297,7 @@ export default {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
// 添加的提交
|
// 添加的提交
|
||||||
this.urlOptions.createURL(this.dataForm).then(response => {
|
this.urlOptions.createURL(this.dataForm).then(res => {
|
||||||
this.$modal.msgSuccess("新增成功");
|
this.$modal.msgSuccess("新增成功");
|
||||||
this.idAttrShow = true;
|
this.idAttrShow = true;
|
||||||
this.dataForm.id = res.data
|
this.dataForm.id = res.data
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<!--
|
<!--
|
||||||
* @Author: zhp
|
* @Author: zhp
|
||||||
* @Date: 2023-11-08 15:30:27
|
* @Date: 2023-11-08 15:30:27
|
||||||
* @LastEditTime: 2023-12-04 15:19:33
|
* @LastEditTime: 2024-03-25 14:14:04
|
||||||
* @LastEditors: zhp
|
* @LastEditors: zhp
|
||||||
* @Description:
|
* @Description:
|
||||||
-->
|
-->
|
||||||
@ -118,7 +118,7 @@ export default {
|
|||||||
this.$refs['dataForm'].resetFields();
|
this.$refs['dataForm'].resetFields();
|
||||||
if (this.dataForm.id) {
|
if (this.dataForm.id) {
|
||||||
getProcessEquValueBomDet({
|
getProcessEquValueBomDet({
|
||||||
id: this.dataForm.id
|
id: this.dataForm.id,
|
||||||
}).then((res) => {
|
}).then((res) => {
|
||||||
this.dataForm = res.data;
|
this.dataForm = res.data;
|
||||||
const arr = []
|
const arr = []
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<!--
|
<!--
|
||||||
* @Author: zhp
|
* @Author: zhp
|
||||||
* @Date: 2023-11-08 14:00:52
|
* @Date: 2023-11-08 14:00:52
|
||||||
* @LastEditTime: 2023-11-09 09:59:53
|
* @LastEditTime: 2024-03-25 14:09:33
|
||||||
* @LastEditors: zhp
|
* @LastEditors: zhp
|
||||||
* @Description:
|
* @Description:
|
||||||
-->
|
-->
|
||||||
@ -25,24 +25,24 @@ export default {
|
|||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
state: false
|
// state: false
|
||||||
|
}
|
||||||
|
},
|
||||||
|
computed: {
|
||||||
|
state() {
|
||||||
|
return this.injectData.enabled === 1 ? true : false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
// computed: {
|
|
||||||
// readonly() {
|
|
||||||
// return !!this.injectData.readonly
|
|
||||||
// }
|
|
||||||
// },
|
|
||||||
mounted() {
|
mounted() {
|
||||||
this.mapToState()
|
// this.mapToState()
|
||||||
},
|
},
|
||||||
|
|
||||||
methods: {
|
methods: {
|
||||||
mapToState() {
|
// mapToState() {
|
||||||
if (this.injectData.prop === 'enabled') {
|
// if (this.injectData.prop === 'enabled') {
|
||||||
this.state = this.injectData.enabled === 1 ? true : false
|
// this.state = this.injectData.enabled === 1 ? true : false
|
||||||
}
|
// }
|
||||||
},
|
// },
|
||||||
changeHandler() {
|
changeHandler() {
|
||||||
// let params = {}
|
// let params = {}
|
||||||
let payload = {}
|
let payload = {}
|
||||||
|
@ -2,43 +2,18 @@
|
|||||||
<div class="app-container">
|
<div class="app-container">
|
||||||
|
|
||||||
<!-- 搜索工作栏 -->
|
<!-- 搜索工作栏 -->
|
||||||
<search-bar
|
<search-bar :formConfigs="formConfig" ref="searchBarForm" @headBtnClick="buttonClick" />
|
||||||
:formConfigs="formConfig"
|
|
||||||
ref="searchBarForm"
|
|
||||||
@headBtnClick="buttonClick"
|
|
||||||
/>
|
|
||||||
<!-- 列表 -->
|
<!-- 列表 -->
|
||||||
<base-table
|
<base-table :page="queryParams.pageNo" :limit="queryParams.pageSize" :table-props="tableProps" :table-data="list"
|
||||||
:page="queryParams.pageNo"
|
:max-height="tableH">
|
||||||
:limit="queryParams.pageSize"
|
<method-btn v-if="tableBtn.length" slot="handleBtn" :width="120" label="操作" :method-list="tableBtn"
|
||||||
:table-props="tableProps"
|
@clickBtn="handleClick" />
|
||||||
:table-data="list"
|
|
||||||
:max-height="tableH"
|
|
||||||
>
|
|
||||||
<method-btn
|
|
||||||
v-if="tableBtn.length"
|
|
||||||
slot="handleBtn"
|
|
||||||
:width="120"
|
|
||||||
label="操作"
|
|
||||||
:method-list="tableBtn"
|
|
||||||
@clickBtn="handleClick"
|
|
||||||
/>
|
|
||||||
</base-table>
|
</base-table>
|
||||||
<pagination
|
<pagination :page.sync="queryParams.pageNo" :limit.sync="queryParams.pageSize" :total="total"
|
||||||
:page.sync="queryParams.pageNo"
|
@pagination="getList" />
|
||||||
:limit.sync="queryParams.pageSize"
|
|
||||||
:total="total"
|
|
||||||
@pagination="getList"
|
|
||||||
/>
|
|
||||||
<!-- 新增 -->
|
<!-- 新增 -->
|
||||||
<base-dialog
|
<base-dialog :dialogTitle="addOrEditTitle" :dialogVisible="centervisible" @cancel="handleCancel"
|
||||||
:dialogTitle="addOrEditTitle"
|
@confirm="handleConfirm" :before-close="handleCancel" width='50%'>
|
||||||
:dialogVisible="centervisible"
|
|
||||||
@cancel="handleCancel"
|
|
||||||
@confirm="handleConfirm"
|
|
||||||
:before-close="handleCancel"
|
|
||||||
width='50%'
|
|
||||||
>
|
|
||||||
<group-class-add ref="classList" @successSubmit="successSubmit" />
|
<group-class-add ref="classList" @successSubmit="successSubmit" />
|
||||||
</base-dialog>
|
</base-dialog>
|
||||||
</div>
|
</div>
|
||||||
@ -85,7 +60,7 @@ const tableProps = [
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
export default {
|
export default {
|
||||||
name: "GroupClass",
|
name: "GroupClasses",
|
||||||
components: { GroupClassAdd },
|
components: { GroupClassAdd },
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
@ -299,14 +299,14 @@ export default {
|
|||||||
getCookie() {
|
getCookie() {
|
||||||
// const username = getUsername();
|
// const username = getUsername();
|
||||||
// const password = getPassword();
|
// const password = getPassword();
|
||||||
// const rememberMe = getRememberMe();
|
const rememberMe = getRememberMe()
|
||||||
const tenantName = getTenantName();
|
// const tenantName = getTenantName();
|
||||||
this.loginForm = {
|
this.loginForm = {
|
||||||
...this.loginForm,
|
...this.loginForm,
|
||||||
username: username ? username : this.loginForm.username,
|
username: this.loginForm.username,
|
||||||
password: password ? password : this.loginForm.password,
|
password: this.loginForm.password,
|
||||||
rememberMe: rememberMe ? getRememberMe() : false,
|
rememberMe: rememberMe ? getRememberMe() : false,
|
||||||
tenantName: tenantName ? tenantName : this.loginForm.tenantName,
|
tenantName: this.loginForm.tenantName,
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
handleLogin(captchaParams) {
|
handleLogin(captchaParams) {
|
||||||
|
@ -21,7 +21,7 @@
|
|||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span='4'>
|
<el-col :span='4'>
|
||||||
<div class="blodTip">产品名称</div>
|
<div class="blodTip">产品名称</div>
|
||||||
<div class="lightTip">{{ orderMsg.productName }}</div>
|
<div class="lightTip" :title='orderMsg.productName'>{{ orderMsg.productName }}</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span='4'>
|
<el-col :span='4'>
|
||||||
<div class="blodTip">产品规格</div>
|
<div class="blodTip">产品规格</div>
|
||||||
@ -282,6 +282,9 @@ export default {
|
|||||||
font-weight: 400;
|
font-weight: 400;
|
||||||
color: rgba(102, 102, 102, 0.75);
|
color: rgba(102, 102, 102, 0.75);
|
||||||
margin-bottom: 12px;
|
margin-bottom: 12px;
|
||||||
|
white-space: nowrap;
|
||||||
|
overflow: hidden;
|
||||||
|
text-overflow: ellipsis;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,34 +1,17 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="app-container orderMonitoring">
|
<div class="app-container orderMonitoring">
|
||||||
<!-- 搜索工作栏 -->
|
<!-- 搜索工作栏 -->
|
||||||
<search-bar
|
<search-bar :formConfigs="formConfig" ref="searchBarForm" @headBtnClick="buttonClick" />
|
||||||
:formConfigs="formConfig"
|
|
||||||
ref="searchBarForm"
|
|
||||||
@headBtnClick="buttonClick"
|
|
||||||
/>
|
|
||||||
<el-tabs v-model="activeName" @tab-click="toggleTab">
|
<el-tabs v-model="activeName" @tab-click="toggleTab">
|
||||||
<el-tab-pane label="数据列表" name="dataList"></el-tab-pane>
|
<el-tab-pane label="数据列表" name="dataList"></el-tab-pane>
|
||||||
<el-tab-pane label="环形图" name="barChart"></el-tab-pane>
|
<el-tab-pane label="环形图" name="barChart"></el-tab-pane>
|
||||||
</el-tabs>
|
</el-tabs>
|
||||||
<!-- 表 -->
|
<!-- 表 -->
|
||||||
<div v-if="activeName === 'dataList'">
|
<div v-if="activeName === 'dataList'">
|
||||||
<base-table
|
<base-table :page="1" :limit="1000000000000" :table-props="tableProps" :table-data="list" :max-height="tableH"
|
||||||
:page="1"
|
row-key="id" :tree-props="{ children: 'orderMonitorVOS', hasChildren: 'hasChildren' }">
|
||||||
:limit="1000000000000"
|
<method-btn v-if="tableBtn.length" slot="handleBtn" :width="100" label="操作" :method-list="tableBtn"
|
||||||
:table-props="tableProps"
|
@clickBtn="handleClick" />
|
||||||
:table-data="list"
|
|
||||||
:max-height="tableH"
|
|
||||||
row-key="id"
|
|
||||||
:tree-props="{children: 'orderMonitorVOS', hasChildren: 'hasChildren'}"
|
|
||||||
>
|
|
||||||
<method-btn
|
|
||||||
v-if="tableBtn.length"
|
|
||||||
slot="handleBtn"
|
|
||||||
:width="100"
|
|
||||||
label="操作"
|
|
||||||
:method-list="tableBtn"
|
|
||||||
@clickBtn="handleClick"
|
|
||||||
/>
|
|
||||||
</base-table>
|
</base-table>
|
||||||
</div>
|
</div>
|
||||||
<!-- 图 -->
|
<!-- 图 -->
|
||||||
@ -168,7 +151,7 @@ export default {
|
|||||||
},
|
},
|
||||||
tableProps,
|
tableProps,
|
||||||
list: [],
|
list: [],
|
||||||
tableH: this.tableHeight(305),
|
tableH: this.tableHeight(260),
|
||||||
total: 0,
|
total: 0,
|
||||||
tableBtn: [
|
tableBtn: [
|
||||||
this.$auth.hasPermi('base:order-completion-monitoring:orderDet')
|
this.$auth.hasPermi('base:order-completion-monitoring:orderDet')
|
||||||
@ -234,7 +217,7 @@ export default {
|
|||||||
components: { MonitoringRingCharts },
|
components: { MonitoringRingCharts },
|
||||||
mounted() {
|
mounted() {
|
||||||
window.addEventListener('resize', () => {
|
window.addEventListener('resize', () => {
|
||||||
this.tableH = this.tableHeight(305)
|
this.tableH = this.tableHeight(260)
|
||||||
})
|
})
|
||||||
let start = moment().subtract(30, 'days').format('yyyy-MM-DD')
|
let start = moment().subtract(30, 'days').format('yyyy-MM-DD')
|
||||||
let end = moment().format('yyyy-MM-DD')
|
let end = moment().format('yyyy-MM-DD')
|
||||||
@ -360,24 +343,31 @@ export default {
|
|||||||
height: 2px;
|
height: 2px;
|
||||||
background-color: #e4e7ed;
|
background-color: #e4e7ed;
|
||||||
}
|
}
|
||||||
|
|
||||||
.el-tabs__nav-wrap::after {
|
.el-tabs__nav-wrap::after {
|
||||||
width: 0;
|
width: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.el-tabs__item {
|
.el-tabs__item {
|
||||||
padding: 0 10px;
|
padding: 0 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.el-tabs__item:hover {
|
.el-tabs__item:hover {
|
||||||
color: rgba(0, 0, 0, 0.85);
|
color: rgba(0, 0, 0, 0.85);
|
||||||
}
|
}
|
||||||
|
|
||||||
.el-tabs__item.is-active {
|
.el-tabs__item.is-active {
|
||||||
color: rgba(0, 0, 0, 0.85);
|
color: rgba(0, 0, 0, 0.85);
|
||||||
}
|
}
|
||||||
|
|
||||||
.el-tabs__item {
|
.el-tabs__item {
|
||||||
color: rgba(0, 0, 0, 0.45);
|
color: rgba(0, 0, 0, 0.45);
|
||||||
}
|
}
|
||||||
|
|
||||||
.searchBarBox {
|
.searchBarBox {
|
||||||
margin-bottom: 0;
|
margin-bottom: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.boxTitle {
|
.boxTitle {
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
font-size: 16px;
|
font-size: 16px;
|
||||||
@ -385,6 +375,7 @@ export default {
|
|||||||
color: #000000;
|
color: #000000;
|
||||||
margin: 0 10px 16px 0;
|
margin: 0 10px 16px 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.blueTitle {
|
.blueTitle {
|
||||||
content: '';
|
content: '';
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<!--
|
<!--
|
||||||
* @Author: zhp
|
* @Author: zhp
|
||||||
* @Date: 2023-12-08 13:46:17
|
* @Date: 2023-12-08 13:46:17
|
||||||
* @LastEditTime: 2024-03-21 10:40:52
|
* @LastEditTime: 2024-03-25 08:50:25
|
||||||
* @LastEditors: zhp
|
* @LastEditors: zhp
|
||||||
* @Description:
|
* @Description:
|
||||||
-->
|
-->
|
||||||
@ -73,12 +73,12 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-row>
|
</el-row>
|
||||||
<el-row :gutter="24" v-for="(item,index) in ingredientList" :key="item.id">
|
<el-row :gutter="24" v-for="(item,index) in ingredientList" :key="item.id">
|
||||||
<el-col :span="8">
|
<el-col :span="6">
|
||||||
<el-form-item label="成分">
|
<el-form-item label="成分">
|
||||||
{{ item.name }}
|
{{ item.name }}
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="8">
|
<el-col :span="6">
|
||||||
<el-form-item :prop="'checkValueList.' + index + '.checkValue'" label="成分含量"
|
<el-form-item :prop="'checkValueList.' + index + '.checkValue'" label="成分含量"
|
||||||
:rules="[{ required: true, message: '成分含量不能为空', trigger: 'blur' }]">
|
:rules="[{ required: true, message: '成分含量不能为空', trigger: 'blur' }]">
|
||||||
<el-input oninput="value=value.replace(/[^\d]/g,'')" :disabled="isdetail"
|
<el-input oninput="value=value.replace(/[^\d]/g,'')" :disabled="isdetail"
|
||||||
@ -92,12 +92,12 @@
|
|||||||
</span>
|
</span>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="4">
|
<el-col :span="6">
|
||||||
<el-form-item :prop="'checkValueList.' + index + '.minValue'" label="最小值">
|
<el-form-item :prop="'checkValueList.' + index + '.minValue'" label="最小值">
|
||||||
<el-input disabled style="width: 90%;margin-right: 10px;" v-model="item.minValue"></el-input>
|
<el-input disabled style="width: 90%;margin-right: 10px;" v-model="item.minValue"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="4">
|
<el-col :span="6">
|
||||||
<el-form-item :prop="'checkValueList.' + index + '.minValue'" label="最大值">
|
<el-form-item :prop="'checkValueList.' + index + '.minValue'" label="最大值">
|
||||||
<el-input disabled style="width: 90%;margin-right: 10px;" v-model="item.maxValue"></el-input>
|
<el-input disabled style="width: 90%;margin-right: 10px;" v-model="item.maxValue"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<!--
|
<!--
|
||||||
* @Author: zhp
|
* @Author: zhp
|
||||||
* @Date: 2023-11-06 15:15:30
|
* @Date: 2023-11-06 15:15:30
|
||||||
* @LastEditTime: 2024-03-20 09:38:10
|
* @LastEditTime: 2024-03-22 17:13:16
|
||||||
* @LastEditors: zhp
|
* @LastEditors: zhp
|
||||||
* @Description:
|
* @Description:
|
||||||
-->
|
-->
|
||||||
@ -10,7 +10,7 @@
|
|||||||
<el-row :gutter="20">
|
<el-row :gutter="20">
|
||||||
<el-col :span="8">
|
<el-col :span="8">
|
||||||
<el-form-item label="工单号" prop="workOrderId">
|
<el-form-item label="工单号" prop="workOrderId">
|
||||||
<el-select v-model="dataForm.workOrderId" placeholder="请选择工单号">
|
<el-select filterable v-model="dataForm.workOrderId" placeholder="请选择工单号">
|
||||||
<el-option v-for="dict in workOrderList" :key="dict.id" :label="dict.name" :value="dict.id" />
|
<el-option v-for="dict in workOrderList" :key="dict.id" :label="dict.name" :value="dict.id" />
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
@ -58,6 +58,13 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
|
<el-col :span="8">
|
||||||
|
<el-form-item label="来源" prop="source">
|
||||||
|
<el-select v-model="dataForm.source" placeholder="请选择来源" multiple>
|
||||||
|
<el-option v-for="dict in sourceList" :key="dict.id" :label="dict.name" :value="dict.id" />
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
<el-col :span="8">
|
<el-col :span="8">
|
||||||
<el-form-item label="备注" prop="remark">
|
<el-form-item label="备注" prop="remark">
|
||||||
<el-input v-model="dataForm.remark" placeholder="备注" />
|
<el-input v-model="dataForm.remark" placeholder="备注" />
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* @Author: zwq
|
* @Author: zwq
|
||||||
* @Date: 2023-08-01 14:55:51
|
* @Date: 2023-08-01 14:55:51
|
||||||
* @LastEditors: zhp
|
* @LastEditors: zhp
|
||||||
* @LastEditTime: 2024-03-21 15:14:04
|
* @LastEditTime: 2024-03-25 16:07:07
|
||||||
* @Description:
|
* @Description:
|
||||||
-->
|
-->
|
||||||
<template>
|
<template>
|
||||||
@ -64,7 +64,7 @@ const tableProps = [
|
|||||||
{
|
{
|
||||||
prop: 'source',
|
prop: 'source',
|
||||||
label: '数据来源',
|
label: '数据来源',
|
||||||
filter: (val) => val == 1 ? '内部' : '外部'
|
filter: (val) => val == 1 ? '手动' : '自动'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
prop: 'remark',
|
prop: 'remark',
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<!--
|
<!--
|
||||||
* @Author: zhp
|
* @Author: zhp
|
||||||
* @Date: 2024-01-24 15:15:24
|
* @Date: 2024-01-24 15:15:24
|
||||||
* @LastEditTime: 2024-03-22 10:14:23
|
* @LastEditTime: 2024-03-22 17:05:51
|
||||||
* @LastEditors: zhp
|
* @LastEditors: zhp
|
||||||
* @Description:
|
* @Description:
|
||||||
-->
|
-->
|
||||||
@ -66,7 +66,7 @@ export default {
|
|||||||
};
|
};
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
this.getDict()
|
// this.getDict()
|
||||||
this.getTodayStartTimeAndEndTime()
|
this.getTodayStartTimeAndEndTime()
|
||||||
this.getDataList()
|
this.getDataList()
|
||||||
},
|
},
|
||||||
@ -104,6 +104,8 @@ export default {
|
|||||||
|
|
||||||
},
|
},
|
||||||
async getDataList() {
|
async getDataList() {
|
||||||
|
const res = await getCorePLList()
|
||||||
|
this.proLineList = res.data;
|
||||||
this.dataListLoading = true
|
this.dataListLoading = true
|
||||||
if (this.listQuery.reportTime.length == 0) {
|
if (this.listQuery.reportTime.length == 0) {
|
||||||
this.$message({
|
this.$message({
|
||||||
@ -135,9 +137,9 @@ export default {
|
|||||||
// item.dailyOutputTrend = null
|
// item.dailyOutputTrend = null
|
||||||
// }
|
// }
|
||||||
item.dailyOutputTrend = item.dailyOutputTrend && item.dailyOutputTrend != 0 ? this.multipliedByHundred(item.dailyOutputTrend) + '%' : item.dailyOutputTrend == 0 ? 0 : null
|
item.dailyOutputTrend = item.dailyOutputTrend && item.dailyOutputTrend != 0 ? this.multipliedByHundred(item.dailyOutputTrend) + '%' : item.dailyOutputTrend == 0 ? 0 : null
|
||||||
item.originalGlassStatisticsTrend = item.dailyOutputTrend && item.originalGlassStatisticsTrend != 0 ? this.multipliedByHundred(item.originalGlassStatisticsTrend) + '%' : item.originalGlassStatisticsTrend == 0 ? 0 : null
|
item.originalGlassStatisticsTrend = item.originalGlassStatisticsTrend && item.originalGlassStatisticsTrend != 0 ? this.multipliedByHundred(item.originalGlassStatisticsTrend) + '%' : item.originalGlassStatisticsTrend == 0 ? 0 : null
|
||||||
item.actualProductTrend = item.dailyOutputTrend && item.actualProductTrend != 0 ? this.multipliedByHundred(item.actualProductTrend) + '%' : item.actualProductTrend == 0 ? 0 : null
|
item.actualProductTrend = item.actualProductTrend && item.actualProductTrend != 0 ? this.multipliedByHundred(item.actualProductTrend) + '%' : item.actualProductTrend == 0 ? 0 : null
|
||||||
item.originalGlassPassTrend = item.dailyOutputTrend && item.originalGlassPassTrend != 0 ? this.multipliedByHundred(item.originalGlassPassTrend) + '%' : item.originalGlassPassTrend == 0 ? 0 : null
|
item.originalGlassPassTrend = item.originalGlassPassTrend && item.originalGlassPassTrend != 0 ? this.multipliedByHundred(item.originalGlassPassTrend) + '%' : item.originalGlassPassTrend == 0 ? 0 : null
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
@ -57,7 +57,7 @@ export default {
|
|||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
this.getCurrentMonthFirst()
|
this.getCurrentMonthFirst()
|
||||||
this.getDict()
|
// this.getDict()
|
||||||
this.getDataList()
|
this.getDataList()
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
@ -98,6 +98,8 @@ export default {
|
|||||||
},
|
},
|
||||||
// 获取数据列表
|
// 获取数据列表
|
||||||
async getDataList() {
|
async getDataList() {
|
||||||
|
const res = await getCorePLList()
|
||||||
|
this.proLineList = res.data;
|
||||||
this.dataListLoading = true;
|
this.dataListLoading = true;
|
||||||
if (this.listQuery.reportTime.length == 0) {
|
if (this.listQuery.reportTime.length == 0) {
|
||||||
this.$message({
|
this.$message({
|
||||||
@ -129,9 +131,9 @@ export default {
|
|||||||
// item.dailyOutputTrend = null
|
// item.dailyOutputTrend = null
|
||||||
// }
|
// }
|
||||||
item.dailyOutputTrend = item.dailyOutputTrend && item.dailyOutputTrend != 0 ? this.multipliedByHundred(item.dailyOutputTrend) + '%' : item.dailyOutputTrend == 0 ? 0 : null
|
item.dailyOutputTrend = item.dailyOutputTrend && item.dailyOutputTrend != 0 ? this.multipliedByHundred(item.dailyOutputTrend) + '%' : item.dailyOutputTrend == 0 ? 0 : null
|
||||||
item.originalGlassStatisticsTrend = item.dailyOutputTrend && item.originalGlassStatisticsTrend != 0 ? this.multipliedByHundred(item.originalGlassStatisticsTrend) + '%' : item.originalGlassStatisticsTrend == 0 ? 0 : null
|
item.originalGlassStatisticsTrend = item.originalGlassStatisticsTrend && item.originalGlassStatisticsTrend != 0 ? this.multipliedByHundred(item.originalGlassStatisticsTrend) + '%' : item.originalGlassStatisticsTrend == 0 ? 0 : null
|
||||||
item.actualProductTrend = item.dailyOutputTrend && item.actualProductTrend != 0 ? this.multipliedByHundred(item.actualProductTrend) + '%' : item.actualProductTrend == 0 ? 0 : null
|
item.actualProductTrend = item.actualProductTrend && item.actualProductTrend != 0 ? this.multipliedByHundred(item.actualProductTrend) + '%' : item.actualProductTrend == 0 ? 0 : null
|
||||||
item.originalGlassPassTrend = item.dailyOutputTrend && item.originalGlassPassTrend != 0 ? this.multipliedByHundred(item.originalGlassPassTrend) + '%' : item.originalGlassPassTrend == 0 ? 0 : null
|
item.originalGlassPassTrend = item.originalGlassPassTrend && item.originalGlassPassTrend != 0 ? this.multipliedByHundred(item.originalGlassPassTrend) + '%' : item.originalGlassPassTrend == 0 ? 0 : null
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
@ -86,23 +86,23 @@ export default {
|
|||||||
},
|
},
|
||||||
],
|
],
|
||||||
};
|
};
|
||||||
|
},
|
||||||
|
created () {
|
||||||
|
// this.getDict()
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
// const day = new Date().getDay()
|
// const day = new Date().getDay()
|
||||||
// console.log('周四', day)
|
// console.log('周四', day)
|
||||||
this.getCurrentWeekStartTimeAndEndTime()
|
this.getCurrentWeekStartTimeAndEndTime()
|
||||||
// this.changeTime(new Date(new Date().getTime() - day * 24 * 60 * 60 * 1000))
|
// this.changeTime(new Date(new Date().getTime() - day * 24 * 60 * 60 * 1000))
|
||||||
this.getDict()
|
|
||||||
this.getDataList()
|
this.getDataList()
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
async getDict() {
|
// async getDict() {
|
||||||
// 产线列表
|
// // 产线列表
|
||||||
await getCorePLList().then(res => {
|
|
||||||
this.proLineList = res.data;
|
|
||||||
// this.getDataList()
|
// },
|
||||||
});
|
|
||||||
},
|
|
||||||
getCurrentWeekStartTimeAndEndTime() {
|
getCurrentWeekStartTimeAndEndTime() {
|
||||||
this.reportTime = new Date()
|
this.reportTime = new Date()
|
||||||
var weekday = new Array(7);
|
var weekday = new Array(7);
|
||||||
@ -187,6 +187,8 @@ export default {
|
|||||||
},
|
},
|
||||||
// 获取数据列表
|
// 获取数据列表
|
||||||
async getDataList() {
|
async getDataList() {
|
||||||
|
const res = await getCorePLList()
|
||||||
|
this.proLineList = res.data;
|
||||||
this.dataListLoading = true;
|
this.dataListLoading = true;
|
||||||
if (this.listQuery.reportTime.length == 0) {
|
if (this.listQuery.reportTime.length == 0) {
|
||||||
this.$message({
|
this.$message({
|
||||||
@ -218,9 +220,9 @@ export default {
|
|||||||
// item.dailyOutputTrend = null
|
// item.dailyOutputTrend = null
|
||||||
// }
|
// }
|
||||||
item.dailyOutputTrend = item.dailyOutputTrend && item.dailyOutputTrend != 0 ? this.multipliedByHundred(item.dailyOutputTrend) + '%' : item.dailyOutputTrend == 0 ? 0 : null
|
item.dailyOutputTrend = item.dailyOutputTrend && item.dailyOutputTrend != 0 ? this.multipliedByHundred(item.dailyOutputTrend) + '%' : item.dailyOutputTrend == 0 ? 0 : null
|
||||||
item.originalGlassStatisticsTrend = item.dailyOutputTrend && item.originalGlassStatisticsTrend != 0 ? this.multipliedByHundred(item.originalGlassStatisticsTrend) + '%' : item.originalGlassStatisticsTrend == 0 ? 0 : null
|
item.originalGlassStatisticsTrend = item.originalGlassStatisticsTrend && item.originalGlassStatisticsTrend != 0 ? this.multipliedByHundred(item.originalGlassStatisticsTrend) + '%' : item.originalGlassStatisticsTrend == 0 ? 0 : null
|
||||||
item.actualProductTrend = item.dailyOutputTrend && item.actualProductTrend != 0 ? this.multipliedByHundred(item.actualProductTrend) + '%' : item.actualProductTrend == 0 ? 0 : null
|
item.actualProductTrend = item.actualProductTrend && item.actualProductTrend != 0 ? this.multipliedByHundred(item.actualProductTrend) + '%' : item.actualProductTrend == 0 ? 0 : null
|
||||||
item.originalGlassPassTrend = item.dailyOutputTrend && item.originalGlassPassTrend != 0 ? this.multipliedByHundred(item.originalGlassPassTrend) + '%' : item.originalGlassPassTrend == 0 ? 0 : null
|
item.originalGlassPassTrend = item.originalGlassPassTrend && item.originalGlassPassTrend != 0 ? this.multipliedByHundred(item.originalGlassPassTrend) + '%' : item.originalGlassPassTrend == 0 ? 0 : null
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
@ -53,7 +53,7 @@ export default {
|
|||||||
};
|
};
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
this.getDict()
|
// this.getDict()
|
||||||
},
|
},
|
||||||
mounted () {
|
mounted () {
|
||||||
this.getCurrentYearFirst()
|
this.getCurrentYearFirst()
|
||||||
@ -98,6 +98,8 @@ export default {
|
|||||||
},
|
},
|
||||||
// 获取数据列表
|
// 获取数据列表
|
||||||
async getDataList() {
|
async getDataList() {
|
||||||
|
const res = await getCorePLList()
|
||||||
|
this.proLineList = res.data;
|
||||||
this.dataListLoading = true;
|
this.dataListLoading = true;
|
||||||
if (this.listQuery.reportTime.length == 0) {
|
if (this.listQuery.reportTime.length == 0) {
|
||||||
this.$message({
|
this.$message({
|
||||||
@ -129,9 +131,9 @@ export default {
|
|||||||
// item.dailyOutputTrend = null
|
// item.dailyOutputTrend = null
|
||||||
// }
|
// }
|
||||||
item.dailyOutputTrend = item.dailyOutputTrend && item.dailyOutputTrend != 0 ? this.multipliedByHundred(item.dailyOutputTrend) + '%' : item.dailyOutputTrend == 0 ? 0 : null
|
item.dailyOutputTrend = item.dailyOutputTrend && item.dailyOutputTrend != 0 ? this.multipliedByHundred(item.dailyOutputTrend) + '%' : item.dailyOutputTrend == 0 ? 0 : null
|
||||||
item.originalGlassStatisticsTrend = item.dailyOutputTrend && item.originalGlassStatisticsTrend != 0 ? this.multipliedByHundred(item.originalGlassStatisticsTrend) + '%' : item.originalGlassStatisticsTrend == 0 ? 0 : null
|
item.originalGlassStatisticsTrend = item.originalGlassStatisticsTrend && item.originalGlassStatisticsTrend != 0 ? this.multipliedByHundred(item.originalGlassStatisticsTrend) + '%' : item.originalGlassStatisticsTrend == 0 ? 0 : null
|
||||||
item.actualProductTrend = item.dailyOutputTrend && item.actualProductTrend != 0 ? this.multipliedByHundred(item.actualProductTrend) + '%' : item.actualProductTrend == 0 ? 0 : null
|
item.actualProductTrend = item.actualProductTrend && item.actualProductTrend != 0 ? this.multipliedByHundred(item.actualProductTrend) + '%' : item.actualProductTrend == 0 ? 0 : null
|
||||||
item.originalGlassPassTrend = item.dailyOutputTrend && item.originalGlassPassTrend != 0 ? this.multipliedByHundred(item.originalGlassPassTrend) + '%' : item.originalGlassPassTrend == 0 ? 0 : null
|
item.originalGlassPassTrend = item.originalGlassPassTrend && item.originalGlassPassTrend != 0 ? this.multipliedByHundred(item.originalGlassPassTrend) + '%' : item.originalGlassPassTrend == 0 ? 0 : null
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
@ -83,8 +83,8 @@ export default {
|
|||||||
captchaEnable: true,
|
captchaEnable: true,
|
||||||
loginForm: {
|
loginForm: {
|
||||||
loginType: "uname",
|
loginType: "uname",
|
||||||
username: "admin",
|
username: "",
|
||||||
password: "admin123",
|
password: "",
|
||||||
rememberMe: false,
|
rememberMe: false,
|
||||||
captchaVerification: "",
|
captchaVerification: "",
|
||||||
},
|
},
|
||||||
@ -140,12 +140,12 @@ export default {
|
|||||||
this.$refs.verify.show()
|
this.$refs.verify.show()
|
||||||
},
|
},
|
||||||
getCookie() {
|
getCookie() {
|
||||||
const username = getUsername();
|
// const username = getUsername();
|
||||||
const password = getPassword();
|
// const password = getPassword();
|
||||||
const rememberMe = getRememberMe();
|
const rememberMe = getRememberMe();
|
||||||
this.loginForm = {
|
this.loginForm = {
|
||||||
username: username ? username : this.loginForm.username,
|
username: this.loginForm.username,
|
||||||
password: password ? password : this.loginForm.password,
|
password: this.loginForm.password,
|
||||||
rememberMe: rememberMe ? getRememberMe() : false,
|
rememberMe: rememberMe ? getRememberMe() : false,
|
||||||
loginType: this.loginForm.loginType,
|
loginType: this.loginForm.loginType,
|
||||||
};
|
};
|
||||||
|
@ -42,7 +42,7 @@ export function WsConnect(url, agentData, successCallback, errCallback) {
|
|||||||
this.lockReconnect = true;
|
this.lockReconnect = true;
|
||||||
this.wsCreateHandler && clearTimeout(this.wsCreateHandler);
|
this.wsCreateHandler && clearTimeout(this.wsCreateHandler);
|
||||||
// 关闭心跳检查
|
// 关闭心跳检查
|
||||||
// heartCheck.stop();
|
heartCheck.stop();
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
const initWsEventHandle = () => {
|
const initWsEventHandle = () => {
|
||||||
@ -50,13 +50,13 @@ export function WsConnect(url, agentData, successCallback, errCallback) {
|
|||||||
// 连接成功
|
// 连接成功
|
||||||
this.wsObj.onopen = (event) => {
|
this.wsObj.onopen = (event) => {
|
||||||
onWsOpen(event);
|
onWsOpen(event);
|
||||||
// heartCheck.start();
|
heartCheck.start();
|
||||||
};
|
};
|
||||||
|
|
||||||
// 监听服务器端返回的信息
|
// 监听服务器端返回的信息
|
||||||
this.wsObj.onmessage = (event) => {
|
this.wsObj.onmessage = (event) => {
|
||||||
onWsMessage(event);
|
onWsMessage(event);
|
||||||
// heartCheck.start();
|
heartCheck.start();
|
||||||
};
|
};
|
||||||
|
|
||||||
this.wsObj.onclose = (event) => {
|
this.wsObj.onclose = (event) => {
|
||||||
@ -123,7 +123,7 @@ export function WsConnect(url, agentData, successCallback, errCallback) {
|
|||||||
if (this.lockReconnect) {
|
if (this.lockReconnect) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
writeToScreen("3秒后重连");
|
writeToScreen("5秒后重连");
|
||||||
this.lockReconnect = true;
|
this.lockReconnect = true;
|
||||||
// 没连接上会一直重连,设置延迟避免请求过多
|
// 没连接上会一直重连,设置延迟避免请求过多
|
||||||
this.wsCreateHandler && clearTimeout(this.wsCreateHandler);
|
this.wsCreateHandler && clearTimeout(this.wsCreateHandler);
|
||||||
@ -132,10 +132,40 @@ export function WsConnect(url, agentData, successCallback, errCallback) {
|
|||||||
this.createWebSoket();
|
this.createWebSoket();
|
||||||
this.lockReconnect = false;
|
this.lockReconnect = false;
|
||||||
writeToScreen("重连完成");
|
writeToScreen("重连完成");
|
||||||
}, 3000);
|
}, 5000);
|
||||||
};
|
};
|
||||||
|
|
||||||
// 心跳检查(看看websocket是否还在正常连接中)
|
// 心跳检查(看看websocket是否还在正常连接中,不需要服务端返回,单向的)
|
||||||
|
let _this = this
|
||||||
|
let heartCheck = {
|
||||||
|
timeout: 55000,
|
||||||
|
timeoutObj: null,
|
||||||
|
// 重启
|
||||||
|
reset() {
|
||||||
|
clearTimeout(this.timeoutObj);
|
||||||
|
this.start();
|
||||||
|
},
|
||||||
|
// 停止
|
||||||
|
stop() {
|
||||||
|
clearTimeout(this.timeoutObj);
|
||||||
|
},
|
||||||
|
// 开启定时器
|
||||||
|
start() {
|
||||||
|
this.timeoutObj && clearTimeout(this.timeoutObj);
|
||||||
|
this.timeoutObj = setTimeout(() => {
|
||||||
|
writeToScreen("心跳检查,发送ping到后台");
|
||||||
|
try {
|
||||||
|
const datas = { ping: true };
|
||||||
|
_this.wsObj.send(JSON.stringify(datas));
|
||||||
|
} catch (err) {
|
||||||
|
writeToScreen("发送ping异常");
|
||||||
|
}
|
||||||
|
}, this.timeout);
|
||||||
|
},
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
// 心跳检查(看看websocket是否还在正常连接中,和服务端通信,双向的)
|
||||||
// let heartCheck = {
|
// let heartCheck = {
|
||||||
// timeout: 15000,
|
// timeout: 15000,
|
||||||
// timeoutObj: null,
|
// timeoutObj: null,
|
||||||
@ -160,7 +190,7 @@ export function WsConnect(url, agentData, successCallback, errCallback) {
|
|||||||
// writeToScreen("心跳检查,发送ping到后台");
|
// writeToScreen("心跳检查,发送ping到后台");
|
||||||
// try {
|
// try {
|
||||||
// const datas = { ping: true };
|
// const datas = { ping: true };
|
||||||
// this.wsObj.send(JSON.stringify(datas));
|
// _this.wsObj.send(JSON.stringify(datas));
|
||||||
// } catch (err) {
|
// } catch (err) {
|
||||||
// writeToScreen("发送ping异常");
|
// writeToScreen("发送ping异常");
|
||||||
// }
|
// }
|
||||||
|
@ -11,7 +11,12 @@ const dcsConn = new WsConnect(
|
|||||||
'',
|
'',
|
||||||
(data) => {
|
(data) => {
|
||||||
// console.log('dcs成功的回调函数, 接收到的data数据: ', data)
|
// console.log('dcs成功的回调函数, 接收到的data数据: ', data)
|
||||||
let msgData = JSON.parse(data)
|
let msgData = {}
|
||||||
|
try {
|
||||||
|
msgData = JSON.parse(data)
|
||||||
|
} catch (error) {
|
||||||
|
console.log("websocket: [unable to msgData] : ", data);
|
||||||
|
}
|
||||||
if (msgData == null) return;
|
if (msgData == null) return;
|
||||||
switch (msgData?.type) {
|
switch (msgData?.type) {
|
||||||
case "FanFrequencyInfo": {
|
case "FanFrequencyInfo": {
|
||||||
@ -43,8 +48,12 @@ const mesIsra = new WsConnect(
|
|||||||
'',
|
'',
|
||||||
(data) => {
|
(data) => {
|
||||||
// console.log('mes ISRA成功的回调函数, 接收到的data数据: ', data)
|
// console.log('mes ISRA成功的回调函数, 接收到的data数据: ', data)
|
||||||
let msgData = JSON.parse(data)
|
let msgData = {}
|
||||||
// console.log(msgData)
|
try {
|
||||||
|
msgData = JSON.parse(data)
|
||||||
|
} catch (error) {
|
||||||
|
console.log("websocket: [unable to msgData] : ", data);
|
||||||
|
}
|
||||||
if (msgData == null) return;
|
if (msgData == null) return;
|
||||||
switch (msgData?.type) {
|
switch (msgData?.type) {
|
||||||
case "israKiln": {
|
case "israKiln": {
|
||||||
@ -65,7 +74,12 @@ const mesMA = new WsConnect(
|
|||||||
'',
|
'',
|
||||||
(data) => {
|
(data) => {
|
||||||
// console.log('mes 原料成功的回调函数, 接收到的data数据: ', data)
|
// console.log('mes 原料成功的回调函数, 接收到的data数据: ', data)
|
||||||
let msgData = JSON.parse(data)
|
let msgData = {}
|
||||||
|
try {
|
||||||
|
msgData = JSON.parse(data)
|
||||||
|
} catch (error) {
|
||||||
|
console.log("websocket: [unable to msgData] : ", data);
|
||||||
|
}
|
||||||
if (msgData == null) return;
|
if (msgData == null) return;
|
||||||
switch (msgData?.type) {
|
switch (msgData?.type) {
|
||||||
case "material": {
|
case "material": {
|
||||||
@ -88,7 +102,12 @@ const mesEN = new WsConnect(
|
|||||||
// 成功拿到后台返回的数据的回调函数
|
// 成功拿到后台返回的数据的回调函数
|
||||||
(data) => {
|
(data) => {
|
||||||
// console.log('mes 能耗成功的回调函数, 接收到的data数据: ', data)
|
// console.log('mes 能耗成功的回调函数, 接收到的data数据: ', data)
|
||||||
let msgData = JSON.parse(data)
|
let msgData = {}
|
||||||
|
try {
|
||||||
|
msgData = JSON.parse(data)
|
||||||
|
} catch (error) {
|
||||||
|
console.log("websocket: [unable to msgData] : ", data);
|
||||||
|
}
|
||||||
if (msgData == null) return;
|
if (msgData == null) return;
|
||||||
switch (msgData?.type) {
|
switch (msgData?.type) {
|
||||||
case "EnergyInfo": {
|
case "EnergyInfo": {
|
||||||
@ -120,17 +139,24 @@ const mesGAS = new WsConnect(
|
|||||||
// 成功拿到后台返回的数据的回调函数
|
// 成功拿到后台返回的数据的回调函数
|
||||||
(data) => {
|
(data) => {
|
||||||
// console.log('mes 烟气成功的回调函数, 接收到的data数据: ', data)
|
// console.log('mes 烟气成功的回调函数, 接收到的data数据: ', data)
|
||||||
let msgData = JSON.parse(data)
|
let msgData = {}
|
||||||
|
try {
|
||||||
|
msgData = JSON.parse(data)
|
||||||
|
} catch (error) {
|
||||||
|
console.log("websocket: [unable to msgData] : ", data);
|
||||||
|
}
|
||||||
if (msgData == null) return;
|
if (msgData == null) return;
|
||||||
switch (msgData?.type) {
|
switch (msgData?.type) {
|
||||||
case "exhaustGas": {
|
case "exhaustGas": {
|
||||||
store.dispatch({ type: "websocket/setExhaustGasInfo", payload: msgData.realtime })
|
store.dispatch({ type: "websocket/setExhaustGasInfo", payload: msgData.realtime })
|
||||||
store.dispatch({type: "websocket/setExhaustGasChart", payload:{
|
store.dispatch({
|
||||||
|
type: "websocket/setExhaustGasChart", payload: {
|
||||||
dayTrend: msgData.dayTrend,
|
dayTrend: msgData.dayTrend,
|
||||||
weekTrend: msgData.weekTrend,
|
weekTrend: msgData.weekTrend,
|
||||||
monthTrend: msgData.monthTrend,
|
monthTrend: msgData.monthTrend,
|
||||||
yearTrend: msgData.yearTrend,
|
yearTrend: msgData.yearTrend,
|
||||||
}})
|
}
|
||||||
|
})
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
default:
|
default:
|
||||||
@ -151,17 +177,24 @@ const mesIS = new WsConnect(
|
|||||||
// 成功拿到后台返回的数据的回调函数
|
// 成功拿到后台返回的数据的回调函数
|
||||||
(data) => {
|
(data) => {
|
||||||
// console.log('mes 缺陷成功的回调函数, 接收到的data数据: ', data)
|
// console.log('mes 缺陷成功的回调函数, 接收到的data数据: ', data)
|
||||||
let msgData = JSON.parse(data)
|
let msgData = {}
|
||||||
|
try {
|
||||||
|
msgData = JSON.parse(data)
|
||||||
|
} catch (error) {
|
||||||
|
console.log("websocket: [unable to msgData] : ", data);
|
||||||
|
}
|
||||||
if (msgData == null) return;
|
if (msgData == null) return;
|
||||||
switch (msgData?.type) {
|
switch (msgData?.type) {
|
||||||
case "isra": {
|
case "isra": {
|
||||||
store.dispatch({type: "websocket/setDefectChart", payload:{
|
store.dispatch({
|
||||||
|
type: "websocket/setDefectChart", payload: {
|
||||||
checkType: msgData.detData.checkType,
|
checkType: msgData.detData.checkType,
|
||||||
dayStatistic: msgData.detData.dayStatistic,
|
dayStatistic: msgData.detData.dayStatistic,
|
||||||
weekStatistic: msgData.detData.weekStatistic,
|
weekStatistic: msgData.detData.weekStatistic,
|
||||||
monthStatistic: msgData.detData.monthStatistic,
|
monthStatistic: msgData.detData.monthStatistic,
|
||||||
yearStatistic: msgData.detData.yearStatistic,
|
yearStatistic: msgData.detData.yearStatistic,
|
||||||
}})
|
}
|
||||||
|
})
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
default:
|
default:
|
||||||
@ -182,7 +215,12 @@ const mesSJG = new WsConnect(
|
|||||||
// 成功拿到后台返回的数据的回调函数
|
// 成功拿到后台返回的数据的回调函数
|
||||||
(data) => {
|
(data) => {
|
||||||
// console.log('mes 产线产量及良品率成功的回调函数, 接收到的data数据: ', data)
|
// console.log('mes 产线产量及良品率成功的回调函数, 接收到的data数据: ', data)
|
||||||
let msgData = JSON.parse(data)
|
let msgData = {}
|
||||||
|
try {
|
||||||
|
msgData = JSON.parse(data)
|
||||||
|
} catch (error) {
|
||||||
|
console.log("websocket: [unable to msgData] : ", data);
|
||||||
|
}
|
||||||
if (msgData == null) return;
|
if (msgData == null) return;
|
||||||
switch (msgData?.type) {
|
switch (msgData?.type) {
|
||||||
case "productline": {
|
case "productline": {
|
||||||
@ -220,7 +258,12 @@ const mesOV = new WsConnect(
|
|||||||
// 成功拿到后台返回的数据的回调函数
|
// 成功拿到后台返回的数据的回调函数
|
||||||
(data) => {
|
(data) => {
|
||||||
// console.log('mes 产线产量及良品率成功的回调函数, 接收到的data数据: ', data)
|
// console.log('mes 产线产量及良品率成功的回调函数, 接收到的data数据: ', data)
|
||||||
let msgData = JSON.parse(data)
|
let msgData = {}
|
||||||
|
try {
|
||||||
|
msgData = JSON.parse(data)
|
||||||
|
} catch (error) {
|
||||||
|
console.log("websocket: [unable to msgData] : ", data);
|
||||||
|
}
|
||||||
if (msgData == null) return;
|
if (msgData == null) return;
|
||||||
switch (msgData?.type) {
|
switch (msgData?.type) {
|
||||||
case "order": {
|
case "order": {
|
||||||
@ -245,9 +288,13 @@ const mesCUTTING = new WsConnect(
|
|||||||
// 成功拿到后台返回的数据的回调函数
|
// 成功拿到后台返回的数据的回调函数
|
||||||
(data) => {
|
(data) => {
|
||||||
// console.log('mes 产线产量及良品率成功的回调函数, 接收到的data数据: ', data)
|
// console.log('mes 产线产量及良品率成功的回调函数, 接收到的data数据: ', data)
|
||||||
let msgData = JSON.parse(data)
|
let msgData = {}
|
||||||
|
try {
|
||||||
|
msgData = JSON.parse(data)
|
||||||
|
} catch (error) {
|
||||||
|
console.log("websocket: [unable to msgData] : ", data);
|
||||||
|
}
|
||||||
if (msgData == null) return;
|
if (msgData == null) return;
|
||||||
console.log(msgData)
|
|
||||||
switch (msgData?.type) {
|
switch (msgData?.type) {
|
||||||
case "cutting": {
|
case "cutting": {
|
||||||
if (msgData?.name === 'table') {
|
if (msgData?.name === 'table') {
|
||||||
|
Loading…
Reference in New Issue
Block a user