语法检查格式修复

merge-requests/1/head
张鑫 5 years ago
parent 42db7e0a83
commit 99d456ac9d

@ -51,7 +51,7 @@
</template>
<script>
import Model from "./model.vue"
import Model from "./model.vue"
export default {
name: "historyMonitoring",
components: {

@ -63,40 +63,40 @@
}
</style>
<script>
export default {
props: ['visible', 'vid'],
watch: {
//visibleisShowprops
visible: function (newVal) {
this.isShow = newVal; //newValvisible
// newVal && this.showConfirm(); //newValshowConfirm
},
vid: function (newVal) {
console.log(newVal)
console.log(1111111)
this.video = newVal
this.$nextTick(() => { //this.$nextTick
export default {
props: ['visible', 'vid'],
watch: {
//visibleisShowprops
visible: function (newVal) {
this.isShow = newVal; //newValvisible
// newVal && this.showConfirm(); //newValshowConfirm
},
vid: function (newVal) {
console.log(newVal)
console.log(1111111)
this.video = newVal
this.$nextTick(() => { //this.$nextTick
})
})
},
},
data() {
return {
isShow: false,
confirmLoading: false,
video: '',
};
},
mounted() {
console.log('mounted执行了')
},
data() {
return {
isShow: false,
confirmLoading: false,
video: '',
};
},
mounted() {
console.log('mounted执行了')
},
methods: {
handleCancel() {
this.$emit('close', false, '')
},
methods: {
handleCancel() {
this.$emit('close', false, '')
},
},
};
},
};
</script>

@ -19,109 +19,109 @@
<script>
const columns = [
{
title: '序号',
// dataIndex: 'id',
customRender: (text, record, index) => {
return (
(1 - 1) * 10 + index + 1
)
const columns = [
{
title: '序号',
// dataIndex: 'id',
customRender: (text, record, index) => {
return (
(1 - 1) * 10 + index + 1
)
}
},
{
title: 'PLCID',
dataIndex: 'plcId',
},
{
title: '状态',
dataIndex: 'status',
scopedSlots: {customRender: 'status'}
},
{
title: '异常时间',
dataIndex: 'time',
},
{
title: '操作',
dataIndex: 'action',
scopedSlots: {customRender: 'action'}
},
];
export default {
data() {
return {
pageNum: 1,
pageSize: 10,
data: [],
pagination: {
total: 0,
current: 1,
defaultPageSize: 10, //
showTotal: total => `${total} 条数据`, //
showSizeChanger: true, //
pageSizeOptions: ['10', '20', '30'],
onShowSizeChange: (current, pageSize) => this.pageSize = pageSize //
},
loading: false,
columns,
visible: false,
modelType: '',
modelData: [],
};
},
computed: {},
mounted() {
this.handleGetCameraIoList()
},
methods: {
handleGetCameraIoList(pagination) {
console.log(pagination)
if (pagination) {
this.pagination.current = pagination.current;
this.pagination.pageSize = pagination.pageSize;
this.pageNum = pagination.current;
this.pageSize = pagination.pageSize;
}
this.request();
},
{
title: 'PLCID',
dataIndex: 'plcId',
},
{
title: '状态',
dataIndex: 'status',
scopedSlots: {customRender: 'status'}
},
{
title: '异常时间',
dataIndex: 'time',
},
{
title: '操作',
dataIndex: 'action',
scopedSlots: {customRender: 'action'}
},
];
export default {
data() {
return {
pageNum: 1,
pageSize: 10,
data: [],
pagination: {
total: 0,
current: 1,
defaultPageSize: 10, //
showTotal: total => `${total} 条数据`, //
showSizeChanger: true, //
pageSizeOptions: ['10', '20', '30'],
onShowSizeChange: (current, pageSize) => this.pageSize = pageSize //
},
loading: false,
columns,
visible: false,
modelType: '',
modelData: [],
};
},
computed: {},
mounted() {
this.handleGetCameraIoList()
},
methods: {
handleGetCameraIoList(pagination) {
console.log(pagination)
if (pagination) {
this.pagination.current = pagination.current;
this.pagination.pageSize = pagination.pageSize;
this.pageNum = pagination.current;
this.pageSize = pagination.pageSize;
request() {
this.$api.httpApi.disPlcList({
data: {
page: this.pageNum,
size: this.pageSize,
}
this.request();
},
request() {
this.$api.httpApi.disPlcList({
data: {
page: this.pageNum,
size: this.pageSize,
}
}).then(res => {
const pagination = {...this.pagination};
pagination.total = res.data.total;
this.data = res.data;
this.pagination = pagination;
res.data.list.forEach((value, index) => {
value.pageNumber = this.pagination.current
});
}).catch(err => {
}).then(res => {
const pagination = {...this.pagination};
pagination.total = res.data.total;
this.data = res.data;
this.pagination = pagination;
res.data.list.forEach((value, index) => {
value.pageNumber = this.pagination.current
});
},
reconnection(data) {
console.log(data.streetId)
var id = data.streetId
this.$axios.get('/plc/tcp', {
params: {id: id}
}).then(res => {
if (res.code == 200) {
this.$message.success('连接成功');
this.handleGetStreetList()
} else {
this.$message.error('连接失败');
}
}).catch(err => {
}).catch(err => {
})
}
});
},
components: {}
};
reconnection(data) {
console.log(data.streetId)
var id = data.streetId
this.$axios.get('/plc/tcp', {
params: {id: id}
}).then(res => {
if (res.code == 200) {
this.$message.success('连接成功');
this.handleGetStreetList()
} else {
this.$message.error('连接失败');
}
}).catch(err => {
})
}
},
components: {}
};
</script>
<style lang="scss" scoped>
.button-box {

Loading…
Cancel
Save