mirror of
https://github.com/bwssytems/ha-bridge.git
synced 2025-12-18 08:13:23 +00:00
Fix small issues and add pct check for FHEM
This commit is contained in:
2
pom.xml
2
pom.xml
@@ -5,7 +5,7 @@
|
|||||||
|
|
||||||
<groupId>com.bwssystems.HABridge</groupId>
|
<groupId>com.bwssystems.HABridge</groupId>
|
||||||
<artifactId>ha-bridge</artifactId>
|
<artifactId>ha-bridge</artifactId>
|
||||||
<version>5.2.0RC8</version>
|
<version>5.2.0RC9</version>
|
||||||
<packaging>jar</packaging>
|
<packaging>jar</packaging>
|
||||||
|
|
||||||
<name>HA Bridge</name>
|
<name>HA Bridge</name>
|
||||||
|
|||||||
@@ -49,14 +49,12 @@ public class HABridge {
|
|||||||
// Singleton initialization
|
// Singleton initialization
|
||||||
thePool = new HttpClientPool();
|
thePool = new HttpClientPool();
|
||||||
|
|
||||||
log.info("HA Bridge (v" + theVersion.getVersion() + ") starting....");
|
|
||||||
|
|
||||||
bridgeSettings = new BridgeSettings();
|
bridgeSettings = new BridgeSettings();
|
||||||
// sparkjava config directive to set html static file location for Jetty
|
// sparkjava config directive to set html static file location for Jetty
|
||||||
while(!bridgeSettings.getBridgeControl().isStop()) {
|
while(!bridgeSettings.getBridgeControl().isStop()) {
|
||||||
bridgeSettings.buildSettings();
|
bridgeSettings.buildSettings();
|
||||||
bridgeSettings.getBridgeSecurity().removeTestUsers();
|
bridgeSettings.getBridgeSecurity().removeTestUsers();
|
||||||
log.info("HA Bridge initializing....");
|
log.info("HA Bridge (v" + theVersion.getVersion() + ") initializing....");
|
||||||
// sparkjava config directive to set ip address for the web server to listen on
|
// sparkjava config directive to set ip address for the web server to listen on
|
||||||
ipAddress(bridgeSettings.getBridgeSettingsDescriptor().getWebaddress());
|
ipAddress(bridgeSettings.getBridgeSettingsDescriptor().getWebaddress());
|
||||||
// sparkjava config directive to set port for the web server to listen on
|
// sparkjava config directive to set port for the web server to listen on
|
||||||
@@ -91,7 +89,7 @@ public class HABridge {
|
|||||||
bridgeSettings.getBridgeSettingsDescriptor().isUseupnpiface() + " on web server: " +
|
bridgeSettings.getBridgeSettingsDescriptor().isUseupnpiface() + " on web server: " +
|
||||||
bridgeSettings.getBridgeSettingsDescriptor().getWebaddress() + ":" + bridgeSettings.getBridgeSettingsDescriptor().getServerPort());
|
bridgeSettings.getBridgeSettingsDescriptor().getWebaddress() + ":" + bridgeSettings.getBridgeSettingsDescriptor().getServerPort());
|
||||||
// setup the class to handle the upnp response rest api
|
// setup the class to handle the upnp response rest api
|
||||||
theSettingResponder = new UpnpSettingsResource(bridgeSettings.getBridgeSettingsDescriptor());
|
theSettingResponder = new UpnpSettingsResource(bridgeSettings);
|
||||||
theSettingResponder.setupServer();
|
theSettingResponder.setupServer();
|
||||||
|
|
||||||
// start the upnp ssdp discovery listener
|
// start the upnp ssdp discovery listener
|
||||||
@@ -127,12 +125,12 @@ public class HABridge {
|
|||||||
bridgeSettings.updateConfigFile();
|
bridgeSettings.updateConfigFile();
|
||||||
try {
|
try {
|
||||||
HttpClientPool.shutdown();
|
HttpClientPool.shutdown();
|
||||||
thePool = null;
|
|
||||||
} catch (InterruptedException e) {
|
} catch (InterruptedException e) {
|
||||||
log.warn("Error shutting down http pool: " + e.getMessage());;
|
log.warn("Error shutting down http pool: " + e.getMessage());;
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
log.warn("Error shutting down http pool: " + e.getMessage());;
|
log.warn("Error shutting down http pool: " + e.getMessage());;
|
||||||
}
|
}
|
||||||
|
thePool = null;
|
||||||
log.info("HA Bridge (v" + theVersion.getVersion() + ") exiting....");
|
log.info("HA Bridge (v" + theVersion.getVersion() + ") exiting....");
|
||||||
System.exit(0);
|
System.exit(0);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -42,6 +42,14 @@ public class HomeManager {
|
|||||||
// factory method
|
// factory method
|
||||||
public void buildHomes(BridgeSettings bridgeSettings, UDPDatagramSender aUdpDatagramSender) {
|
public void buildHomes(BridgeSettings bridgeSettings, UDPDatagramSender aUdpDatagramSender) {
|
||||||
Home aHome = null;
|
Home aHome = null;
|
||||||
|
//setup the http handler Home - This must be the first home created for devMode
|
||||||
|
aHome = new HTTPHome(bridgeSettings);
|
||||||
|
homeList.put(DeviceMapTypes.HTTP_DEVICE[DeviceMapTypes.typeIndex], aHome);
|
||||||
|
homeList.put(DeviceMapTypes.CUSTOM_DEVICE[DeviceMapTypes.typeIndex], aHome);
|
||||||
|
homeList.put(DeviceMapTypes.VERA_DEVICE[DeviceMapTypes.typeIndex], aHome);
|
||||||
|
homeList.put(DeviceMapTypes.VERA_SCENE[DeviceMapTypes.typeIndex], aHome);
|
||||||
|
homeList.put(DeviceMapTypes.FIBARO_DEVICE[DeviceMapTypes.typeIndex], aHome);
|
||||||
|
homeList.put(DeviceMapTypes.FIBARO_SCENE[DeviceMapTypes.typeIndex], aHome);
|
||||||
//setup the harmony connection if available
|
//setup the harmony connection if available
|
||||||
aHome = new HarmonyHome(bridgeSettings);
|
aHome = new HarmonyHome(bridgeSettings);
|
||||||
resourceList.put(DeviceMapTypes.HARMONY_ACTIVITY[DeviceMapTypes.typeIndex], aHome);
|
resourceList.put(DeviceMapTypes.HARMONY_ACTIVITY[DeviceMapTypes.typeIndex], aHome);
|
||||||
@@ -80,14 +88,6 @@ public class HomeManager {
|
|||||||
aHome = new CommandHome(bridgeSettings);
|
aHome = new CommandHome(bridgeSettings);
|
||||||
homeList.put(DeviceMapTypes.EXEC_DEVICE_COMPAT[DeviceMapTypes.typeIndex], aHome);
|
homeList.put(DeviceMapTypes.EXEC_DEVICE_COMPAT[DeviceMapTypes.typeIndex], aHome);
|
||||||
homeList.put(DeviceMapTypes.CMD_DEVICE[DeviceMapTypes.typeIndex], aHome);
|
homeList.put(DeviceMapTypes.CMD_DEVICE[DeviceMapTypes.typeIndex], aHome);
|
||||||
//setup the http handler Home
|
|
||||||
aHome = new HTTPHome(bridgeSettings);
|
|
||||||
homeList.put(DeviceMapTypes.HTTP_DEVICE[DeviceMapTypes.typeIndex], aHome);
|
|
||||||
homeList.put(DeviceMapTypes.CUSTOM_DEVICE[DeviceMapTypes.typeIndex], aHome);
|
|
||||||
homeList.put(DeviceMapTypes.VERA_DEVICE[DeviceMapTypes.typeIndex], aHome);
|
|
||||||
homeList.put(DeviceMapTypes.VERA_SCENE[DeviceMapTypes.typeIndex], aHome);
|
|
||||||
homeList.put(DeviceMapTypes.FIBARO_DEVICE[DeviceMapTypes.typeIndex], aHome);
|
|
||||||
homeList.put(DeviceMapTypes.FIBARO_SCENE[DeviceMapTypes.typeIndex], aHome);
|
|
||||||
//setup the tcp handler Home
|
//setup the tcp handler Home
|
||||||
aHome = new TCPHome(bridgeSettings);
|
aHome = new TCPHome(bridgeSettings);
|
||||||
homeList.put(DeviceMapTypes.TCP_DEVICE[DeviceMapTypes.typeIndex], aHome);
|
homeList.put(DeviceMapTypes.TCP_DEVICE[DeviceMapTypes.typeIndex], aHome);
|
||||||
|
|||||||
@@ -111,11 +111,7 @@ public class BrightnessDecode {
|
|||||||
|
|
||||||
Integer endResult = calculateMath(variables, mathDescriptor);
|
Integer endResult = calculateMath(variables, mathDescriptor);
|
||||||
if(endResult != null) {
|
if(endResult != null) {
|
||||||
if (isHex) {
|
replaceValue = convertToHex(endResult);
|
||||||
replaceValue = convertToHex(endResult);
|
|
||||||
} else {
|
|
||||||
replaceValue = endResult.toString();
|
|
||||||
}
|
|
||||||
replaceTarget = INTENSITY_MATH + mathDescriptor + INTENSITY_MATH_CLOSE_HEX;
|
replaceTarget = INTENSITY_MATH + mathDescriptor + INTENSITY_MATH_CLOSE_HEX;
|
||||||
notDone = true;
|
notDone = true;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -45,14 +45,21 @@ public class HttpTestHandler extends HTTPHandler {
|
|||||||
log.info("header index " + i + " name: <<<" + headers[i].getName() + ">>>, value: <<<" + headers[i].getValue() + ">>>");
|
log.info("header index " + i + " name: <<<" + headers[i].getName() + ">>>, value: <<<" + headers[i].getValue() + ">>>");
|
||||||
String responseData = null;
|
String responseData = null;
|
||||||
for(NameValue aTest:theData) {
|
for(NameValue aTest:theData) {
|
||||||
if(url.contains(aTest.getName()))
|
if(aTest.getName() == null)
|
||||||
responseData = aTest.getValue();
|
|
||||||
else if(aTest.getName() == null || aTest.getName().isEmpty())
|
|
||||||
responseData = aTest.getValue();
|
responseData = aTest.getValue();
|
||||||
|
else {
|
||||||
|
if(url.contains(aTest.getName()))
|
||||||
|
responseData = aTest.getValue();
|
||||||
|
else if(aTest.getName() == null || aTest.getName().isEmpty())
|
||||||
|
responseData = aTest.getValue();
|
||||||
|
}
|
||||||
|
|
||||||
if(responseData != null)
|
if(responseData != null)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(responseData == null)
|
||||||
|
responseData = "No data was set for HttpTestHandler for your request url.";
|
||||||
return responseData;
|
return responseData;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -66,22 +66,26 @@ public class OpenHABInstance {
|
|||||||
theData = httpClient.doHttpRequest(theUrl, HttpGet.METHOD_NAME, "application/json", null, headers);
|
theData = httpClient.doHttpRequest(theUrl, HttpGet.METHOD_NAME, "application/json", null, headers);
|
||||||
if(theData != null) {
|
if(theData != null) {
|
||||||
log.debug("GET OpenHAB States - data: " + theData);
|
log.debug("GET OpenHAB States - data: " + theData);
|
||||||
theOpenhabStates = new Gson().fromJson(theData, OpenHABItem[].class);
|
try {
|
||||||
if(theOpenhabStates == null) {
|
theOpenhabStates = new Gson().fromJson(theData, OpenHABItem[].class);
|
||||||
log.warn("Cannot get any devices for OpenHAB " + theOpenHAB.getName() + " as response is not parsable.");
|
if(theOpenhabStates == null) {
|
||||||
}
|
log.warn("Cannot get any devices for OpenHAB " + theOpenHAB.getName() + " as response is not parsable.");
|
||||||
else {
|
}
|
||||||
deviceList = new ArrayList<OpenHABDevice>();
|
else {
|
||||||
|
deviceList = new ArrayList<OpenHABDevice>();
|
||||||
for (int i = 0; i < theOpenhabStates.length; i++) {
|
|
||||||
OpenHABDevice aNewOpenHABDeviceDevice = new OpenHABDevice();
|
for (int i = 0; i < theOpenhabStates.length; i++) {
|
||||||
aNewOpenHABDeviceDevice.setItem(theOpenhabStates[i]);
|
OpenHABDevice aNewOpenHABDeviceDevice = new OpenHABDevice();
|
||||||
aNewOpenHABDeviceDevice.setAddress(theOpenHAB.getIp() + ":" + theOpenHAB.getPort());
|
aNewOpenHABDeviceDevice.setItem(theOpenhabStates[i]);
|
||||||
aNewOpenHABDeviceDevice.setName(theOpenHAB.getName());
|
aNewOpenHABDeviceDevice.setAddress(theOpenHAB.getIp() + ":" + theOpenHAB.getPort());
|
||||||
deviceList.add(aNewOpenHABDeviceDevice);
|
aNewOpenHABDeviceDevice.setName(theOpenHAB.getName());
|
||||||
|
deviceList.add(aNewOpenHABDeviceDevice);
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
log.warn("Cannot get an devices for OpenHAB " + theOpenHAB.getName() + " Gson Parse Error.");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
log.warn("Cannot get an devices for OpenHAB " + theOpenHAB.getName() + " http call failed.");
|
log.warn("Cannot get an devices for OpenHAB " + theOpenHAB.getName() + " http call failed.");
|
||||||
|
|||||||
@@ -3,6 +3,7 @@ package com.bwssystems.HABridge.upnp;
|
|||||||
import org.slf4j.Logger;
|
import org.slf4j.Logger;
|
||||||
import org.slf4j.LoggerFactory;
|
import org.slf4j.LoggerFactory;
|
||||||
|
|
||||||
|
import com.bwssystems.HABridge.BridgeSettings;
|
||||||
import com.bwssystems.HABridge.BridgeSettingsDescriptor;
|
import com.bwssystems.HABridge.BridgeSettingsDescriptor;
|
||||||
import com.bwssystems.HABridge.api.hue.HueConstants;
|
import com.bwssystems.HABridge.api.hue.HueConstants;
|
||||||
import com.bwssystems.HABridge.api.hue.HuePublicConfig;
|
import com.bwssystems.HABridge.api.hue.HuePublicConfig;
|
||||||
@@ -16,6 +17,7 @@ public class UpnpSettingsResource {
|
|||||||
private Logger log = LoggerFactory.getLogger(UpnpSettingsResource.class);
|
private Logger log = LoggerFactory.getLogger(UpnpSettingsResource.class);
|
||||||
|
|
||||||
private BridgeSettingsDescriptor theSettings;
|
private BridgeSettingsDescriptor theSettings;
|
||||||
|
private BridgeSettings bridgeSettings;
|
||||||
|
|
||||||
private String hueTemplate = "<?xml version=\"1.0\" encoding=\"UTF-8\" ?>\n"
|
private String hueTemplate = "<?xml version=\"1.0\" encoding=\"UTF-8\" ?>\n"
|
||||||
+ "<root xmlns=\"urn:schemas-upnp-org:device-1-0\">\n"
|
+ "<root xmlns=\"urn:schemas-upnp-org:device-1-0\">\n"
|
||||||
@@ -55,15 +57,22 @@ public class UpnpSettingsResource {
|
|||||||
+ "</device>\n"
|
+ "</device>\n"
|
||||||
+ "</root>\n";
|
+ "</root>\n";
|
||||||
|
|
||||||
public UpnpSettingsResource(BridgeSettingsDescriptor theBridgeSettings) {
|
public UpnpSettingsResource(BridgeSettings theBridgeSettings) {
|
||||||
super();
|
super();
|
||||||
this.theSettings = theBridgeSettings;
|
this.bridgeSettings = theBridgeSettings;
|
||||||
|
this.theSettings = theBridgeSettings.getBridgeSettingsDescriptor();
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setupServer() {
|
public void setupServer() {
|
||||||
log.info("Description xml service started....");
|
log.info("Description xml service started....");
|
||||||
// http://ip_adress:port/description.xml which returns the xml configuration for the hue emulator
|
// http://ip_adress:port/description.xml which returns the xml configuration for the hue emulator
|
||||||
get("/description.xml", "application/xml; charset=utf-8", (request, response) -> {
|
get("/description.xml", "application/xml; charset=utf-8", (request, response) -> {
|
||||||
|
if(bridgeSettings.getBridgeControl().isReinit() || bridgeSettings.getBridgeControl().isStop()) {
|
||||||
|
log.info("Get description.xml called while in re-init or stop state");
|
||||||
|
response.status(503);
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
String portNumber = Integer.toString(request.port());
|
String portNumber = Integer.toString(request.port());
|
||||||
String filledTemplate = null;
|
String filledTemplate = null;
|
||||||
String bridgeIdMac = HuePublicConfig.createConfig("temp", theSettings.getUpnpConfigAddress(), HueConstants.HUB_VERSION, theSettings.getHubmac()).getSNUUIDFromMac();
|
String bridgeIdMac = HuePublicConfig.createConfig("temp", theSettings.getUpnpConfigAddress(), HueConstants.HUB_VERSION, theSettings.getHubmac()).getSNUUIDFromMac();
|
||||||
|
|||||||
@@ -3049,6 +3049,8 @@ app.controller('MQTTController', function ($scope, $location, bridgeService, ngD
|
|||||||
bridgeService.viewMQTTDevices();
|
bridgeService.viewMQTTDevices();
|
||||||
$scope.imgButtonsUrl = "glyphicon glyphicon-plus";
|
$scope.imgButtonsUrl = "glyphicon glyphicon-plus";
|
||||||
$scope.buttonsVisible = false;
|
$scope.buttonsVisible = false;
|
||||||
|
$scope.mqttretain = false;
|
||||||
|
$scope.mqttqos = 1;
|
||||||
|
|
||||||
$scope.clearDevice = function () {
|
$scope.clearDevice = function () {
|
||||||
bridgeService.clearDevice();
|
bridgeService.clearDevice();
|
||||||
@@ -3056,6 +3058,10 @@ app.controller('MQTTController', function ($scope, $location, bridgeService, ngD
|
|||||||
};
|
};
|
||||||
|
|
||||||
$scope.buildMQTTPublish = function (mqttbroker, mqtttopic, mqttmessage, mqttqos, mqttretain) {
|
$scope.buildMQTTPublish = function (mqttbroker, mqtttopic, mqttmessage, mqttqos, mqttretain) {
|
||||||
|
if(mqttretain === 'undefined')
|
||||||
|
mqttretain = false;
|
||||||
|
if(mqttqos === 'undefined')
|
||||||
|
mqttqos = 1;
|
||||||
onpayload = "{\"clientId\":\"" + mqttbroker.clientId + "\",\"topic\":\"" + mqtttopic + "\",\"message\":\"" + mqttmessage + "\",\"qos\":\"" + mqttqos + "\",\"retain\":\"" + mqttretain + "\"}";
|
onpayload = "{\"clientId\":\"" + mqttbroker.clientId + "\",\"topic\":\"" + mqtttopic + "\",\"message\":\"" + mqttmessage + "\",\"qos\":\"" + mqttqos + "\",\"retain\":\"" + mqttretain + "\"}";
|
||||||
offpayload = "{\"clientId\":\"" + mqttbroker.clientId + "\",\"topic\":\"" + mqtttopic + "\",\"message\":\"" + mqttmessage + "\",\"qos\":\"" + mqttqos + "\",\"retain\":\"" + mqttretain + "\"}";
|
offpayload = "{\"clientId\":\"" + mqttbroker.clientId + "\",\"topic\":\"" + mqtttopic + "\",\"message\":\"" + mqttmessage + "\",\"qos\":\"" + mqttqos + "\",\"retain\":\"" + mqttretain + "\"}";
|
||||||
|
|
||||||
@@ -3926,16 +3932,23 @@ app.controller('FhemController', function ($scope, $location, bridgeService, ngD
|
|||||||
|
|
||||||
$scope.buildDeviceUrls = function (fhemdevice, dim_control, buildonly) {
|
$scope.buildDeviceUrls = function (fhemdevice, dim_control, buildonly) {
|
||||||
var preCmd = "/fhem?cmd=set%20" + fhemdevice.item.Name + "%20";
|
var preCmd = "/fhem?cmd=set%20" + fhemdevice.item.Name + "%20";
|
||||||
if(fhemdevice.item.PossibleSets.indexOf("dim") >= 0) {
|
if(fhemdevice.item.PossibleSets.toLowerCase().indexOf("dim") >= 0) {
|
||||||
if((dim_control.indexOf("byte") >= 0 || dim_control.indexOf("percent") >= 0 || dim_control.indexOf("math") >= 0)) {
|
if((dim_control.indexOf("byte") >= 0 || dim_control.indexOf("percent") >= 0 || dim_control.indexOf("math") >= 0)) {
|
||||||
dimpayload = "{\"url\":\"http://" + fhemdevice.address + preCmd + "\",\"command\":\"dim%20" + dim_control + "\"}";
|
dimpayload = "{\"url\":\"http://" + fhemdevice.address + preCmd + "\",\"command\":\"dim%20" + dim_control + "\"}";
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
dimpayload = "{\"url\":\"http://" + fhemdevice.address + preCmd + "\",\"command\":\"dim%20${intensity.percent}\"}";
|
dimpayload = "{\"url\":\"http://" + fhemdevice.address + preCmd + "\",\"command\":\"dim%20${intensity.percent}\"}";
|
||||||
}
|
}
|
||||||
|
else if(fhemdevice.item.PossibleSets.toLowerCase().indexOf("pct") >= 0) {
|
||||||
|
if((dim_control.indexOf("byte") >= 0 || dim_control.indexOf("percent") >= 0 || dim_control.indexOf("math") >= 0)) {
|
||||||
|
dimpayload = "{\"url\":\"http://" + fhemdevice.address + preCmd + "\",\"command\":\"pct%20" + dim_control + "\"}";
|
||||||
|
}
|
||||||
|
else
|
||||||
|
dimpayload = "{\"url\":\"http://" + fhemdevice.address + preCmd + "\",\"command\":\"pct%20${intensity.percent}\"}";
|
||||||
|
}
|
||||||
else
|
else
|
||||||
dimpayload = null;
|
dimpayload = null;
|
||||||
if(fhemdevice.item.PossibleSets.indexOf("RGB") >= 0) {
|
if(fhemdevice.item.PossibleSets.toLowerCase().indexOf("rgb") >= 0) {
|
||||||
colorpayload = "{\"url\":\"http://" + fhemdevice.address + preCmd + "\",\"command\":\"RGB%20${color.rgbx}\"}";
|
colorpayload = "{\"url\":\"http://" + fhemdevice.address + preCmd + "\",\"command\":\"RGB%20${color.rgbx}\"}";
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|||||||
@@ -17,7 +17,7 @@
|
|||||||
<li ng-if="bridge.showSomfy" role="presentation"><a href="#!/somfydevices">Somfy Devices</a></li>
|
<li ng-if="bridge.showSomfy" role="presentation"><a href="#!/somfydevices">Somfy Devices</a></li>
|
||||||
<li ng-if="bridge.showLifx" role="presentation"><a href="#!/lifxdevices">LIFX Devices</a></li>
|
<li ng-if="bridge.showLifx" role="presentation"><a href="#!/lifxdevices">LIFX Devices</a></li>
|
||||||
<li ng-if="bridge.showHomeWizard" role="presentation"><a href="#!/homewizarddevices">HomeWizard Devices</a></li>
|
<li ng-if="bridge.showHomeWizard" role="presentation"><a href="#!/homewizarddevices">HomeWizard Devices</a></li>
|
||||||
<li ng-if="bridge.showbroadlink" role="presentation"><a href="#!/broadlinkdevices">broadlink Devices</a></li>
|
<li ng-if="bridge.showOpenHAB" role="presentation"><a href="#!/openhabdevices">OpenHAB Devices</a></li>
|
||||||
<li ng-if="bridge.showFHEM" role="presentation"><a href="#!/fhemdevices">FHEM Devices</a></li>
|
<li ng-if="bridge.showFHEM" role="presentation"><a href="#!/fhemdevices">FHEM Devices</a></li>
|
||||||
<li ng-if="bridge.showBroadlink" role="presentation" class="active"><a href="#!/broadlinkdevices">Broadlink Devices</a></li>
|
<li ng-if="bridge.showBroadlink" role="presentation" class="active"><a href="#!/broadlinkdevices">Broadlink Devices</a></li>
|
||||||
<li role="presentation"><a href="#!/editdevice">Add/Edit</a></li>
|
<li role="presentation"><a href="#!/editdevice">Add/Edit</a></li>
|
||||||
|
|||||||
@@ -71,8 +71,9 @@
|
|||||||
ng-model="mqttqos" placeholder="1"/>
|
ng-model="mqttqos" placeholder="1"/>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<input type="checkbox" rows="1" class="form-control" id="mqtt-retain"
|
<input type="checkbox" id="mqtt-retain"
|
||||||
ng-model="mqttretain"/>
|
ng-model="mqttretain" ng-true-value=true
|
||||||
|
ng-false-value=false>{{mqttretain}}</td>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<button class="btn btn-success" type="submit"
|
<button class="btn btn-success" type="submit"
|
||||||
|
|||||||
Reference in New Issue
Block a user