调整bug
This commit is contained in:
+16
-7
@@ -16,13 +16,10 @@ export default {
|
|||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
let that = this
|
let that = this
|
||||||
if (that.$store.getters.token) {
|
// if (that.$store.getters.token) {
|
||||||
that.$store.dispatch('chat/initWebSocket') // 初始化websocket
|
|
||||||
}
|
// }
|
||||||
this.showNotify()
|
that.$store.dispatch('chat/initWebSocket') // 初始化websocket
|
||||||
this.showNotify()
|
|
||||||
this.showNotify()
|
|
||||||
this.showNotify()
|
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
'$store.state.chat.printer_error': {
|
'$store.state.chat.printer_error': {
|
||||||
@@ -50,6 +47,18 @@ export default {
|
|||||||
},
|
},
|
||||||
deep: true,
|
deep: true,
|
||||||
immediate: true
|
immediate: true
|
||||||
|
},
|
||||||
|
'$store.state.chat.isConnect': {
|
||||||
|
handler(val) {
|
||||||
|
let that = this
|
||||||
|
if (val) {
|
||||||
|
that.errors = []
|
||||||
|
} else {
|
||||||
|
that.$notify.closeAll()
|
||||||
|
}
|
||||||
|
},
|
||||||
|
deep: true,
|
||||||
|
immediate: true
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
|||||||
@@ -1060,13 +1060,17 @@ export default {
|
|||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
height: 40px;
|
height: 40px;
|
||||||
padding: 0 22px;
|
padding: 0 22px;
|
||||||
background: rgba(0, 195, 37, 0.12);
|
background: transparent;
|
||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
border: 1px solid rgba(0, 195, 37, 0.32);
|
border: 1px solid #999;
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
font-size: 18px;
|
font-size: 18px;
|
||||||
color: #00c325;
|
color: #333;
|
||||||
|
&:hover {
|
||||||
|
background: rgba(0, 195, 37, 0.32);
|
||||||
|
border: 1px solid rgba(0, 195, 37, 0.32);
|
||||||
|
color: #00c325;
|
||||||
|
}
|
||||||
img {
|
img {
|
||||||
width: 22px;
|
width: 22px;
|
||||||
height: 22px;
|
height: 22px;
|
||||||
@@ -1116,13 +1120,18 @@ export default {
|
|||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
height: 40px;
|
height: 40px;
|
||||||
padding: 0 22px;
|
padding: 0 22px;
|
||||||
background: rgba(0, 195, 37, 0.12);
|
background: transparent;
|
||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
border: 1px solid rgba(0, 195, 37, 0.32);
|
border: 1px solid #999;
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
font-size: 16px;
|
font-size: 16px;
|
||||||
color: #00c325;
|
color: #333;
|
||||||
margin-right: 22px;
|
margin-right: 22px;
|
||||||
|
&:hover {
|
||||||
|
background: rgba(0, 195, 37, 0.32);
|
||||||
|
border: 1px solid rgba(0, 195, 37, 0.32);
|
||||||
|
color: #00c325;
|
||||||
|
}
|
||||||
|
|
||||||
img {
|
img {
|
||||||
width: 20px;
|
width: 20px;
|
||||||
@@ -1419,13 +1428,18 @@ export default {
|
|||||||
.footer_save {
|
.footer_save {
|
||||||
width: 166px;
|
width: 166px;
|
||||||
height: 45px;
|
height: 45px;
|
||||||
background: #00bcc3;
|
background: transparent;
|
||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
font-size: 19px;
|
font-size: 19px;
|
||||||
color: #ffffff;
|
color: #333;
|
||||||
|
border: 1px solid #999;
|
||||||
padding: 0;
|
padding: 0;
|
||||||
margin-right: 22px;
|
margin-right: 22px;
|
||||||
|
&:hover {
|
||||||
|
background: #00bcc3;
|
||||||
|
color: #ffffff;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.footer_submit {
|
.footer_submit {
|
||||||
|
|||||||
@@ -535,7 +535,8 @@ const actions = {
|
|||||||
// 心跳检测重连
|
// 心跳检测重连
|
||||||
pingCheck({ state, commit, dispatch, rootState }) {
|
pingCheck({ state, commit, dispatch, rootState }) {
|
||||||
if (state.pingNum < 4) {
|
if (state.pingNum < 4) {
|
||||||
state.pingNum++
|
let num = state.pingNum + 1
|
||||||
|
commit('setData', { name: 'pingNum', data: num })
|
||||||
timeouter = setTimeout(() => {
|
timeouter = setTimeout(() => {
|
||||||
dispatch('pingCheck')
|
dispatch('pingCheck')
|
||||||
}, 10000)
|
}, 10000)
|
||||||
@@ -590,7 +591,8 @@ const actions = {
|
|||||||
commit('setData', { name: 'connecting', data: false })
|
commit('setData', { name: 'connecting', data: false })
|
||||||
commit('setData', { name: 'isConnect', data: false })
|
commit('setData', { name: 'isConnect', data: false })
|
||||||
commit('setData', { name: 'serviceStatus', data: false })
|
commit('setData', { name: 'serviceStatus', data: false })
|
||||||
state.reconnections += 1
|
let num = state.reconnections + 1
|
||||||
|
commit('setData', { name: 'reconnections', data: num })
|
||||||
const refreshTime = parseInt(state.refreshTime) * 1000
|
const refreshTime = parseInt(state.refreshTime) * 1000
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
dispatch('initWebSocket')
|
dispatch('initWebSocket')
|
||||||
|
|||||||
@@ -23,7 +23,7 @@
|
|||||||
</el-tooltip>
|
</el-tooltip>
|
||||||
<div class="flex_box top_left_option">
|
<div class="flex_box top_left_option">
|
||||||
<div class="top_left_text">完成刻录数:</div>
|
<div class="top_left_text">完成刻录数:</div>
|
||||||
<div class="top_left_num">{{ taskNum[0] }}</div>
|
<div class="top_left_num top_left_num1">{{ taskNum[0] }}</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="flex_box top_left_option">
|
<div class="flex_box top_left_option">
|
||||||
<div class="top_left_text">废弃刻录数:</div>
|
<div class="top_left_text">废弃刻录数:</div>
|
||||||
@@ -31,7 +31,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="flex_box top_left_option">
|
<div class="flex_box top_left_option">
|
||||||
<div class="top_left_text">错误:</div>
|
<div class="top_left_text">错误:</div>
|
||||||
<div class="top_left_num">{{ taskNum[2] }}</div>
|
<div class="top_left_num top_left_num1">{{ taskNum[2] }}</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="top_left_line"></div>
|
<div class="top_left_line"></div>
|
||||||
</div>
|
</div>
|
||||||
@@ -287,7 +287,7 @@
|
|||||||
<el-table-column prop="task_status" label="状态">
|
<el-table-column prop="task_status" label="状态">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<div v-if="scope.row.task_status == 5 && scope.row.task_uuid">
|
<div v-if="scope.row.task_status == 5 && scope.row.task_uuid">
|
||||||
<el-dropdown trigger="click" @command="(e) => workCommand(scope.$index, e)">
|
<el-dropdown trigger="click" @command="(e) => workCommand(scope.row, e)">
|
||||||
<div class="el-dropdown-link flex_box work_status_box">
|
<div class="el-dropdown-link flex_box work_status_box">
|
||||||
<div>{{ statusList[scope.row.task_status] }}</div>
|
<div>{{ statusList[scope.row.task_status] }}</div>
|
||||||
<i class="el-icon-caret-bottom"></i>
|
<i class="el-icon-caret-bottom"></i>
|
||||||
@@ -929,25 +929,25 @@ export default {
|
|||||||
},
|
},
|
||||||
// 新建作业
|
// 新建作业
|
||||||
showWork() {
|
showWork() {
|
||||||
if (!that.workStatus) {
|
// if (!that.workStatus) {
|
||||||
that.$message({
|
// that.$message({
|
||||||
message: '请先连接服务',
|
// message: '请先连接服务',
|
||||||
type: 'warning'
|
// type: 'warning'
|
||||||
})
|
// })
|
||||||
return
|
// return
|
||||||
}
|
// }
|
||||||
if (that.printer_info.is_set_cddev == 1) {
|
// if (that.printer_info.is_set_cddev == 1) {
|
||||||
that.$confirm('上下光驱未设置,请前往设置', '温馨提示', {
|
// that.$confirm('上下光驱未设置,请前往设置', '温馨提示', {
|
||||||
confirmButtonText: '确定',
|
// confirmButtonText: '确定',
|
||||||
cancelButtonText: '取消',
|
// cancelButtonText: '取消',
|
||||||
type: 'warning'
|
// type: 'warning'
|
||||||
}).then(() => {
|
// }).then(() => {
|
||||||
that.goSet('/manage?type=cddev')
|
// that.goSet('/manage?type=cddev')
|
||||||
}).catch(() => {
|
// }).catch(() => {
|
||||||
|
|
||||||
});
|
// });
|
||||||
return
|
// return
|
||||||
}
|
// }
|
||||||
that.isNew = true
|
that.isNew = true
|
||||||
that.workShow = true
|
that.workShow = true
|
||||||
that.$nextTick(() => {
|
that.$nextTick(() => {
|
||||||
@@ -1006,22 +1006,22 @@ export default {
|
|||||||
that.showAll = !that.showAll
|
that.showAll = !that.showAll
|
||||||
},
|
},
|
||||||
// 下拉操作
|
// 下拉操作
|
||||||
workCommand(index, e) {
|
workCommand(row, e) {
|
||||||
if (e === 'retry') {
|
if (e === 'retry') {
|
||||||
that.workRetry(index)
|
that.workRetry(row)
|
||||||
}
|
}
|
||||||
if (e === 'cancel') {
|
if (e === 'cancel') {
|
||||||
that.workCancel(index)
|
that.workCancel(row)
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
// 作业重试
|
// 作业重试
|
||||||
workRetry(e) {
|
workRetry(row) {
|
||||||
that.$store
|
that.$store
|
||||||
.dispatch('chat/websocketsend', {
|
.dispatch('chat/websocketsend', {
|
||||||
req_name: 'retry_task',
|
req_name: 'retry_task',
|
||||||
req_type: 1,
|
req_type: 1,
|
||||||
req_info: {
|
req_info: {
|
||||||
task_uuid: that.task_list[e].task_uuid
|
task_uuid: row.task_uuid
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
@@ -1029,9 +1029,9 @@ export default {
|
|||||||
message: '重试成功',
|
message: '重试成功',
|
||||||
type: 'success'
|
type: 'success'
|
||||||
})
|
})
|
||||||
that.task_list[e].task_status = 1
|
row.task_status = 1
|
||||||
if (that.task_list[e].ass_task && that.task_list[e].ass_task.length > 0) {
|
if (row.ass_task && row.ass_task.length > 0) {
|
||||||
that.task_list[e].ass_task.forEach((item) => {
|
row.ass_task.forEach((item) => {
|
||||||
item.task_status = 1
|
item.task_status = 1
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@@ -1113,13 +1113,17 @@ $red: #ff0000;
|
|||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
padding: 0 16px;
|
padding: 0 16px;
|
||||||
height: 40px;
|
height: 40px;
|
||||||
background: rgba(0, 195, 37, 0.12);
|
border: 2px solid #999;
|
||||||
border: 2px solid rgba(0, 195, 37, 0.32);
|
color: #333;
|
||||||
border-radius: 6px;
|
border-radius: 6px;
|
||||||
margin-right: 16px;
|
margin-right: 16px;
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
font-size: 18px;
|
font-size: 18px;
|
||||||
color: #00c325;
|
&:hover {
|
||||||
|
background: rgba(0, 195, 37, 0.12);
|
||||||
|
border: 2px solid rgba(0, 195, 37, 0.32);
|
||||||
|
color: #00c325;
|
||||||
|
}
|
||||||
img {
|
img {
|
||||||
width: 18px;
|
width: 18px;
|
||||||
height: 18px;
|
height: 18px;
|
||||||
@@ -1412,9 +1416,11 @@ $red: #ff0000;
|
|||||||
.device_run_input {
|
.device_run_input {
|
||||||
width: calc(100% - 140px);
|
width: calc(100% - 140px);
|
||||||
height: 44px;
|
height: 44px;
|
||||||
border: 2px solid #00bcc3;
|
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
border-radius: 6px 0 0 6px;
|
border-radius: 6px 0 0 6px;
|
||||||
|
border-style: solid;
|
||||||
|
border-width: 1px 0 1px 1px;
|
||||||
|
border-color: #999;
|
||||||
.el-select {
|
.el-select {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
padding-left: 10px;
|
padding-left: 10px;
|
||||||
@@ -1441,12 +1447,20 @@ $red: #ff0000;
|
|||||||
.device_run_btn {
|
.device_run_btn {
|
||||||
width: 140px;
|
width: 140px;
|
||||||
height: 44px;
|
height: 44px;
|
||||||
background: #00bcc3;
|
background: transparent;
|
||||||
|
border-style: solid;
|
||||||
|
border-width: 1px;
|
||||||
|
border-color: #999;
|
||||||
border-radius: 0px 6px 6px 0px;
|
border-radius: 0px 6px 6px 0px;
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
font-size: 19px;
|
font-size: 19px;
|
||||||
margin: 0;
|
margin: 0;
|
||||||
color: #ffffff;
|
color: #333;
|
||||||
|
&:hover {
|
||||||
|
background: rgba(0, 195, 37, 0.12);
|
||||||
|
border: 2px solid rgba(0, 195, 37, 0.32);
|
||||||
|
color: #00c325;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1544,7 +1558,7 @@ $red: #ff0000;
|
|||||||
.notice_all {
|
.notice_all {
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
font-size: 19px;
|
font-size: 19px;
|
||||||
color: #00c325;
|
color: #333;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
img {
|
img {
|
||||||
width: 28px;
|
width: 28px;
|
||||||
|
|||||||
@@ -742,15 +742,19 @@ export default {
|
|||||||
width: 250px;
|
width: 250px;
|
||||||
height: 42px;
|
height: 42px;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
background: rgba(0, 195, 37, 0.12);
|
color: #333;
|
||||||
|
border: 1px solid #999;
|
||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
border: 1px solid rgba(0, 195, 37, 0.32);
|
|
||||||
line-height: 40px;
|
line-height: 40px;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
font-size: 19px;
|
font-size: 19px;
|
||||||
color: #00c325;
|
|
||||||
margin: 6px;
|
margin: 6px;
|
||||||
|
&:hover {
|
||||||
|
background: rgba(0, 195, 37, 0.12);
|
||||||
|
border: 1px solid rgba(0, 195, 37, 0.32);
|
||||||
|
color: #00c325;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
.form_input {
|
.form_input {
|
||||||
@@ -758,13 +762,14 @@ export default {
|
|||||||
height: 42px;
|
height: 42px;
|
||||||
background: #ffffff;
|
background: #ffffff;
|
||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
border: 1px solid #98e8a6;
|
border: 1px solid #999;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
::v-deep {
|
::v-deep {
|
||||||
.el-input-group__append {
|
.el-input-group__append {
|
||||||
font-size: 16px;
|
font-size: 16px;
|
||||||
color: #000;
|
color: #000;
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
|
border-radius: 0;
|
||||||
}
|
}
|
||||||
.el-input__inner {
|
.el-input__inner {
|
||||||
width: 360px;
|
width: 360px;
|
||||||
@@ -787,8 +792,16 @@ export default {
|
|||||||
height: 40px;
|
height: 40px;
|
||||||
border: none;
|
border: none;
|
||||||
padding: 0;
|
padding: 0;
|
||||||
background: #00c325;
|
background: transparent;
|
||||||
border-radius: 0px 4px 4px 0px;
|
border-radius: 0px 4px 4px 0px;
|
||||||
|
color: #333;
|
||||||
|
font-weight: bold;
|
||||||
|
font-size: 16px;
|
||||||
|
&:hover {
|
||||||
|
background: #00c325;
|
||||||
|
color: #fff;
|
||||||
|
border: none;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -816,7 +829,7 @@ export default {
|
|||||||
line-height: 24px;
|
line-height: 24px;
|
||||||
}
|
}
|
||||||
.el-checkbox__input.is-checked + .el-checkbox__label {
|
.el-checkbox__input.is-checked + .el-checkbox__label {
|
||||||
color: #00c325;
|
color: #333;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
.form_select {
|
.form_select {
|
||||||
|
|||||||
@@ -333,12 +333,17 @@ export default {
|
|||||||
.footer_submit {
|
.footer_submit {
|
||||||
width: 166px;
|
width: 166px;
|
||||||
height: 45px;
|
height: 45px;
|
||||||
background: #00C325;
|
background: transparent;
|
||||||
|
border: 1px solid #999;
|
||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
font-size: 19px;
|
font-size: 19px;
|
||||||
color: #FFFFFF;
|
color: #333;
|
||||||
padding: 0;
|
padding: 0;
|
||||||
|
&:hover {
|
||||||
|
background: #00C325;
|
||||||
|
color: #FFFFFF;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user