Browse Source

情报板样式

wangqin
lau572 11 months ago
parent
commit
d08e770ff4
  1. 10
      ruoyi-ui/src/views/information/board/addinfo.vue
  2. 29
      ruoyi-ui/src/views/information/board/editInfo.vue
  3. 9
      ruoyi-ui/src/views/information/board/index.vue

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

@ -1,7 +1,7 @@
<template> <template>
<div class="container infoBoardDialog"> <div class="container infoBoardDialog">
<!-- 添加信息弹窗 --> <!-- 添加信息弹窗 -->
<el-dialog title="新增" :visible.sync="dialogVisible" width="42%" :before-close="handleClose" :close-on-click-modal="false"> <el-dialog title="新增" :visible.sync="dialogVisible" width="43%" :before-close="handleClose" :close-on-click-modal="false">
<div class="dialogStyleBox"> <div class="dialogStyleBox">
<div class="dialogLine"></div> <div class="dialogLine"></div>
<div class="dialogCloseButton"></div> <div class="dialogCloseButton"></div>
@ -564,7 +564,7 @@ export default {
if (this.isAdd) { if (this.isAdd) {
if (this.infoType == 1) { if (this.infoType == 1) {
// //
this.dataForm.STAY = Number(this.dataForm.STAY) * 100 this.dataForm.STAY = Number(this.dataForm.STAY) * 10
this.$emit('addInfo', this.dataForm) this.$emit('addInfo', this.dataForm)
} else { } else {
// //
@ -579,7 +579,7 @@ export default {
inScreenMode: this.dataForm.ACTION, inScreenMode: this.dataForm.ACTION,
remark: '', remark: '',
screenSize: this.dataForm.screenSize, screenSize: this.dataForm.screenSize,
stopTime: Number(this.dataForm.STAY) * 100, stopTime: Number(this.dataForm.STAY) * 10,
vmsType: '', vmsType: '',
width: '' width: ''
} }
@ -641,7 +641,7 @@ export default {
if (this.isAdd) { if (this.isAdd) {
if (this.infoType == 1) { if (this.infoType == 1) {
// //
this.dataForm.STAY = Number(this.dataForm.STAY) * 100 this.dataForm.STAY = Number(this.dataForm.STAY) * 10
this.$emit('addInfo', this.dataForm) this.$emit('addInfo', this.dataForm)
} else { } else {
// //
@ -656,7 +656,7 @@ export default {
inScreenMode: this.dataForm.ACTION, inScreenMode: this.dataForm.ACTION,
remark: '', remark: '',
screenSize: this.dataForm.screenSize, screenSize: this.dataForm.screenSize,
stopTime: Number(this.dataForm.STAY) * 100, stopTime: Number(this.dataForm.STAY) * 10,
vmsType: '', vmsType: '',
width: '' width: ''
} }

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

@ -1,16 +1,17 @@
<template> <template>
<div class="container infoBoardDialog"> <div class="container infoBoardDialog">
<!-- 添加信息弹窗 --> <!-- 添加信息弹窗 -->
<el-dialog title="修改" :visible.sync="dialogVisible" width="42%" :before-close="closeDialog" :close-on-click-modal="false"> <el-dialog title="修改" :visible.sync="dialogVisible" width="43%" :before-close="closeDialog" :close-on-click-modal="false">
<div class="dialogStyleBox"> <div class="dialogStyleBox">
<div class="dialogLine"></div> <div class="dialogLine"></div>
<div class="dialogCloseButton"></div> <div class="dialogCloseButton"></div>
</div> </div>
<el-card class="box-card"> <el-card class="box-card" >
<div class="blackBoard1" v-on:ondragenter="ondragenter" v-on:drop="faceDrop" v-on:dragover="allowDrop" :style="{ <div class="blackBoard1" v-on:ondragenter="ondragenter" v-on:drop="faceDrop" v-on:dragover="allowDrop" :style="{
width: getDevicePixel(boardWidth, 0), width: getDevicePixel(boardWidth, 0),
height: getDevicePixel(boardHeight, 1), height: getDevicePixel(boardHeight, 1),
position: 'relative', position: 'relative',
display:'flex', display:'flex',
'align-items': getTextAlign(dataForm.formatStyle), 'align-items': getTextAlign(dataForm.formatStyle),
'justify-content': getTextAlign(dataForm.formatStyle) 'justify-content': getTextAlign(dataForm.formatStyle)
@ -18,7 +19,7 @@
<span class="textBoard1 boardTextStyle" :style="{ <span class="textBoard1 boardTextStyle" :style="{
color: getColorStyle(dataForm.COLOR), color: getColorStyle(dataForm.COLOR),
fontSize: getFontSize(dataForm.FONT_SIZE), fontSize: getFontSize(dataForm.FONT_SIZE),
fontFamily: dataForm.FONT, fontFamily: getFontStyle(dataForm.FONT),
zIndex: '1000', zIndex: '1000',
position:'relative', position:'relative',
/*left: getCoordinate(dataForm.COORDINATE.substring(0, 3), 0), /*left: getCoordinate(dataForm.COORDINATE.substring(0, 3), 0),
@ -485,7 +486,7 @@ export default {
console.log(this.dataForm, 'this.dataForm') console.log(this.dataForm, 'this.dataForm')
// this.dataForm.FONT = this.getFont(this.boardEmitItem.FONT) // this.dataForm.FONT = this.getFont(this.boardEmitItem.FONT)
this.dataForm.CONTENT = JSON.parse(JSON.stringify(this.boardEmitItem.CONTENT.replace('<br>', '\n').replace(/ /g, ' ').replace('<r><n>', '\n'))) this.dataForm.CONTENT = JSON.parse(JSON.stringify(this.boardEmitItem.CONTENT.replace('<br>', '\n').replace(/ /g, ' ').replace('<r><n>', '\n')))
this.dataForm.STAY = JSON.parse(JSON.stringify(Number(this.boardEmitItem.STAY) / 100)) this.dataForm.STAY = JSON.parse(JSON.stringify(Number(this.boardEmitItem.STAY) / 10))
this.getFontSizeList() this.getFontSizeList()
}, },
getColorValue(color) { getColorValue(color) {
@ -603,7 +604,7 @@ export default {
this.loading = false this.loading = false
this.isAdd = false this.isAdd = false
if (this.dataForm.type == 1) { if (this.dataForm.type == 1) {
this.dataForm.STAY = Number(this.dataForm.STAY) * 100 this.dataForm.STAY = Number(this.dataForm.STAY) * 10
this.$emit('receiveForm', this.dataForm) this.$emit('receiveForm', this.dataForm)
console.log(this.dataForm, 'this.dataForm修改后给父组件传表单内容') console.log(this.dataForm, 'this.dataForm修改后给父组件传表单内容')
} else { } else {
@ -641,7 +642,7 @@ export default {
remark: '', remark: '',
screenSize: this.dataForm.screenSize, screenSize: this.dataForm.screenSize,
searchValue: null, searchValue: null,
stopTime: Number(this.dataForm.STAY) * 100, stopTime: Number(this.dataForm.STAY) * 10,
tcontents: null, tcontents: null,
templateType: null, templateType: null,
updateBy: null, updateBy: null,
@ -690,7 +691,7 @@ export default {
this.loading = false this.loading = false
this.isAdd = false this.isAdd = false
if (this.dataForm.type == 1) { if (this.dataForm.type == 1) {
this.dataForm.STAY = Number(this.dataForm.STAY) * 100 this.dataForm.STAY = Number(this.dataForm.STAY) * 10
this.$emit('receiveForm', this.dataForm) this.$emit('receiveForm', this.dataForm)
console.log(this.dataForm, 'this.dataForm修改后给父组件传表单内容') console.log(this.dataForm, 'this.dataForm修改后给父组件传表单内容')
} else { } else {
@ -728,7 +729,7 @@ export default {
remark: '', remark: '',
screenSize: this.dataForm.screenSize, screenSize: this.dataForm.screenSize,
searchValue: null, searchValue: null,
stopTime: Number(this.dataForm.STAY) * 100, stopTime: Number(this.dataForm.STAY) * 10,
tcontents: null, tcontents: null,
templateType: null, templateType: null,
updateBy: null, updateBy: null,
@ -769,13 +770,13 @@ export default {
getFontStyle(font) { getFontStyle(font) {
if (font == '宋体') { if (font == '宋体') {
return 'Simsun' return 'Simsun'
} else if (font == '黑体') { } else if (font == '黑体' || font == '1') {
return 'SimHei' return 'SimHei'
} else if (font == '楷体') { } else if (font == '楷体' || font == '2') {
return 'KaiTi' return 'KaiTi'
} else if (font == '仿宋') { } else if (font == '仿宋' || font == '4') {
return 'FangSong' return 'FangSong'
} else if (font == '隶书') { } else if (font == '隶书' || font == '5') {
return 'LiSu' return 'LiSu'
} }
}, },
@ -804,8 +805,8 @@ export default {
return devicePixel + 'px' return devicePixel + 'px'
} }
} else if (num == 1) { } else if (num == 1) {
if (devicePixel > 128) { if (devicePixel > 160) {
return 128 + 'px' return 160 + 'px'
} else { } else {
return devicePixel + 'px' return devicePixel + 'px'
} }

9
ruoyi-ui/src/views/information/board/index.vue

@ -1190,16 +1190,16 @@ export default {
console.log('发布消息,播放文件-----------------------------') console.log('发布消息,播放文件-----------------------------')
console.log(res) console.log(res)
}).catch(()=>{ }).catch(()=>{
this.$modal.msgError("发布失败,请重试"); this.$modal.msgWarning("发布失败,请重试");
}) })
} }
}).catch(()=>{ }).catch(()=>{
this.$modal.msgError("发布失败,请重试"); this.$modal.msgWarning("发布失败,请重试");
}) })
} }
}).catch(()=>{ }).catch(()=>{
this.$modal.msgError("发布失败,请重试"); this.$modal.msgWarning("发布失败,请重试");
}) })
loading.close() loading.close()
}).catch(() => { }).catch(() => {
@ -1347,6 +1347,7 @@ export default {
item.FONT_SIZE = item.fontSize + 'px' item.FONT_SIZE = item.fontSize + 'px'
item.ID = i item.ID = i
item.FONT = item.font item.FONT = item.font
item.STAY = item.playbackDuration
item.COORDINATE = this.covering(item.xCoordinate) + this.covering(item.yCoordinate) item.COORDINATE = this.covering(item.xCoordinate) + this.covering(item.yCoordinate)
item.screenSize = item.displayAreaWidth + '*' + item.displayAreaHeight item.screenSize = item.displayAreaWidth + '*' + item.displayAreaHeight
item.CONTENT = item.textContent.replaceAll('\\,',',') item.CONTENT = item.textContent.replaceAll('\\,',',')
@ -1366,7 +1367,7 @@ export default {
this.submitButton = false this.submitButton = false
}) })
.catch(e => { .catch(e => {
this.$modal.msgError("回读失败,请重试"); this.$modal.msgWarning("回读失败,请重试");
this.loading = false this.loading = false
this.submitButton = false this.submitButton = false
}) })

Loading…
Cancel
Save