mirror of
https://github.com/IoTManagerProject/IoTManager.git
synced 2026-03-29 15:42:20 +03:00
Global Webinterface Upgrade
This commit is contained in:
111
data/set.mqtt.json
Normal file
111
data/set.mqtt.json
Normal file
@@ -0,0 +1,111 @@
|
||||
{
|
||||
"configs": [
|
||||
"/config.setup.json"
|
||||
],
|
||||
"class": "col-sm-offset-1 col-sm-10 col-md-offset-2 col-md-8 col-lg-offset-3 col-lg-6",
|
||||
"content": [
|
||||
{
|
||||
"type": "h5",
|
||||
"title": "{{name}}",
|
||||
"class": "alert-warning"
|
||||
},
|
||||
{
|
||||
"type": "text",
|
||||
"class": "alert alert-warning",
|
||||
"title": "Обратите внимание что поле prefix может состоять только из одного слова и одного разделителя: <b>/prefix</b>, вариант вида: <b>/prefix1/prefix2</b> работать не будет. После изменения поля prefix необходимо перезагрузить устройство"
|
||||
},
|
||||
{
|
||||
"type": "h4",
|
||||
"title": "Server name:"
|
||||
},
|
||||
{
|
||||
"type": "input",
|
||||
"title": "",
|
||||
"name": "1",
|
||||
"state": "{{mqttServer}}"
|
||||
},
|
||||
{
|
||||
"type": "h4",
|
||||
"title": "Port:"
|
||||
},
|
||||
{
|
||||
"type": "input",
|
||||
"title": "",
|
||||
"name": "2",
|
||||
"state": "{{mqttPort}}"
|
||||
},
|
||||
{
|
||||
"type": "h4",
|
||||
"title": "Prefix:"
|
||||
},
|
||||
{
|
||||
"type": "input",
|
||||
"title": "",
|
||||
"name": "3",
|
||||
"state": "{{mqttPrefix}}"
|
||||
},
|
||||
{
|
||||
"type": "h4",
|
||||
"title": "User name:"
|
||||
},
|
||||
{
|
||||
"type": "input",
|
||||
"title": "",
|
||||
"name": "4",
|
||||
"state": "{{mqttUser}}"
|
||||
},
|
||||
{
|
||||
"type": "h4",
|
||||
"title": "Password:"
|
||||
},
|
||||
{
|
||||
"type": "input",
|
||||
"title": "",
|
||||
"name": "5",
|
||||
"state": "{{mqttPass}}"
|
||||
},
|
||||
{
|
||||
"type": "h3",
|
||||
"name": "my-block",
|
||||
"style": "position:fixed;top:30%;left:50%;width:400px;margin-left:-200px;text-align:center;",
|
||||
"class": "hidden"
|
||||
},
|
||||
{
|
||||
"type": "text",
|
||||
"class": "alert alert-warning",
|
||||
"title": "Прежде чем нажимать на кнопку <b>'Отправить настройки MQTT'</b> сохрание их, если Вы их меняли. Настройки получат и перезапишут все устройства в локальной сети"
|
||||
},
|
||||
{
|
||||
"type": "button",
|
||||
"title": "Сохранить",
|
||||
"action": "mqttSave?mqttServer=[[1]]&mqttPort=[[2]]&mqttPrefix=[[3]]&mqttUser=[[4]]&mqttPass=[[5]]",
|
||||
"class": "btn btn-block btn-success"
|
||||
},
|
||||
{
|
||||
"type": "button",
|
||||
"title": "Отправить настройки MQTT с этого устройства на все остальные",
|
||||
"action": "udp?arg=2",
|
||||
"class": "btn btn-block btn-success"
|
||||
},
|
||||
|
||||
{
|
||||
"type": "button",
|
||||
"title": "Проверить соединение с MQTT",
|
||||
"action": "mqttCheck",
|
||||
"response": "[[my-block]]",
|
||||
"class": "btn btn-block btn-success"
|
||||
},
|
||||
{
|
||||
"type": "link",
|
||||
"title": "Перезагрузить устройство",
|
||||
"action": "javascript:if(confirm(renameBlock(jsonResponse,'Перезагрузить?'))){send_request(this,'/restart?device=ok');}",
|
||||
"class": "btn btn-block btn-success"
|
||||
},
|
||||
{
|
||||
"type": "link",
|
||||
"title": "Главная",
|
||||
"action": "/",
|
||||
"class": "btn btn-block btn-danger btn-sm"
|
||||
}
|
||||
]
|
||||
}
|
||||
Reference in New Issue
Block a user