4 Commits

Author SHA1 Message Date
f0562eade5 Merge pull request '修改EAP' (#97) from zwq into develop
All checks were successful
continuous-integration/drone/push Build is passing
Reviewed-on: #97
2022-08-09 10:07:48 +08:00
zwq
396e09f696 修改EAP 2022-08-09 10:07:17 +08:00
0402b24568 Merge pull request '更新ERP' (#96) from zwq into develop
All checks were successful
continuous-integration/drone/push Build is passing
Reviewed-on: #96
2022-07-29 16:33:15 +08:00
zwq
dcbece43f8 更新ERP 2022-07-29 16:32:28 +08:00
16 changed files with 115 additions and 68 deletions

2
dist/index.html vendored

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1 @@
.app-container[data-v-3a23e516]{width:100%;height:200px}.waring[data-v-3a23e516]{padding:5px;border-radius:5px;background-color:#f56c6c;color:#fff}.normal[data-v-3a23e516]{padding:5px;border-radius:5px;background-color:#67c23a;color:#fff}

View File

@@ -1 +0,0 @@
.app-container[data-v-6d6503bb]{width:100%;height:200px}.waring[data-v-6d6503bb]{padding:5px;border-radius:5px;background-color:#f56c6c;color:#fff}.normal[data-v-6d6503bb]{padding:5px;border-radius:5px;background-color:#67c23a;color:#fff}.btn-container[data-v-2ecdfc10]{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;-ms-flex-wrap:wrap;flex-wrap:wrap}.btndiv[data-v-2ecdfc10]{width:20%;height:100px;margin:auto}.box-card[data-v-2ecdfc10]{background-color:#3e8ef7;margin:10px;color:#fff}

View File

@@ -1 +0,0 @@
.app-container[data-v-6d6503bb]{width:100%;height:200px}.waring[data-v-6d6503bb]{padding:5px;border-radius:5px;background-color:#f56c6c;color:#fff}.normal[data-v-6d6503bb]{padding:5px;border-radius:5px;background-color:#67c23a;color:#fff}

View File

@@ -0,0 +1 @@
.app-container[data-v-3a23e516]{width:100%;height:200px}.waring[data-v-3a23e516]{padding:5px;border-radius:5px;background-color:#f56c6c;color:#fff}.normal[data-v-3a23e516]{padding:5px;border-radius:5px;background-color:#67c23a;color:#fff}.btn-container[data-v-2e322fe2]{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;-ms-flex-wrap:wrap;flex-wrap:wrap}.btndiv[data-v-2e322fe2]{width:20%;height:100px;margin:auto}.box-card[data-v-2e322fe2]{background-color:#3e8ef7;margin:10px;color:#fff}

File diff suppressed because one or more lines are too long

1
dist/static/js/app.6fb7a37a.js vendored Normal file

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -228,3 +228,17 @@ export function sendReportLinkedEventAndVid() {
method: 'post' method: 'post'
}) })
} }
export function sendSecsGemSetting() {
return request({
url: '/cigs-00a/IL1testcontroller/post/sendSecsGemSetting',
method: 'post'
})
}
export function sendAlarmReport() {
return request({
url: '/cigs-00a/IL1testcontroller/post/sendAlarmReport',
method: 'post'
})
}

View File

@@ -267,11 +267,11 @@ export default {
zh: '首页', zh: '首页',
en: 'Home' en: 'Home'
}, },
aSpc: { eap: {
zh: 'EAP', zh: 'EAP',
en: 'EAP' en: 'EAP'
}, },
spcControl: { eapControl: {
zh: 'EAP控制', zh: 'EAP控制',
en: 'EAP Control' en: 'EAP Control'
}, },

View File

