调整综合监控

This commit is contained in:
zyy 2020-10-15 15:28:23 +08:00
parent 78dd2f3d26
commit 114516abb8
3 changed files with 22 additions and 2 deletions

View File

@ -270,7 +270,7 @@ deviceRender[deviceType.ArcStatus] = {
deviceRender[deviceType.IscsButton] = {
_type: deviceType.IscsButton,
zlevel: 1,
z: 4
z: 5
};
/** 状态表 */
deviceRender[deviceType.StateTable] = {

View File

@ -27,6 +27,7 @@ export default class Button extends Group {
this.buttonText = new Text({
zlevel: model.zlevel,
z: model.z + 1,
z2: model.z2 || 0,
style: {
x: 0,
y: 0,
@ -46,6 +47,7 @@ export default class Button extends Group {
this.imageButton = new Image({
zlevel: model.zlevel,
z: model.z,
z2: model.z2 || 0,
style: {
x: textRect.x - model.levelPadding,
y: textRect.y - model.verticalPadding,
@ -61,6 +63,7 @@ export default class Button extends Group {
this.textButtonRect = new Rect({
zlevel: model.zlevel,
z: model.z,
z2: model.z2 || 0,
shape: {
x: textRect.x - model.levelPadding,
y: textRect.y - model.verticalPadding,
@ -75,6 +78,7 @@ export default class Button extends Group {
this.lineLeftTop = new Polyline({
zlevel: model.zlevel,
z: model.z,
z2: model.z2 || 0,
draggable: false,
shape: {
points: [
@ -91,6 +95,7 @@ export default class Button extends Group {
this.lineBottomRight = new Polyline({
zlevel: model.zlevel,
z: model.z,
z2: model.z2 || 0,
draggable: false,
shape: {
points: [
@ -111,6 +116,7 @@ export default class Button extends Group {
this.textButtonRectSmall = new Rect({
zlevel: model.zlevel,
z: model.z,
z2: model.z2 || 0,
shape: {
x: textRect.x - model.levelPadding + 6,
y: textRect.y - model.verticalPadding + 6,
@ -145,7 +151,6 @@ export default class Button extends Group {
this.add(this.grouper);
this.on('mouseout', (e) => { this.buttonText && this.buttonText.setStyle({textFill: model.textColor || '#FFF'}); });
this.on('mouseover', (e) => { this.buttonText && this.buttonText.setStyle({textFill: model.textColorActive || '#000'}); });
}
setModel(dx, dy) {
this.model.point.x += dx;

View File

@ -1,6 +1,9 @@
<template>
<div style="overflow-y: scroll;height: calc(100% - 46px); width: 100%;">
<el-form ref="form" :rules="rules" :model="form" label-width="100px" style="width: 100%;padding: 10px 50px;">
<el-form-item label="图层:" prop="z2">
<el-input-number v-model="form.z2" controls-position="right" size="small" />
</el-form-item>
<el-form-item v-if="isUpdate" label="按钮编号:" prop="code">
<el-input v-model="form.code" size="small" :disabled="true" />
</el-form-item>
@ -19,6 +22,12 @@
<el-form-item label="选中文字颜色:" prop="textColorActive">
<el-color-picker v-model="form.textColorActive" size="small" />
</el-form-item>
<!-- <el-form-item label="背景颜色:" prop="textColor">
<el-color-picker v-model="form.fillColor" size="small" />
</el-form-item>
<el-form-item label="选中背景颜色:" prop="textColor">
<el-color-picker v-model="form.fillColorActive" size="small" />
</el-form-item> -->
<el-form-item label="文字大小:" prop="fontSize">
<el-input-number v-model="form.fontSize" size="small" controls-position="right" :min="1" />
</el-form-item>
@ -72,6 +81,7 @@ export default {
],
form: {
code: '',
z2: 0,
levelPadding: 10,
verticalPadding: 5,
fontSize: 10,
@ -80,6 +90,8 @@ export default {
context: '',
function: '',
textColor: '',
// fillColor: '#D1C2C2',
// fillColorActive: '#847b7b',
textColorActive: '#000'
},
rules: {
@ -105,6 +117,7 @@ export default {
this.showDeleteButton = true;
this.isUpdate = true;
this.form.code = model.code;
this.form.z2 = model.z2;
this.form.levelPadding = model.levelPadding;
this.form.verticalPadding = model.verticalPadding;
this.form.x = model.point.x;
@ -149,6 +162,7 @@ export default {
},
code: this.isUpdate ? this.form.code : getUID('IscsButton', this.iscs.iscsButtonList),
_type: 'IscsButton',
z2: this.form.z2,
levelPadding: this.form.levelPadding,
verticalPadding: this.form.verticalPadding,
context: this.form.context,
@ -186,6 +200,7 @@ export default {
this.showDeleteButton = false;
this.form = {
code: '',
z2: '',
levelPadding: 10,
verticalPadding: 2,
fontSize: 10,