Browse Source

情报板模板接口

wangqin
lau572 11 months ago
parent
commit
b565a39d06
  1. 14
      ruoyi-ui/src/views/information/board/addinfo.vue
  2. 14
      ruoyi-ui/src/views/information/board/editInfo.vue
  3. 492
      ruoyi-ui/src/views/information/board/index.vue

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

@ -721,16 +721,16 @@ export default {
}
},
getColorStyle(font) {
if (font == '黄色') {
return 'yellow'
} else if (font == '红色') {
return 'red'
if (font == '黄色' || font == 'yellow') {
return '#FFFF00'
} else if (font == '红色' || font == 'red') {
return '#FF0000'
} else if (font == '绿色' || font == 'GreenYellow') {
return '#00FF00'
} else if (font == '蓝色') {
return 'blue'
} else if (font == '蓝色' || font == 'blue') {
return '#0000FF'
} else {
return font
return '#' + font
}
},
getTextAlign(font) {

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

@ -774,16 +774,16 @@ export default {
}
},
getColorStyle(font) {
if (font == '黄色') {
return 'yellow'
} else if (font == '红色') {
return 'red'
if (font == '黄色' || font == 'yellow') {
return '#FFFF00'
} else if (font == '红色' || font == 'red') {
return '#FF0000'
} else if (font == '绿色' || font == 'GreenYellow') {
return '#00FF00'
} else if (font == '蓝色') {
return 'blue'
} else if (font == '蓝色' || font == 'blue') {
return '#0000FF'
} else {
return font
return '#' + font
}
},
closeDialog() {

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

@ -391,8 +391,8 @@ export default {
updateTime: null,
remark: null,
params: {},
deviceId: 1055550312,
deviceName: '门架式可变信息标志YK16+268',
deviceId: 65,
deviceName: '门架式可变信息标志K103+900',
brandId: 4,
iotBoardBrandName: {
brandId: 4,
@ -419,7 +419,7 @@ export default {
installDate: '2022-12-14T16:06:03.000+08:00',
maintainId: 2,
collarAgencyId: 555503,
pileNumber: 'ZK134+587',
pileNumber: 'K103+900',
manageAgencyId: 'YG11002',
producteDate: null,
repairDate: null,
@ -431,7 +431,7 @@ export default {
localInfo: 36,
routeNumber: null,
routeName: null,
deviceIp: '10.7.179.244',
deviceIp: '10.0.31.111',
devicePort: null,
devicePixel: '768*64',
userName: null,
@ -521,317 +521,7 @@ export default {
updateTime: null,
remark: null,
params: {},
deviceId: 1055550306,
deviceName: '雨棚可变信息标志YK16+970',
brandId: 4,
iotBoardBrandName: {
brandId: 4,
brandName: '光电比特'
},
routeId: 17,
routeDirection: '菏泽方向',
deviceMarkingName: null,
deviceTypeId: 202010001,
deviceTypeNumber: 202010004,
deviceModelId: null,
factoryLibrary: null,
userUnitId: 555503,
operatorId: null,
longitude: null,
latitude: null,
firmId: 18,
purchaseDate: '2022-12-14T16:06:03.000+08:00',
warrantyYears: null,
unitPrice: null,
runStatus: 1,
tunnelId: 'JQ-JiNan-WenZuBei-MJY',
deviceStatus: '1',
installDate: '2022-12-14T16:06:03.000+08:00',
maintainId: 2,
collarAgencyId: 555503,
pileNumber: 'YK133+825',
manageAgencyId: 'YG11002',
producteDate: null,
repairDate: null,
operateDate: null,
serviceLife: null,
storageDate: null,
isMonitor: 1,
isConfig: 1,
localInfo: 16,
routeNumber: null,
routeName: null,
deviceIp: '10.7.180.84',
devicePort: null,
devicePixel: '480*48',
userName: null,
passWord: null,
protocolName: null,
deviceTypeIds: null,
lUserID: null,
lAlarmHandle: null,
lUserIDStr: null,
lAlarmHandleStr: null,
eqDirection: null,
iotDeviceType: null
},
{
searchValue: null,
createBy: null,
createTime: null,
updateBy: null,
updateTime: null,
remark: null,
params: {},
deviceId: 1055550307,
deviceName: '雨棚可变信息标志ZK17+013',
brandId: 4,
iotBoardBrandName: {
brandId: 4,
brandName: '光电比特'
},
routeId: 17,
routeDirection: '济南方向',
deviceMarkingName: null,
deviceTypeId: 202010001,
deviceTypeNumber: 202010004,
deviceModelId: null,
factoryLibrary: null,
userUnitId: 555503,
operatorId: null,
longitude: null,
latitude: null,
firmId: 18,
purchaseDate: '2022-12-14T16:06:03.000+08:00',
warrantyYears: null,
unitPrice: null,
runStatus: 1,
tunnelId: 'JQ-JiNan-WenZuBei-MJY',
deviceStatus: '1',
installDate: '2022-12-14T16:06:03.000+08:00',
maintainId: 2,
collarAgencyId: 555503,
pileNumber: 'ZK135+268',
manageAgencyId: 'YG11002',
producteDate: null,
repairDate: null,
operateDate: null,
serviceLife: null,
storageDate: null,
isMonitor: 1,
isConfig: 1,
localInfo: 16,
routeNumber: null,
routeName: null,
deviceIp: '10.7.180.85',
devicePort: null,
devicePixel: '480*48',
userName: null,
passWord: null,
protocolName: null,
deviceTypeIds: null,
lUserID: null,
lAlarmHandle: null,
lUserIDStr: null,
lAlarmHandleStr: null,
eqDirection: null,
iotDeviceType: null
},
{
searchValue: null,
createBy: null,
createTime: null,
updateBy: null,
updateTime: null,
remark: null,
params: {},
deviceId: 1055550308,
deviceName: '雨棚可变信息标志YK17+800',
brandId: 4,
iotBoardBrandName: {
brandId: 4,
brandName: '光电比特'
},
routeId: 17,
routeDirection: '济南方向',
deviceMarkingName: null,
deviceTypeId: 202010001,
deviceTypeNumber: 202010004,
deviceModelId: null,
factoryLibrary: null,
userUnitId: 555503,
operatorId: null,
longitude: null,
latitude: null,
firmId: 18,
purchaseDate: '2022-12-14T16:06:03.000+08:00',
warrantyYears: null,
unitPrice: null,
runStatus: 1,
tunnelId: 'JQ-JiNan-WenZuBei-MJY',
deviceStatus: '1',
installDate: '2022-12-14T16:06:03.000+08:00',
maintainId: 2,
collarAgencyId: 555503,
pileNumber: 'ZK135+568',
manageAgencyId: 'YG11002',
producteDate: null,
repairDate: null,
operateDate: null,
serviceLife: null,
storageDate: null,
isMonitor: 1,
isConfig: 1,
localInfo: 16,
routeNumber: null,
routeName: null,
deviceIp: '10.7.180.86',
devicePort: null,
devicePixel: '480*48',
userName: null,
passWord: null,
protocolName: null,
deviceTypeIds: null,
lUserID: null,
lAlarmHandle: null,
lUserIDStr: null,
lAlarmHandleStr: null,
eqDirection: null,
iotDeviceType: null
},
{
searchValue: null,
createBy: null,
createTime: null,
updateBy: null,
updateTime: null,
remark: null,
params: {},
deviceId: 1055550309,
deviceName: '雨棚可变信息标志ZK17+840',
brandId: 4,
iotBoardBrandName: {
brandId: 4,
brandName: '光电比特'
},
routeId: 17,
routeDirection: '菏泽方向',
deviceMarkingName: null,
deviceTypeId: 202010001,
deviceTypeNumber: 202010004,
deviceModelId: null,
factoryLibrary: null,
userUnitId: 555503,
operatorId: null,
longitude: '117.9554825',
latitude: '36.84254887',
firmId: 18,
purchaseDate: '2022-12-14T16:06:03.000+08:00',
warrantyYears: null,
unitPrice: null,
runStatus: 1,
tunnelId: 'JQ-JiNan-WenZuBei-MJY',
deviceStatus: '1',
installDate: '2022-12-14T16:06:03.000+08:00',
maintainId: 2,
collarAgencyId: 555503,
pileNumber: 'YK134+550',
manageAgencyId: 'YG11002',
producteDate: null,
repairDate: null,
operateDate: null,
serviceLife: null,
storageDate: null,
isMonitor: 1,
isConfig: 1,
localInfo: 16,
routeNumber: null,
routeName: null,
deviceIp: '10.7.181.27',
devicePort: null,
devicePixel: '480*48',
userName: null,
passWord: null,
protocolName: null,
deviceTypeIds: null,
lUserID: null,
lAlarmHandle: null,
lUserIDStr: null,
lAlarmHandleStr: null,
eqDirection: null,
iotDeviceType: null
},
{
searchValue: null,
createBy: null,
createTime: null,
updateBy: null,
updateTime: null,
remark: null,
params: {},
deviceId: 1055550310,
deviceName: '雨棚可变信息标志YK18+630',
brandId: 4,
iotBoardBrandName: {
brandId: 4,
brandName: '光电比特'
},
routeId: 17,
routeDirection: '济南方向',
deviceMarkingName: null,
deviceTypeId: 202010001,
deviceTypeNumber: 202010004,
deviceModelId: null,
factoryLibrary: null,
userUnitId: 555503,
operatorId: null,
longitude: '117.9554825',
latitude: '36.84254887',
firmId: 18,
purchaseDate: '2022-12-14T16:06:03.000+08:00',
warrantyYears: null,
unitPrice: null,
runStatus: 1,
tunnelId: 'JQ-JiNan-WenZuBei-MJY',
deviceStatus: '1',
installDate: '2022-12-14T16:06:03.000+08:00',
maintainId: 2,
collarAgencyId: 555503,
pileNumber: 'ZK134+587',
manageAgencyId: 'YG11002',
producteDate: null,
repairDate: null,
operateDate: null,
serviceLife: null,
storageDate: null,
isMonitor: 1,
isConfig: 1,
localInfo: 16,
routeNumber: null,
routeName: null,
deviceIp: '10.7.181.28',
devicePort: null,
devicePixel: '480*48',
userName: null,
passWord: null,
protocolName: null,
deviceTypeIds: null,
lUserID: null,
lAlarmHandle: null,
lUserIDStr: null,
lAlarmHandleStr: null,
eqDirection: null,
iotDeviceType: null
},
{
searchValue: null,
createBy: null,
createTime: null,
updateBy: null,
updateTime: null,
remark: null,
params: {},
deviceId: 1055550311,
deviceId: 65,
deviceName: '雨棚可变信息标志ZK18+665',
brandId: 4,
iotBoardBrandName: {
@ -952,130 +642,6 @@ export default {
lAlarmHandleStr: null,
eqDirection: null,
iotDeviceType: null
},
{
searchValue: null,
createBy: null,
createTime: null,
updateBy: null,
updateTime: null,
remark: null,
params: {},
deviceId: 1055550307,
deviceName: '悬臂可变信息标志ZK17+013',
brandId: 4,
iotBoardBrandName: {
brandId: 4,
brandName: '光电比特'
},
routeId: 17,
routeDirection: '济南方向',
deviceMarkingName: null,
deviceTypeId: 202010001,
deviceTypeNumber: 202010004,
deviceModelId: null,
factoryLibrary: null,
userUnitId: 555503,
operatorId: null,
longitude: null,
latitude: null,
firmId: 18,
purchaseDate: '2022-12-14T16:06:03.000+08:00',
warrantyYears: null,
unitPrice: null,
runStatus: 1,
tunnelId: 'JQ-JiNan-WenZuBei-MJY',
deviceStatus: '1',
installDate: '2022-12-14T16:06:03.000+08:00',
maintainId: 2,
collarAgencyId: 555503,
pileNumber: 'ZK135+268',
manageAgencyId: 'YG11002',
producteDate: null,
repairDate: null,
operateDate: null,
serviceLife: null,
storageDate: null,
isMonitor: 1,
isConfig: 1,
localInfo: 16,
routeNumber: null,
routeName: null,
deviceIp: '10.7.180.85',
devicePort: null,
devicePixel: '192*160',
userName: null,
passWord: null,
protocolName: null,
deviceTypeIds: null,
lUserID: null,
lAlarmHandle: null,
lUserIDStr: null,
lAlarmHandleStr: null,
eqDirection: null,
iotDeviceType: null
},
{
searchValue: null,
createBy: null,
createTime: null,
updateBy: null,
updateTime: null,
remark: null,
params: {},
deviceId: 1055550308,
deviceName: '悬臂可变信息标志YK17+800',
brandId: 4,
iotBoardBrandName: {
brandId: 4,
brandName: '光电比特'
},
routeId: 17,
routeDirection: '济南方向',
deviceMarkingName: null,
deviceTypeId: 202010001,
deviceTypeNumber: 202010004,
deviceModelId: null,
factoryLibrary: null,
userUnitId: 555503,
operatorId: null,
longitude: null,
latitude: null,
firmId: 18,
purchaseDate: '2022-12-14T16:06:03.000+08:00',
warrantyYears: null,
unitPrice: null,
runStatus: 1,
tunnelId: 'JQ-JiNan-WenZuBei-MJY',
deviceStatus: '1',
installDate: '2022-12-14T16:06:03.000+08:00',
maintainId: 2,
collarAgencyId: 555503,
pileNumber: 'ZK135+568',
manageAgencyId: 'YG11002',
producteDate: null,
repairDate: null,
operateDate: null,
serviceLife: null,
storageDate: null,
isMonitor: 1,
isConfig: 1,
localInfo: 16,
routeNumber: null,
routeName: null,
deviceIp: '10.7.180.86',
devicePort: null,
devicePixel: '192*160',
userName: null,
passWord: null,
protocolName: null,
deviceTypeIds: null,
lUserID: null,
lAlarmHandle: null,
lUserIDStr: null,
lAlarmHandleStr: null,
eqDirection: null,
iotDeviceType: null
}
]
}
@ -1332,14 +898,13 @@ export default {
obj.ACTION = item.ACTION
obj.SPEED = item.SPEED
obj.COORDINATE = item.COORDINATE.replace('-', '0')
obj.x = obj.COORDINATE.substring(0,3)
obj.y = obj.COORDINATE.substring(3,6)
obj.COLOR = that.getColorValue(item.COLOR)
obj.FONT = that.getFontValue(item.FONT)
obj.FONT_SIZE = item.FONT_SIZE.substring(0, 2)
obj.CONTENT = item.CONTENT.replace(/\n|\r\n/g, '<r><n>')
obj.width = devicePixel[0]
obj.height = devicePixel[1]
obj.horizontalAlignment = item.formatStyle //
return obj
})
objAll.parameters = newArr
@ -1348,54 +913,45 @@ export default {
}
console.log(newArr, 'newArr')
invokedFunction(65,13,{parameters:newArr}).then(res =>{
debugger
if (res.data.result == '01'){
invokedFunction(65,'1B',{}).then(res =>{
invokedFunction(65,'1B',{fileId:'1'}).then(res =>{
debugger
console.log("1B---------------------------------")
console.log('发布消息,播放文件-----------------------------')
console.log(res)
}).catch(()=>{
})
}
}).catch(()=>{
this.$modal.msgError("发布失败,请重试");
})
invokedFunction(65,11,{deviceId : '65535',fileName:'play001.lst'}).then(res =>{
/*invokedFunction(65,11,{size : '65535',fileName:'play001.lst'}).then(res =>{
debugger
loading.close()
console.log('11-------------------------------------')
console.log('发布消息,校验文件名-------------------------------------')
console.log(res)
if (res.data.result == '01'){
invokedFunction(65,13,{parameters:newArr}).then(res =>{
debugger
console.log('13-----------------------------')
console.log('发布消息,发送文件内容-----------------------------')
console.log(res)
if (res.data.result == '01'){
invokedFunction(65,'1B',{}).then(res =>{
invokedFunction(65,'1B',{fileId:'1'}).then(res =>{
debugger
console.log("1B---------------------------------")
console.log('发布消息,播放文件-----------------------------')
console.log(res)
}).catch(()=>{
this.$modal.msgError("发布失败,请重试");
})
}
}).catch(()=>{
this.$modal.msgError("发布失败,请重试");
})
}
}).catch(()=>{
this.$modal.msgError("发布失败,请重试");
})*/
loading.close()
})
})
.catch(() => {
}).catch(() => {
this.$message({
type: 'info',
message: '已取消发布情报板'
@ -1529,13 +1085,13 @@ export default {
})*/
await getDeviceRealtimeProperty('65','3A',{ async: false})
.then(res => {
debugger
if ("3A" in res.data){
console.log('回读消息------------------------')
console.log(res.data)
var contents = res.data['3A'].content
console.log(contents, 'onSubmit-----contents')
for (let i = 0; i < contents.length; i++) {
let item = contents[i]
item.COLOR = this.getColorStyle(item.foregroundColor)
item.COLOR = item.foregroundColor
item.FONT_SIZE = item.fontSize + 'px'
item.ID = i
item.FONT = item.font

Loading…
Cancel
Save