@@ -93,24 +93,24 @@ export const constantRoutes = [
] ]
}, },
{ {
path: '/spc', path: '/eap',
component: Layout, component: Layout,
redirect: '/spc', redirect: '/eap',
name: 'spc', name: 'eap',
meta: { title: routerTitle.aSpc?.[language] || routerTitle.aSpc.en, icon: 'form', iconPart: 'ArtManager', affix: true, required: true, requireToken: true }, meta: { title: routerTitle.eap?.[language] || routerTitle.eap.en, icon: 'form', iconPart: 'ArtManager', affix: true, required: true, requireToken: true },
children: [ children: [
{ {
path: 'spc', path: 'eap',
component: () => import('@/views/00a-spc/index'), component: () => import('@/views/EAP/index'),
name: 'spc', name: 'eap',
meta: { title: routerTitle.aSpc?.[language] || routerTitle.aSpc.en, icon: 'form', affix: true, required: true, requireToken: true, noCache: true } meta: { title: routerTitle.eap?.[language] || routerTitle.eap.en, icon: 'form', affix: true, required: true, requireToken: true, noCache: true }
}, },
{ {
path: 'spcControl', path: 'eapControl',
component: () => import('@/views/00a-spc/spcControl'), component: () => import('@/views/EAP/eapControl'),
name: 'spcControl', name: 'eapControl',
hidden: true, hidden: true,
meta: { title: routerTitle.spcControl?.[language] || routerTitle.spcControl.en, icon: 'form', affix: true, required: true, requireToken: true, noCache: true } meta: { title: routerTitle.eapControl?.[language] || routerTitle.eapControl.en, icon: 'form', affix: true, required: true, requireToken: true, noCache: true }
} }
] ]
}, },

View File

