lau572 11 months ago
parent
commit
7826b489fd
  1. 14
      ruoyi-ui/src/views/information/board/addinfo.vue
  2. 11
      ruoyi-ui/src/views/information/board/editInfo.vue

14
ruoyi-ui/src/views/information/board/addinfo.vue

@ -12,7 +12,7 @@
height: boardHeight + 'px',
position: 'relative',
lineHeight:boardHeight + 'px',
textAlign: getTextAlign(dataForm.formatStyle)
}" class="blackBoard2">
@ -426,7 +426,7 @@ export default {
STATE: 'true',
STAY: '5',
screenSize: devicePixel,
formatStyle :'2'
formatStyle: '2'
}
this.content = '请输入内容'
} else {
@ -442,7 +442,7 @@ export default {
getFontSizeList(type) {
this.getDicts('iot_device_font_size').then(res => {
this.fontSizeOpt = res.data
this.dataForm.FONT_SIZE = res.data[3].dictValue
this.dataForm.FONT_SIZE = res.data[1].dictValue
if (type) {
this.alignment(2)
}
@ -663,7 +663,7 @@ export default {
fontSize: this.dataForm.FONT_SIZE.substring(0, 2),
fontSpacing: this.dataForm.SPEED,
fontType: this.getFontStyle(this.dataForm.FONT),
formatStyle : this.dataForm.formatStyle
formatStyle: this.dataForm.formatStyle
})
// this.$emit("addInfoMode", this.dataForm);
addTemplate(params1, method).then(data => {
@ -734,9 +734,9 @@ export default {
}
},
getTextAlign(font) {
if (font == '0'){
if (font == '0') {
return 'left'
} else if (font == '1'){
} else if (font == '1') {
return 'right'
} else {
return 'center'
@ -807,7 +807,7 @@ export default {
var textTop = this.addZero(textBoard2[0].offsetTop)
this.dataForm.COORDINATE = textLeft + textTop
debugger
if (alignmentNum != undefined){
if (alignmentNum != undefined) {
this.dataForm.formatStyle = alignmentNum
}
// console.log(this.dataForm.COORDINATE, "this.dataForm.COORDINATE");

11
ruoyi-ui/src/views/information/board/editInfo.vue

@ -11,8 +11,9 @@
width: getDevicePixel(boardWidth, 0),
height: getDevicePixel(boardHeight, 1),
position: 'relative',
lineHeight:boardHeight + 'px',
textAlign: getTextAlign(dataForm.formatStyle)
display:'flex',
'align-items': getTextAlign(dataForm.formatStyle),
'justify-content': getTextAlign(dataForm.formatStyle)
}">
<span class="textBoard1 boardTextStyle" :style="{
color: getColorStyle(dataForm.COLOR),
@ -655,7 +656,7 @@ export default {
coordinate: this.dataForm.COORDINATE,
id: this.dataForm.tcontentsId,
templateId: this.dataForm.id,
formatStyle: this.dataForm.formatStyle,
formatStyle: this.dataForm.formatStyle
})
var params = {
@ -826,9 +827,9 @@ export default {
},
getTextAlign(font) {
if (font == '0'){
if (font == '0') {
return 'left'
} else if (font == '1'){
} else if (font == '1') {
return 'right'
} else {
return 'center'

Loading…
Cancel
Save