@@ -2,7 +2,7 @@
* @Author: zwq * @Author: zwq
* @Date: 2020-12-29 15:41:11 * @Date: 2020-12-29 15:41:11
* @LastEditors: zwq * @LastEditors: zwq
* @LastEditTime: 2022-07-22 16:34:32 * @LastEditTime: 2022-08-05 09:09:17
* @Description: * @Description:
--> -->
<template> <template>
@@ -17,16 +17,12 @@
> >
<el-col :span="4"> <el-col :span="4">
<el-form-item label="communication状态" prop="communicationState" required> <el-form-item label="communication状态" prop="communicationState" required>
<el-switch <span :class="dataForm.communicationState === 0? 'waring' : 'normal'">{{ dataForm.communicationState === 0? 'off' : 'on' }}</span>
v-model="dataForm.communicationState" <el-button type="primary" size="mini" @click="switchChange()">控制</el-button>
:active-value="1"
:inactive-value="0"
@change="switchChange()"
/>
</el-form-item> </el-form-item>
<div v-show="communicationShow">Result ={{ communicationStatus }}</div> <!-- <div v-show="communicationShow">Result ={{ communicationStatus }}</div> -->
</el-col> </el-col>
<el-col :span="6" :offset="1"> <el-col v-if="false" :span="6" :offset="1">
<el-form-item label="eqpState" prop="eqpState"> <el-form-item label="eqpState" prop="eqpState">
<el-select v-model="dataForm.eqpState" placeholder="请选择下拉选择" clearable @change="eqpStateChange"> <el-select v-model="dataForm.eqpState" placeholder="请选择下拉选择" clearable @change="eqpStateChange">
<el-option <el-option
@@ -36,7 +32,7 @@
:value="item.value" :value="item.value"
/> />
</el-select> </el-select>
<div v-show="eqpStatusShow">Result ={{ eqpStatus }}</div> <!-- <div v-show="eqpStatusShow">Result ={{ eqpStatus }}</div> -->
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8"> <el-col :span="8">
@@ -49,12 +45,18 @@
:value="item.value" :value="item.value"
/> />
</el-select> </el-select>
<span :class="dataForm.controllerState === 1? 'waring' : 'normal'">{{ controllerInfo }}</span> <span :class="controllerInfo === 'offline'? 'waring' : 'normal'">{{ controllerInfo }}</span>
<div v-show="controllerStatusShow">Result ={{ controllerStatus }}</div> <!-- <div v-show="controllerStatusShow">Result ={{ controllerStatus }}</div> -->
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-form> </el-form>
<el-col :span="3" :offset="2">
<el-button type="primary" @click="sendSecsGemSetting()">Setting</el-button>
</el-col>
<el-col :span="3"> <el-col :span="3">
<el-button type="primary" @click="sendAlarmReport()">AlarmReport</el-button>
</el-col>
<el-col v-if="false" :span="3">
<el-button type="primary" @click="sendReportLinkedEventAndVid()"> ReportLinkedEventAndVid </el-button> <el-button type="primary" @click="sendReportLinkedEventAndVid()"> ReportLinkedEventAndVid </el-button>
</el-col> </el-col>
</el-row> </el-row>
@@ -68,8 +70,10 @@ import {
getcontrollerState, getcontrollerState,
sendEqpState, sendEqpState,
sendControllerState, sendControllerState,
sendReportLinkedEventAndVid sendReportLinkedEventAndVid,
} from '@/api/00a-spc' sendSecsGemSetting,
sendAlarmReport
} from '@/api/EAP'
/** /**
* 表格表头配置项 TypeScript接口注释 * 表格表头配置项 TypeScript接口注释
* tableConfig<ConfigItem> = [] * tableConfig<ConfigItem> = []
@@ -126,8 +130,11 @@ export default {
'label': 'offline', 'label': 'offline',
'value': 1 'value': 1
}, { }, {
'label': 'online', 'label': 'local',
'value': 2 'value': 2
}, {
'label': 'remote',
'value': 3
}], }],
websock: '', websock: '',
url: '', url: '',
@@ -151,7 +158,8 @@ export default {
methods: { methods: {
switchChange() { switchChange() {
this.communicationShow = false this.communicationShow = false
DisableEnableCommunication(this.dataForm.communicationState).then(response => { const cState = this.dataForm.communicationState ? 0 : 1
DisableEnableCommunication(cState).then(response => {
this.$message({ this.$message({
message: this.$t('module.basicData.visual.success'), message: this.$t('module.basicData.visual.success'),
type: 'success', type: 'success',
@@ -173,7 +181,7 @@ export default {
this.controllerStatusShow = false this.controllerStatusShow = false
sendControllerState(this.dataForm.controllerState).then(response => { sendControllerState(this.dataForm.controllerState).then(response => {
this.$message({ this.$message({
message: this.$t('module.basicData. visual.success'), message: this.$t('module.basicData.visual.success'),
type: 'success', type: 'success',
duration: 1500 duration: 1500
}) })
@@ -182,14 +190,16 @@ export default {
getState() { getState() {
getcontrollerState().then(res => { getcontrollerState().then(res => {
if (res.data.controllerState === 1) { if (res.data.controllerState === 1) {
this.dataForm.controllerState = 1
this.controllerInfo = 'offline' this.controllerInfo = 'offline'
} else if (res.data.eqpState === 4) { } else if (res.data.eqpState === 4) {
this.dataForm.controllerState = 2
this.controllerInfo = 'local' this.controllerInfo = 'local'
} else if (res.data.eqpState === 5) { } else if (res.data.eqpState === 5) {
this.dataForm.controllerState = 3
this.controllerInfo = 'remote' this.controllerInfo = 'remote'
} }
this.dataForm.eqpState = res.data.eqpState this.dataForm.eqpState = res.data.eqpState
this.dataForm.controllerState = res.data.controllerState
}) })
}, },
sendReportLinkedEventAndVid() { sendReportLinkedEventAndVid() {
@@ -201,9 +211,27 @@ export default {
}) })
}) })
}, },
sendSecsGemSetting() {
sendSecsGemSetting().then(response => {
this.$message({
message: this.$t('module.basicData.visual.success'),
type: 'success',
duration: 1500
})
})
},
sendAlarmReport() {
sendAlarmReport().then(response => {
this.$message({
message: this.$t('module.basicData.visual.success'),
type: 'success',
duration: 1500
})
})
},
initWebSocket() { initWebSocket() {
// weosocket // weosocket
const path = `ws://${this.url}/opcua/websocket/1` const path = `ws://${this.url}/opcua/websocket/${Math.round(Math.random() * 100)}`
this.websock = new WebSocket(path) this.websock = new WebSocket(path)
this.websock.onmessage = this.websocketonmessage this.websock.onmessage = this.websocketonmessage
this.websock.onopen = this.websocketonopen this.websock.onopen = this.websocketonopen
@@ -211,6 +239,7 @@ export default {
this.websock.onclose = this.websocketclose this.websock.onclose = this.websocketclose
}, },
websocketonopen() { websocketonopen() {
console.log('websocketonopen')
// send // send
// this.websocketsend(JSON.stringify('2')) // this.websocketsend(JSON.stringify('2'))
}, },
@@ -221,24 +250,27 @@ export default {
websocketonmessage(e) { websocketonmessage(e) {
// //
this.wbData = JSON.parse(e.data) this.wbData = JSON.parse(e.data)
if (this.wbData.eqpResult) { console.log(this.wbData)
this.eqpStatus = this.wbData.eqpResult if (this.wbData.controllerState) {
this.dataForm.eqpState = parseInt(this.wbData.eqpState)
this.eqpStatusShow = true
} else if (this.wbData.vidResult) {
this.controllerStatus = this.wbData.vidResult this.controllerStatus = this.wbData.vidResult
this.dataForm.controllerState = parseInt(this.wbData.controllerState)
if (this.wbData.controllerState === '1') { if (this.wbData.controllerState === '1') {
this.dataForm.controllerState = 1
this.controllerInfo = 'offline' this.controllerInfo = 'offline'
} else if (this.wbData.eqpState === '4') { } else if (this.wbData.eqpState === '4') {
this.dataForm.controllerState = 2
this.controllerInfo = 'local' this.controllerInfo = 'local'
} else if (this.wbData.eqpState === '5') { } else if (this.wbData.eqpState === '5') {
this.dataForm.controllerState = 3
this.controllerInfo = 'remote' this.controllerInfo = 'remote'
} }
this.controllerStatusShow = true this.controllerStatusShow = true
} else if (this.wbData.eqpState) {
this.eqpStatus = this.wbData.eqpResult
this.dataForm.eqpState = parseInt(this.wbData.eqpState)
this.eqpStatusShow = true
} else { } else {
this.communicationStatus = this.wbData.communicationResult this.communicationStatus = this.wbData.communicationResult
this.dataForm.communicationState = parseInt(this.wbData.communicationState) this.dataForm.communicationState = parseInt(this.wbData.connectState)
this.communicationShow = true this.communicationShow = true
} }
}, },
@@ -249,6 +281,7 @@ export default {
websocketclose(e) { websocketclose(e) {
// //
console.log('断开连接', e) console.log('断开连接', e)
this.initWebSocket()
} }
} }
} }

View File

@@ -2,7 +2,7 @@
* @Author: zwq * @Author: zwq
* @Date: 2020-12-29 15:41:11 * @Date: 2020-12-29 15:41:11
* @LastEditors: zwq * @LastEditors: zwq
* @LastEditTime: 2022-07-21 15:07:28 * @LastEditTime: 2022-08-03 16:30:27
* @Description: * @Description:
--> -->
<template> <template>
@@ -17,8 +17,8 @@
</template> </template>
<script> <script>
import * as spcApi from '@/api/00a-spc' import * as spcApi from '@/api/EAP'
import spcControl from './spcControl' import spcControl from './eapControl'
// , handleLimit // , handleLimit
/** /**
* 表格表头配置项 TypeScript接口注释 * 表格表头配置项 TypeScript接口注释
@@ -52,31 +52,31 @@ export default {
data() { data() {
return { return {
btnList: [ btnList: [
'AlarmCleared', 'EquipmentOffline',
'AlarmDetected',
'CompleteProcessFlow',
'ControlStateLocal', 'ControlStateLocal',
'ControlStateRemote', 'ControlStateRemote',
'E10StateChanged', 'AlarmDetected',
'EmptyCassettereport', 'AlarmCleared',
'EquipmentOffline', // 'SpoolTransmitFailure',
'MaintenancePlan', // 'SpoolingActivated',
'MaintenanceRecord', // 'SpoolingDeactivated',
'ProcessingStarted',
'ProcessingCompleted',
'ProcessingStopped',
'MaterialReceived', 'MaterialReceived',
'MaterialRemoved', 'MaterialRemoved',
'OKsubstratereport', 'E10StateChanged',
'PowerConsumption', 'CompleteProcessFlow',
'ProcessingCompleted', 'MaintenancePlan',
'ProcessingStarted', 'MaintenanceRecord',
'ProcessingStopped',
'QCPChange',
'RepairRecord', 'RepairRecord',
'Scrapsubstratereport',
'ShuttleMovementFinished',
'ShuttleMovementStart', 'ShuttleMovementStart',
'SpoolTransmitFailure', 'ShuttleMovementFinished',
'SpoolingActivated', 'QCPChange',
'SpoolingDeactivated' 'PowerConsumption',
'OKsubstratereport',
'Scrapsubstratereport',
'EmptyCassettereport'
] ]
} }
}, },