Updated view consistency. Fixed HAL bulk add

This commit is contained in:
Admin
2016-05-23 16:45:47 -05:00
parent 80ca8c3ca3
commit ed3db4427b
15 changed files with 1679 additions and 1474 deletions

View File

@@ -5,7 +5,7 @@
<groupId>com.bwssystems.HABridge</groupId> <groupId>com.bwssystems.HABridge</groupId>
<artifactId>ha-bridge</artifactId> <artifactId>ha-bridge</artifactId>
<version>2.0.7-hal</version> <version>2.0.7-hal-a</version>
<packaging>jar</packaging> <packaging>jar</packaging>
<name>HA Bridge</name> <name>HA Bridge</name>

View File

@@ -1,5 +1,5 @@
.scrollableContainer { .scrollableContainer {
height: 800px; height: 600px;
position: relative; position: relative;
padding-top: 35px; padding-top: 35px;
overflow: hidden; overflow: hidden;

View File

@@ -973,11 +973,17 @@ app.controller('VeraController', function ($scope, $location, $http, bridgeServi
} }
} }
} }
bridgeService.bulkAddDevice(devicesList); bridgeService.bulkAddDevice(devicesList).then(
$scope.clearDevice(); function () {
bridgeService.viewDevices(); $scope.clearDevice();
bridgeService.viewVeraDevices(); bridgeService.viewDevices();
bridgeService.viewVeraScenes(); bridgeService.viewVeraDevices();
bridgeService.viewVeraScenes();
},
function (error) {
bridgeService.displayWarn("Error adding Vera devices in bulk.", error)
}
);
$scope.bulk = { devices: [] }; $scope.bulk = { devices: [] };
}; };
@@ -1280,10 +1286,17 @@ app.controller('HueController', function ($scope, $location, $http, bridgeServic
} }
} }
} }
bridgeService.bulkAddDevice(devicesList); bridgeService.bulkAddDevice(devicesList).then(
$scope.clearDevice(); function () {
bridgeService.viewDevices(); $scope.clearDevice();
bridgeService.viewHueDevices(); bridgeService.viewDevices();
bridgeService.viewHueDevices();
},
function (error) {
bridgeService.displayWarn("Error adding Hue devices in bulk.", error)
}
);
$scope.bulk = { devices: [] }; $scope.bulk = { devices: [] };
}; };
@@ -1389,7 +1402,7 @@ app.controller('HalController', function ($scope, $location, $http, bridgeServic
var devicesList = []; var devicesList = [];
for(var i = 0; i < $scope.bulk.devices.length; i++) { for(var i = 0; i < $scope.bulk.devices.length; i++) {
for(var x = 0; x < bridgeService.state.haldevices.length; x++) { for(var x = 0; x < bridgeService.state.haldevices.length; x++) {
if(bridgeService.state.haldevices[x].id == $scope.bulk.devices[i]) { if(bridgeService.state.haldevices[x].haldevicename == $scope.bulk.devices[i]) {
$scope.buildDeviceUrls(bridgeService.state.haldevices[x],dim_control); $scope.buildDeviceUrls(bridgeService.state.haldevices[x],dim_control);
devicesList[i] = { devicesList[i] = {
name: $scope.device.name, name: $scope.device.name,
@@ -1408,10 +1421,16 @@ app.controller('HalController', function ($scope, $location, $http, bridgeServic
} }
} }
} }
bridgeService.bulkAddDevice(devicesList); bridgeService.bulkAddDevice(devicesList).then(
$scope.clearDevice(); function () {
bridgeService.viewDevices(); $scope.clearDevice();
bridgeService.viewHalDevices(); bridgeService.viewDevices();
bridgeService.viewHalDevices();
},
function (error) {
bridgeService.displayWarn("Error adding HAL devices in bulk.", error)
}
);
$scope.bulk = { devices: [] }; $scope.bulk = { devices: [] };
}; };
@@ -1437,7 +1456,8 @@ app.controller('HalController', function ($scope, $location, $http, bridgeServic
$scope.imgButtonsUrl = "glyphicon glyphicon-plus"; $scope.imgButtonsUrl = "glyphicon glyphicon-plus";
}; };
$scope.deleteDeviceByMapId = function (id, mapType) { $scope.deleteDeviceByMapId = function (haldevicename, halname, mapType) {
var id = haldevicename + "-" + halname;
$scope.bridge.mapandid = { id, mapType }; $scope.bridge.mapandid = { id, mapType };
ngDialog.open({ ngDialog.open({
template: 'deleteMapandIdDialog', template: 'deleteMapandIdDialog',
@@ -1685,7 +1705,7 @@ app.filter('availableHalDeviceId', function(bridgeService) {
if(input == null) if(input == null)
return out; return out;
for (var i = 0; i < input.length; i++) { for (var i = 0; i < input.length; i++) {
if(!bridgeService.findDeviceByMapId(input[i].id, input[i].haldevicename, "halDevice")){ if(!bridgeService.findDeviceByMapId(input[i].haldevicename + "-" + input[i].halname, input[i].halname, "halDevice")){
out.push(input[i]); out.push(input[i]);
} }
} }
@@ -1699,7 +1719,7 @@ app.filter('unavailableHalDeviceId', function(bridgeService) {
if(input == null) if(input == null)
return out; return out;
for (var i = 0; i < input.length; i++) { for (var i = 0; i < input.length; i++) {
if(bridgeService.findDeviceByMapId(input[i].id, input[i].haldevicename, "halDevice")){ if(bridgeService.findDeviceByMapId(input[i].haldevicename + "-" + input[i].halname, input[i].halname, "halDevice")){
out.push(input[i]); out.push(input[i]);
} }
} }

View File

@@ -1,41 +1,50 @@
<ul class="nav nav-pills" role="tablist">
<li role="presentation" class="active"><a href="#">Bridge Devices</a></li>
<li role="presentation"><a href="#/system">Bridge Control</a></li>
<li role="presentation"><a href="#/logs">Logs</a></li>
<li ng-if="bridge.showVera" role="presentation"><a href="#/veradevices">Vera Devices</a></li>
<li ng-if="bridge.showVera" role="presentation"><a href="#/verascenes">Vera Scenes</a></li>
<li ng-if="bridge.showHarmony" role="presentation"><a href="#/harmonyactivities">Harmony Activities</a></li>
<li ng-if="bridge.showHarmony" role="presentation"><a href="#/harmonydevices">Harmony Devices</a></li>
<li ng-if="bridge.showNest" role="presentation"><a href="#/nest">Nest</a></li>
<li ng-if="bridge.showHue" role="presentation"><a href="#/huedevices">Hue Devices</a></li>
<li ng-if="bridge.showHal" role="presentation"><a href="#/haldevices">HAL Devices</a></li>
<li role="presentation"><a href="#/editor">Manual Add</a></li>
</ul>
<div class="panel panel-default"> <ul class="nav nav-pills" role="tablist">
<div class="panel-heading"> <li role="presentation" class="active"><a href="#">Bridge
<h2 class="panel-title">Current devices ({{bridge.devices.length}}) </h2> Devices</a></li>
</div> <li role="presentation"><a href="#/system">Bridge Control</a></li>
<scrollable-table watch="bridge.devices"> <li role="presentation"><a href="#/logs">Logs</a></li>
<table class="table table-bordered table-striped table-hover"> <li ng-if="bridge.showVera" role="presentation"><a
<thead> href="#/veradevices">Vera Devices</a></li>
<tr> <li ng-if="bridge.showVera" role="presentation"><a
<th>Row</th> href="#/verascenes">Vera Scenes</a></li>
<th sortable-header col="id">ID</th> <li ng-if="bridge.showHarmony" role="presentation"><a
<th sortable-header col="name">Name</th> href="#/harmonyactivities">Harmony Activities</a></li>
<th sortable-header col="deviceType">Type</th> <li ng-if="bridge.showHarmony" role="presentation"><a
<th sortable-header col="targetDevice">Target</th> href="#/harmonydevices">Harmony Devices</a></li>
<th>Actions</th> <li ng-if="bridge.showNest" role="presentation"><a href="#/nest">Nest</a></li>
</tr> <li ng-if="bridge.showHue" role="presentation"><a
</thead> href="#/huedevices">Hue Devices</a></li>
<tr ng-repeat="device in bridge.devices"> <li ng-if="bridge.showHal" role="presentation"><a
<td>{{$index+1}}</td> href="#/haldevices">HAL Devices</a></li>
<td>{{device.id}}</td> <li role="presentation"><a href="#/editor">Manual Add</a></li>
<td>{{device.name}}</td> </ul>
<td>{{device.deviceType}}</td>
<td>{{device.targetDevice}}</td> <div class="panel panel-default">
<td> <div class="panel-heading">
<p> <h2 class="panel-title">Current devices
({{bridge.devices.length}})</h2>
</div>
<scrollable-table watch="bridge.devices">
<table class="table table-bordered table-striped table-hover">
<thead>
<tr>
<th>Row</th>
<th sortable-header col="id">ID</th>
<th sortable-header col="name">Name</th>
<th sortable-header col="deviceType">Type</th>
<th sortable-header col="targetDevice">Target</th>
<th>Actions</th>
</tr>
</thead>
<tr ng-repeat="device in bridge.devices">
<td>{{$index+1}}</td>
<td>{{device.id}}</td>
<td>{{device.name}}</td>
<td>{{device.deviceType}}</td>
<td>{{device.targetDevice}}</td>
<td>
<p>
<button class="btn btn-info" type="submit" <button class="btn btn-info" type="submit"
ng-click="testUrl(device, 'on')">Test ON</button> ng-click="testUrl(device, 'on')">Test ON</button>
<button class="btn btn-info" type="submit" <button class="btn btn-info" type="submit"
@@ -46,50 +55,55 @@
ng-click="editDevice(device)">Edit/Copy</button> ng-click="editDevice(device)">Edit/Copy</button>
<button class="btn btn-danger" type="submit" <button class="btn btn-danger" type="submit"
ng-click="deleteDevice(device)">Delete</button> ng-click="deleteDevice(device)">Delete</button>
</p> </p>
</td>
</tr>
</table>
</scrollable-table>
</div>
<div class="panel panel-default backup">
<div class="panel-heading">
<h1 class="panel-title">
Bridge Device DB Backup <a ng-click="toggleBk()"><span
class={{imgBkUrl}} aria-hidden="true"></a>
</h1>
</div>
<div ng-if="visibleBk" class="animate-if" class="panel-body">
<form class="form-horizontal">
<div class="form-group">
<label class="col-xs-12 col-sm-2 control-label" for="backup-name">Backup
File Name</label>
<div class="col-xs-8 col-sm-7">
<input id="backup-name" class="form-control" type="text"
ng-model="optionalbackupname" placeholder="Optional">
</div>
<button type="submit" class="btn btn-primary"
ng-click="backupDeviceDb(optionalbackupname)">Backup
Device DB</button>
</div>
</form>
<table class="table table-bordered table-striped table-hover">
<thead>
<tr>
<th>Filename</th>
<th>Actions</th>
</tr>
</thead>
<tr ng-repeat="backup in bridge.backups">
<td>{{backup}}</td>
<td>
<button class="btn btn-danger" type="submit"
ng-click="restoreBackup(backup)">Restore</button>
<button class="btn btn-warning" type="submit"
ng-click="deleteBackup(backup)">Delete</button>
</td> </td>
</tr> </tr>
</table> </table>
</scrollable-table>
</div> </div>
<div class="panel panel-default backup"> </div>
<div class="panel-heading">
<h1 class="panel-title">Bridge Device DB Backup <a ng-click="toggleBk()"><span class={{imgBkUrl}} aria-hidden="true"></a></h1>
</div>
<div ng-if="visibleBk" class="animate-if" class="panel-body">
<form class="form-horizontal">
<div class="form-group">
<label class="col-xs-12 col-sm-2 control-label" for="backup-name">Backup File Name</label>
<div class="col-xs-8 col-sm-7"> <script type="text/ng-template" id="valueDialog">
<input id="backup-name" class="form-control" type="text"
ng-model="optionalbackupname" placeholder="Optional">
</div>
<button type="submit" class="btn btn-primary"
ng-click="backupDeviceDb(optionalbackupname)">Backup Device DB</button>
</div>
</form>
<table class="table table-bordered table-striped table-hover">
<thead>
<tr>
<th>Filename</th>
<th>Actions</th>
</tr>
</thead>
<tr ng-repeat="backup in bridge.backups">
<td>{{backup}}</td>
<td>
<button class="btn btn-danger" type="submit"
ng-click="restoreBackup(backup)">Restore</button>
<button class="btn btn-warning" type="submit"
ng-click="deleteBackup(backup)">Delete</button>
</td>
</tr>
</table>
</div>
</div>
<script type="text/ng-template" id="valueDialog">
<div class="ngdialog-message"> <div class="ngdialog-message">
<h2>Select value</h2> <h2>Select value</h2>
<p> <p>
@@ -104,7 +118,7 @@
<button type="button" class="ngdialog-button ngdialog-button-primary" ng-click="setValue()">Set</button> <button type="button" class="ngdialog-button ngdialog-button-primary" ng-click="setValue()">Set</button>
</div> </div>
</script> </script>
<script type="text/ng-template" id="deleteDialog"> <script type="text/ng-template" id="deleteDialog">
<div class="ngdialog-message"> <div class="ngdialog-message">
<h2>Device to Delete?</h2> <h2>Device to Delete?</h2>
<p>{{device.name}}</p> <p>{{device.name}}</p>
@@ -114,4 +128,3 @@
<button type="button" class="ngdialog-button ngdialog-button-error" ng-click="deleteDevice(device)">Delete</button> <button type="button" class="ngdialog-button ngdialog-button-error" ng-click="deleteDevice(device)">Delete</button>
</div> </div>
</script> </script>

View File

@@ -1,211 +1,230 @@
<ul class="nav nav-pills" role="tablist"> <ul class="nav nav-pills" role="tablist">
<li role="presentation"><a href="#">Bridge Devices</a></li> <li role="presentation"><a href="#">Bridge Devices</a></li>
<li role="presentation"><a href="#/system">Bridge Control</a></li> <li role="presentation"><a href="#/system">Bridge Control</a></li>
<li role="presentation"><a href="#/logs">Logs</a></li> <li role="presentation"><a href="#/logs">Logs</a></li>
<li ng-if="bridge.showVera" role="presentation"><a href="#/veradevices">Vera Devices</a></li> <li ng-if="bridge.showVera" role="presentation"><a
<li ng-if="bridge.showVera" role="presentation"><a href="#/verascenes">Vera Scenes</a></li> href="#/veradevices">Vera Devices</a></li>
<li ng-if="bridge.showHarmony" role="presentation"><a href="#/harmonyactivities">Harmony Activities</a></li> <li ng-if="bridge.showVera" role="presentation"><a
<li ng-if="bridge.showHarmony" role="presentation"><a href="#/harmonydevices">Harmony Devices</a></li> href="#/verascenes">Vera Scenes</a></li>
<li ng-if="bridge.showNest" role="presentation"><a href="#/nest">Nest</a></li> <li ng-if="bridge.showHarmony" role="presentation"><a
<li ng-if="bridge.showHue" role="presentation"><a href="#/huedevices">Hue Devices</a></li> href="#/harmonyactivities">Harmony Activities</a></li>
<li role="presentation"><a href="#/editor">Manual Add</a></li> <li ng-if="bridge.showHarmony" role="presentation"><a
<li ng-if="bridge.showHal" role="presentation"><a href="#/haldevices">HAL Devices</a></li> href="#/harmonydevices">Harmony Devices</a></li>
<li role="presentation" class="active"><a href="#/editdevice">Edit Device</a></li> <li ng-if="bridge.showNest" role="presentation"><a href="#/nest">Nest</a></li>
</ul> <li ng-if="bridge.showHue" role="presentation"><a
href="#/huedevices">Hue Devices</a></li>
<li role="presentation"><a href="#/editor">Manual Add</a></li>
<li ng-if="bridge.showHal" role="presentation"><a
href="#/haldevices">HAL Devices</a></li>
<li role="presentation" class="active"><a href="#/editdevice">Edit
Device</a></li>
</ul>
<div class="panel panel-default bridgeServer" ng-if="!bridge.error"> <div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
<h2 class="panel-title">Edit/Copy a device</h2> <h2 class="panel-title">Edit/Copy a device</h2>
</div> </div>
<p class="text-muted">This screen allows the modification of many fields the bridge uses. Please use care when <div class="panel-body">
updating these fields as you may break the settings used by the bridge to call a specific end point device.</p> <p class="text-muted">This screen allows the modification of many
<p>When copying, update the name and select the "Add Bridge Device" Button.</p> fields the bridge uses. Please use care when updating these fields as
<ul class="list-group"> you may break the settings used by the bridge to call a specific end
<li class="list-group-item"> point device.</p>
<form class="form-horizontal"> <p>When copying, update the name and select the "Add Bridge
<div class="form-group"> Device" Button.</p>
<label class="col-xs-12 col-sm-2 control-label" for="device-name">Name </div>
</label> <form class="form-horizontal">
<div class="form-group">
<label class="col-xs-12 col-sm-2 control-label" for="device-name">Name
</label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<input type="text" class="form-control" id="device-name" <input type="text" class="form-control" id="device-name"
ng-model="device.name" placeholder="Device Name"> ng-model="device.name" placeholder="Device Name">
</div> </div>
<button type="submit" class="col-xs-4 col-sm-2 btn btn-success" ng-click="addDevice()"> <button type="submit" class="col-xs-4 col-sm-2 btn btn-success"
Update Bridge Device</button> ng-click="addDevice()">Update Bridge Device</button>
</div> </div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-12 col-sm-2 control-label" for="device-target">Target <label class="col-xs-12 col-sm-2 control-label" for="device-target">Target
</label> </label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<input type="text" class="form-control" id="device-target" <input type="text" class="form-control" id="device-target"
ng-model="device.targetDevice" placeholder="default"> ng-model="device.targetDevice" placeholder="default">
</div> </div>
<button class="btn btn-primary" ng-click="copyDevice()"> <button class="btn btn-primary" ng-click="copyDevice()">Add
Add Bridge Device</button> Bridge Device</button>
</div> </div>
<div class="form-group"> <div class="form-group">
<div class="row"> <div class="row">
<label class="col-xs-12 col-sm-2 control-label" for="device-type">Device Type <label class="col-xs-12 col-sm-2 control-label" for="device-type">Device
</label> Type </label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<select name="device-type" id="device-type" ng-model="device.deviceType"> <select name="device-type" id="device-type"
<option value="">---Types if needed---</option> <!-- not selected / blank option --> ng-model="device.deviceType">
<option value="custom">Custom</option> <option value="">---Types if needed---</option>
<option value="UDP">UDP</option> <!-- not selected / blank option -->
<option value="TCP">TCP</option> <option value="custom">Custom</option>
<option value="exec">Execute Script/Program</option> <option value="UDP">UDP</option>
<option value="switch">Switch</option> <option value="TCP">TCP</option>
<option value="scene">Scene</option> <option value="exec">Execute Script/Program</option>
<option value="activity">Activity</option> <option value="switch">Switch</option>
<option value="button">Button</option> <option value="scene">Scene</option>
<option value="thermo">Thermo</option> <option value="activity">Activity</option>
<option value="passthru">Pass Thru</option> <option value="button">Button</option>
</select> <option value="thermo">Thermo</option>
</div> <option value="passthru">Pass Thru</option>
</div> </select>
</div> </div>
<div class="form-group"> </div>
<div class="row"> </div>
<label class="col-xs-12 col-sm-2 control-label" for="device-map-type">Map Type <div class="form-group">
</label> <div class="row">
<label class="col-xs-12 col-sm-2 control-label"
for="device-map-type">Map Type </label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<select name="device-map-type" id="device-map-type" ng-model="device.mapType"> <select name="device-map-type" id="device-map-type"
<option value="">---Please select---</option> <!-- not selected / blank option --> ng-model="device.mapType">
<option value="veraDevice">Vera Device</option> <option value="">---Please select---</option>
<option value="veraScene">Vera Scene</option> <!-- not selected / blank option -->
<option value="harmonyActivity">Harmony Activity</option> <option value="veraDevice">Vera Device</option>
<option value="harmonyButton">Harmony Button</option> <option value="veraScene">Vera Scene</option>
<option value="nestHomeAway">Nest Home Status</option> <option value="harmonyActivity">Harmony Activity</option>
<option value="nestThermoSet">Nest Thermostat</option> <option value="harmonyButton">Harmony Button</option>
<option value="hueDevice">Hue Device</option> <option value="nestHomeAway">Nest Home Status</option>
</select> <option value="nestThermoSet">Nest Thermostat</option>
</div> <option value="hueDevice">Hue Device</option>
<button class="btn btn-danger" ng-click="clearDevice()"> </select>
Clear Device</button>
</div>
</div> </div>
<div ng-if="device.mapType" class="form-group"> <button class="btn btn-danger" ng-click="clearDevice()">
<label class="col-xs-12 col-sm-2 control-label" for="device-map-id">Map ID Clear Device</button>
</label> </div>
</div>
<div ng-if="device.mapType" class="form-group">
<label class="col-xs-12 col-sm-2 control-label" for="device-map-id">Map
ID </label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<input type="text" class="form-control" id="device-map-id" <input type="text" class="form-control" id="device-map-id"
ng-model="device.mapId" placeholder="1111"> ng-model="device.mapId" placeholder="1111">
</div> </div>
</div> </div>
<div class="form-group"> <div class="form-group">
<div class="row"> <div class="row">
<label class="col-xs-12 col-sm-2 control-label" for="device-on-url">On <label class="col-xs-12 col-sm-2 control-label" for="device-on-url">On
URL </label> URL </label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<textarea rows="3" class="form-control" id="device-on-url" <textarea rows="3" class="form-control" id="device-on-url"
ng-model="device.onUrl" placeholder="URL to turn device on"></textarea> ng-model="device.onUrl" placeholder="URL to turn device on"></textarea>
</div>
</div>
</div> </div>
<div class="form-group"> </div>
<div class="row"> </div>
<label class="col-xs-12 col-sm-2 control-label" for="device-dim-url">Dim <div class="form-group">
URL </label> <div class="row">
<label class="col-xs-12 col-sm-2 control-label" for="device-dim-url">Dim
URL </label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<textarea rows="3" class="form-control" id="device-dim-url" <textarea rows="3" class="form-control" id="device-dim-url"
ng-model="device.dimUrl" placeholder="URL to dim device"></textarea> ng-model="device.dimUrl" placeholder="URL to dim device"></textarea>
</div>
</div>
</div> </div>
<div class="form-group"> </div>
<div class="row"> </div>
<label class="col-xs-12 col-sm-2 control-label" <div class="form-group">
for="device-off-url">Off URL </label> <div class="row">
<label class="col-xs-12 col-sm-2 control-label" for="device-off-url">Off
URL </label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<textarea rows="3" class="form-control" id="device-off-url" <textarea rows="3" class="form-control" id="device-off-url"
ng-model="device.offUrl" placeholder="URL to turn device off"></textarea> ng-model="device.offUrl" placeholder="URL to turn device off"></textarea>
</div>
</div>
</div> </div>
<div class="form-group"> </div>
<div class="row"> </div>
<label class="col-xs-12 col-sm-2 control-label" <div class="form-group">
for="device-headers">HTTP Headers </label> <div class="row">
<label class="col-xs-12 col-sm-2 control-label" for="device-headers">HTTP
Headers </label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<textarea rows="3" class="form-control" id="device-headers" <textarea rows="3" class="form-control" id="device-headers"
ng-model="device.headers" placeholder="format like: [{&quot;name&quot;:&quot;A name&quot;,&quot;value&quot;:&quot;a value&quot;}]"></textarea> ng-model="device.headers"
</div> placeholder="format like: [{&quot;name&quot;:&quot;A name&quot;,&quot;value&quot;:&quot;a value&quot;}]"></textarea>
</div>
</div> </div>
<div class="form-group"> </div>
<div class="row"> </div>
<label class="col-xs-12 col-sm-2 control-label" for="device-http-verb">Http Verb <div class="form-group">
</label> <div class="row">
<label class="col-xs-12 col-sm-2 control-label"
for="device-http-verb">Http Verb </label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<select name="device-http-verb" id="device-http-verb" ng-model="device.httpVerb"> <select name="device-http-verb" id="device-http-verb"
<option value="">---Please select---</option> <!-- not selected / blank option --> ng-model="device.httpVerb">
<option value="GET">GET</option> <option value="">---Please select---</option>
<option value="PUT">PUT</option> <!-- not selected / blank option -->
<option value="POST">POST</option> <option value="GET">GET</option>
</select> <option value="PUT">PUT</option>
</div> <option value="POST">POST</option>
</div> </select>
</div> </div>
<div ng-if="device.httpVerb" class="form-group"> </div>
<div class="row"> </div>
<label class="col-xs-12 col-sm-2 control-label" for="device-content-type">Content Type <div ng-if="device.httpVerb" class="form-group">
</label> <div class="row">
<label class="col-xs-12 col-sm-2 control-label"
for="device-content-type">Content Type </label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<select name="device-content-type" id="device-content-type" ng-model="device.contentType"> <select name="device-content-type" id="device-content-type"
<option value="">---Please select---</option> <!-- not selected / blank option --> ng-model="device.contentType">
<option value="application/atom+xml">application/atom+xml</option> <option value="">---Please select---</option>
<option value="application/x-www-form-urlencoded">application/x-www-form-urlencoded</option> <!-- not selected / blank option -->
<option value="application/json">application/json</option> <option value="application/atom+xml">application/atom+xml</option>
<option value="application/octet-stream">application/octet-stream</option> <option value="application/x-www-form-urlencoded">application/x-www-form-urlencoded</option>
<option value="application/svg+xml">application/svg+xml</option> <option value="application/json">application/json</option>
<option value="application/xhtml+xml">application/xhtml+xml</option> <option value="application/octet-stream">application/octet-stream</option>
<option value="application/xml">application/xml</option> <option value="application/svg+xml">application/svg+xml</option>
<option value="*">*</option> <option value="application/xhtml+xml">application/xhtml+xml</option>
<option value="multipart/form-data">multipart/form-data</option> <option value="application/xml">application/xml</option>
<option value="text/html">text/html</option> <option value="*">*</option>
<option value="text/plain">text/plain</option> <option value="multipart/form-data">multipart/form-data</option>
<option value="text/xml">text/xml</option> <option value="text/html">text/html</option>
<option value="*/*">*/*</option> <option value="text/plain">text/plain</option>
</select> <option value="text/xml">text/xml</option>
</div> <option value="*/*">*/*</option>
</div> </select>
</div> </div>
<div ng-if="device.httpVerb" class="form-group"> </div>
<div class="row"> </div>
<label class="col-xs-12 col-sm-2 control-label" <div ng-if="device.httpVerb" class="form-group">
for="device-content-body">Content Body On</label> <div class="row">
<label class="col-xs-12 col-sm-2 control-label"
for="device-content-body">Content Body On</label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<textarea rows="3" class="form-control" id="device-content-body" <textarea rows="3" class="form-control" id="device-content-body"
ng-model="device.contentBody" placeholder="Content Body On for specific GET/PUT/POST type"></textarea> ng-model="device.contentBody"
</div> placeholder="Content Body On for specific GET/PUT/POST type"></textarea>
<div class="clearfix visible-xs"></div>
</div>
</div> </div>
<div ng-if="device.httpVerb" class="form-group"> <div class="clearfix visible-xs"></div>
<div class="row"> </div>
<label class="col-xs-12 col-sm-2 control-label" </div>
for="device-content-body-off">Content Body Off</label> <div ng-if="device.httpVerb" class="form-group">
<div class="row">
<label class="col-xs-12 col-sm-2 control-label"
for="device-content-body-off">Content Body Off</label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<textarea rows="3" class="form-control" id="device-content-body-off" <textarea rows="3" class="form-control"
ng-model="device.contentBodyOff" placeholder="Content Body Off for specific GET/PUT/POST type"></textarea> id="device-content-body-off" ng-model="device.contentBodyOff"
</div> placeholder="Content Body Off for specific GET/PUT/POST type"></textarea>
<div class="clearfix visible-xs"></div>
</div>
</div> </div>
</form> <div class="clearfix visible-xs"></div>
</li> </div>
</ul> </div>
</form>
</div> </div>

View File

@@ -1,231 +1,250 @@
<ul class="nav nav-pills" role="tablist"> <ul class="nav nav-pills" role="tablist">
<li role="presentation"><a href="#">Bridge Devices</a></li> <li role="presentation"><a href="#">Bridge Devices</a></li>
<li role="presentation"><a href="#/system">Bridge Control</a></li> <li role="presentation"><a href="#/system">Bridge Control</a></li>
<li role="presentation"><a href="#/logs">Logs</a></li> <li role="presentation"><a href="#/logs">Logs</a></li>
<li ng-if="bridge.showVera" role="presentation"><a href="#/veradevices">Vera Devices</a></li> <li ng-if="bridge.showVera" role="presentation"><a
<li ng-if="bridge.showVera" role="presentation"><a href="#/verascenes">Vera Scenes</a></li> href="#/veradevices">Vera Devices</a></li>
<li ng-if="bridge.showHarmony" role="presentation"><a href="#/harmonyactivities">Harmony Activities</a></li> <li ng-if="bridge.showVera" role="presentation"><a
<li ng-if="bridge.showHarmony" role="presentation"><a href="#/harmonydevices">Harmony Devices</a></li> href="#/verascenes">Vera Scenes</a></li>
<li ng-if="bridge.showNest" role="presentation"><a href="#/nest">Nest</a></li> <li ng-if="bridge.showHarmony" role="presentation"><a
<li ng-if="bridge.showHue" role="presentation"><a href="#/huedevices">Hue Devices</a></li> href="#/harmonyactivities">Harmony Activities</a></li>
<li ng-if="bridge.showHal" role="presentation"><a href="#/haldevices">HAL Devices</a></li> <li ng-if="bridge.showHarmony" role="presentation"><a
<li role="presentation" class="active"><a href="#/editor">Manual Add</a></li> href="#/harmonydevices">Harmony Devices</a></li>
</ul> <li ng-if="bridge.showNest" role="presentation"><a href="#/nest">Nest</a></li>
<li ng-if="bridge.showHue" role="presentation"><a
href="#/huedevices">Hue Devices</a></li>
<li ng-if="bridge.showHal" role="presentation"><a
href="#/haldevices">HAL Devices</a></li>
<li role="presentation" class="active"><a href="#/editor">Manual
Add</a></li>
</ul>
<div class="panel panel-default bridgeServer" ng-if="bridge.showVera"> <div ng-if="bridge.showVera" class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
<h2 class="panel-title">Generate a new device/scene/control point</h2> <h2 class="panel-title">Generate a new device/scene/control point</h2>
</div> </div>
<ul class="list-group"> <div class="panel-body">
<li class="list-group-item"> <p class="text-muted">You can generate on/off URLs by filling in
<p class="text-muted">You can generate on/off URLs by filling in the Vera server URL, port, and device ID; or you can fill them out
the Vera server URL, port, and device ID; or you can fill them out manually in the lower section.</p>
manually in the lower section.</p> </div>
<form class="form-horizontal">
<div class="form-group">
<label class="col-xs-12 col-sm-2 control-label" for="vera-base">Vera
Server URL </label>
<form class="form-horizontal"> <div class="col-xs-8 col-sm-7">
<div class="form-group"> <input type="text" class="form-control" id="vera-base"
<label class="col-xs-12 col-sm-2 control-label" for="vera-base">Vera ng-model="vera.base"
Server URL </label> placeholder="Vera URL (e.g. http://192.168.1.100)">
</div>
</div>
<div class="form-group">
<label class="col-xs-2 col-sm-2 control-label" for="vera-port">Vera
Request Port </label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-10 col-sm-2">
<input type="text" class="form-control" id="vera-base" <input type="text" class="form-control" id="vera-port"
ng-model="vera.base" ng-model="vera.port" placeholder="Vera Port (typically 3480)">
placeholder="Vera URL (e.g. http://192.168.1.100)"> </div>
</div>
</div>
<div class="form-group">
<label class="col-xs-2 col-sm-2 control-label" for="vera-port">Vera
Request Port </label>
<div class="col-xs-10 col-sm-2"> <label class="col-xs-2 col-sm-2 control-label" for="vera-id">Device
<input type="text" class="form-control" id="vera-port" ID </label>
ng-model="vera.port" placeholder="Vera Port (typically 3480)">
</div>
<label class="col-xs-2 col-sm-2 control-label" for="vera-id">Device <div class="col-xs-10 col-sm-2">
ID </label> <input type="text" class="form-control" id="vera-id"
ng-model="vera.id" placeholder="ID">
</div>
</div>
<div class="form-group">
<label class="col-xs-2 col-sm-2 control-label"
for="device-dim-control">Device Dim Control</label>
<div class="col-xs-10 col-sm-2"> <div class="col-xs-10 col-sm-2">
<input type="text" class="form-control" id="vera-id" <select name="device-dim-control" id="device-dim-control"
ng-model="vera.id" placeholder="ID"> ng-model="device_dim_control">
</div> <option value="">none</option>
</div> <option value="${intensity..byte}">Pass-thru Value</option>
<div class="form-group"> <option value="${intensity.percent}">Percentage</option>
<label class="col-xs-2 col-sm-2 control-label" for="device-dim-control">Device Dim Control</label> <option value="${intensity.math(X*1)}">Custom Math</option>
</select>
<div class="col-xs-10 col-sm-2"> </div>
<select name="device-dim-control" id="device-dim-control" ng-model="device_dim_control"> </div>
<option value="">none</option> <div class="form-group">
<option value="${intensity..byte}">Pass-thru Value</option> <button type="submit"
<option value="${intensity.percent}">Percentage</option> ng-click="buildUrlsUsingDevice(device_dim_control)"
<option value="${intensity.math(X*1)}">Custom Math</option> class="col-xs-2 col-sm-2 col-xs-offset-2 col-sm-offset-2 btn btn-success">Generate
</select> Device URLs</button>
</div> <button type="submit" ng-click="buildUrlsUsingScene()"
</div> class="col-xs-2 col-sm-2 col-xs-offset-2 col-sm-offset-2 btn btn-success">Generate
<div class="form-group"> Scene URLs</button>
<button type="submit" ng-click="buildUrlsUsingDevice(device_dim_control)" </div>
class="col-xs-2 col-sm-2 col-xs-offset-2 col-sm-offset-2 btn btn-success">Generate Device </form>
URLs</button>
<button type="submit" ng-click="buildUrlsUsingScene()"
class="col-xs-2 col-sm-2 col-xs-offset-2 col-sm-offset-2 btn btn-success">Generate Scene
URLs</button>
</div>
</form>
</li>
</ul>
</div> </div>
<div class="panel panel-default bridgeServer" ng-if="!bridge.error"> <div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
<h2 class="panel-title">Add a new device</h2> <h2 class="panel-title">Add a new device</h2>
</div> </div>
<p class="text-muted">This area allows you to create any http or udp call to an endpoint. You can use the default GET or select <div class="panel-body">
the http verb type below and configure a payload for either on, dim or off methods. Currently, https is not supported. For Execution of <p class="text-muted">This area allows you to create any http or
a script or program, plese fill in the path. All manually entered calls can use Json notation of array with udp call to an endpoint. You can use the default GET or select the
[{&quot;item&quot;:&quot;the payload&quot;},{&quot;item&quot;:&quot;another payload&quot;}] to execute multiple entries. Adding the value replacements (${intensity..byte},${intensity.percent},${intensity.math(X*1)}) http verb type below and configure a payload for either on, dim or
will also work.</p> off methods. Currently, https is not supported. For Execution of a
<ul class="list-group"> script or program, plese fill in the path. All manually entered calls
<li class="list-group-item"> can use Json notation of array with [{&quot;item&quot;:&quot;the
<form class="form-horizontal"> payload&quot;},{&quot;item&quot;:&quot;another payload&quot;}] to
<div class="form-group"> execute multiple entries. Adding the value replacements
<div class="row"> (${intensity..byte},${intensity.percent},${intensity.math(X*1)}) will
<label class="col-xs-12 col-sm-2 control-label" for="device-name">Name also work.</p>
</label> </div>
<form class="form-horizontal">
<div class="form-group">
<div class="row">
<label class="col-xs-12 col-sm-2 control-label" for="device-name">Name
</label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<input type="text" class="form-control" id="device-name" <input type="text" class="form-control" id="device-name"
ng-model="device.name" placeholder="Device Name"> ng-model="device.name" placeholder="Device Name">
</div>
<button type="submit" class="col-xs-4 col-sm-2 btn btn-primary" ng-click="addDevice()">
Add Bridge Device</button>
</div>
</div> </div>
<div class="form-group"> <button type="submit" class="col-xs-4 col-sm-2 btn btn-primary"
<div class="row"> ng-click="addDevice()">Add Bridge Device</button>
<label class="col-xs-12 col-sm-2 control-label" for="device-type">Device Type </div>
</label> </div>
<div class="form-group">
<div class="row">
<label class="col-xs-12 col-sm-2 control-label" for="device-type">Device
Type </label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<select name="device-type" id="device-type" ng-model="device.deviceType"> <select name="device-type" id="device-type"
<option value="">---Types if needed---</option> <!-- not selected / blank option --> ng-model="device.deviceType">
<option value="custom">Custom</option> <option value="">---Types if needed---</option>
<option value="UDP">UDP</option> <!-- not selected / blank option -->
<option value="TCP">TCP</option> <option value="custom">Custom</option>
<option value="exec">Execute Script/Program</option> <option value="UDP">UDP</option>
</select> <option value="TCP">TCP</option>
</div> <option value="exec">Execute Script/Program</option>
</div> </select>
</div> </div>
<div class="form-group"> </div>
<div class="row"> </div>
<label class="col-xs-12 col-sm-2 control-label" for="device-on-url">On <div class="form-group">
URL </label> <div class="row">
<label class="col-xs-12 col-sm-2 control-label" for="device-on-url">On
URL </label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<textarea rows="3" class="form-control" id="device-on-url" <textarea rows="3" class="form-control" id="device-on-url"
ng-model="device.onUrl" placeholder="URL to turn device on"></textarea> ng-model="device.onUrl" placeholder="URL to turn device on"></textarea>
</div>
<button class="btn btn-danger" ng-click="clearDevice()">
Clear Device</button>
</div>
</div> </div>
<div class="form-group"> <button class="btn btn-danger" ng-click="clearDevice()">
<div class="row"> Clear Device</button>
<label class="col-xs-12 col-sm-2 control-label" for="device-dim-url">Dim </div>
URL </label> </div>
<div class="form-group">
<div class="row">
<label class="col-xs-12 col-sm-2 control-label" for="device-dim-url">Dim
URL </label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<textarea rows="3" class="form-control" id="device-dim-url" <textarea rows="3" class="form-control" id="device-dim-url"
ng-model="device.dimUrl" placeholder="URL to dim device"></textarea> ng-model="device.dimUrl" placeholder="URL to dim device"></textarea>
</div>
</div>
</div> </div>
<div class="form-group"> </div>
<div class="row"> </div>
<label class="col-xs-12 col-sm-2 control-label" <div class="form-group">
for="device-off-url">Off URL </label> <div class="row">
<label class="col-xs-12 col-sm-2 control-label" for="device-off-url">Off
URL </label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<textarea rows="3" class="form-control" id="device-off-url" <textarea rows="3" class="form-control" id="device-off-url"
ng-model="device.offUrl" placeholder="URL to turn device off"></textarea> ng-model="device.offUrl" placeholder="URL to turn device off"></textarea>
</div>
</div>
</div> </div>
<div class="form-group"> </div>
<div class="row"> </div>
<label class="col-xs-12 col-sm-2 control-label" <div class="form-group">
for="device-headers">HTTP Headers </label> <div class="row">
<label class="col-xs-12 col-sm-2 control-label" for="device-headers">HTTP
Headers </label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<textarea rows="3" class="form-control" id="device-headers" <textarea rows="3" class="form-control" id="device-headers"
ng-model="device.headers" placeholder="format like: [{&quot;name&quot;:&quot;A name&quot;,&quot;value&quot;:&quot;a value&quot;}]"></textarea> ng-model="device.headers"
</div> placeholder="format like: [{&quot;name&quot;:&quot;A name&quot;,&quot;value&quot;:&quot;a value&quot;}]"></textarea>
</div>
</div> </div>
<div class="form-group"> </div>
<div class="row"> </div>
<label class="col-xs-12 col-sm-2 control-label" for="device-http-verb">Http Verb <div class="form-group">
</label> <div class="row">
<label class="col-xs-12 col-sm-2 control-label"
for="device-http-verb">Http Verb </label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<select name="device-http-verb" id="device-http-verb" ng-model="device.httpVerb"> <select name="device-http-verb" id="device-http-verb"
<option value="">---Please select---</option> <!-- not selected / blank option --> ng-model="device.httpVerb">
<option value="GET">GET</option> <option value="">---Please select---</option>
<option value="PUT">PUT</option> <!-- not selected / blank option -->
<option value="POST">POST</option> <option value="GET">GET</option>
</select> <option value="PUT">PUT</option>
</div> <option value="POST">POST</option>
</div> </select>
</div> </div>
<div ng-if="device.httpVerb" class="form-group"> </div>
<div class="row"> </div>
<label class="col-xs-12 col-sm-2 control-label" for="device-content-type">Content Type <div ng-if="device.httpVerb" class="form-group">
</label> <div class="row">
<label class="col-xs-12 col-sm-2 control-label"
for="device-content-type">Content Type </label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<select name="device-content-type" id="device-content-type" ng-model="device.contentType"> <select name="device-content-type" id="device-content-type"
<option value="">---Please select---</option> <!-- not selected / blank option --> ng-model="device.contentType">
<option value="application/atom+xml">application/atom+xml</option> <option value="">---Please select---</option>
<option value="application/x-www-form-urlencoded">application/x-www-form-urlencoded</option> <!-- not selected / blank option -->
<option value="application/json">application/json</option> <option value="application/atom+xml">application/atom+xml</option>
<option value="application/octet-stream">application/octet-stream</option> <option value="application/x-www-form-urlencoded">application/x-www-form-urlencoded</option>
<option value="application/svg+xml">application/svg+xml</option> <option value="application/json">application/json</option>
<option value="application/xhtml+xml">application/xhtml+xml</option> <option value="application/octet-stream">application/octet-stream</option>
<option value="application/xml">application/xml</option> <option value="application/svg+xml">application/svg+xml</option>
<option value="*">*</option> <option value="application/xhtml+xml">application/xhtml+xml</option>
<option value="multipart/form-data">multipart/form-data</option> <option value="application/xml">application/xml</option>
<option value="text/html">text/html</option> <option value="*">*</option>
<option value="text/plain">text/plain</option> <option value="multipart/form-data">multipart/form-data</option>
<option value="text/xml">text/xml</option> <option value="text/html">text/html</option>
<option value="*/*">*/*</option> <option value="text/plain">text/plain</option>
</select> <option value="text/xml">text/xml</option>
</div> <option value="*/*">*/*</option>
</div> </select>
</div> </div>
<div ng-if="device.httpVerb" class="form-group"> </div>
<div class="row"> </div>
<label class="col-xs-12 col-sm-2 control-label" <div ng-if="device.httpVerb" class="form-group">
for="device-content-body">Content Body On</label> <div class="row">
<label class="col-xs-12 col-sm-2 control-label"
for="device-content-body">Content Body On</label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<textarea rows="3" class="form-control" id="device-content-body" <textarea rows="3" class="form-control" id="device-content-body"
ng-model="device.contentBody" placeholder="Content Body On for specific GET/PUT/POST type"></textarea> ng-model="device.contentBody"
</div> placeholder="Content Body On for specific GET/PUT/POST type"></textarea>
<div class="clearfix visible-xs"></div>
</div>
</div> </div>
<div ng-if="device.httpVerb" class="form-group"> <div class="clearfix visible-xs"></div>
<div class="row"> </div>
<label class="col-xs-12 col-sm-2 control-label" </div>
for="device-content-body-off">Content Body Off</label> <div ng-if="device.httpVerb" class="form-group">
<div class="row">
<label class="col-xs-12 col-sm-2 control-label"
for="device-content-body-off">Content Body Off</label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<textarea rows="3" class="form-control" id="device-content-body-off" <textarea rows="3" class="form-control"
ng-model="device.contentBodyOff" placeholder="Content Body Off for specific GET/PUT/POST type"></textarea> id="device-content-body-off" ng-model="device.contentBodyOff"
</div> placeholder="Content Body Off for specific GET/PUT/POST type"></textarea>
<div class="clearfix visible-xs"></div>
</div>
</div> </div>
</form> <div class="clearfix visible-xs"></div>
</li> </div>
</ul> </div>
</form>
</div> </div>

View File

@@ -1,118 +1,135 @@
<ul class="nav nav-pills" role="tablist"> <ul class="nav nav-pills" role="tablist">
<li role="presentation"><a href="#">Bridge Devices</a></li> <li role="presentation"><a href="#">Bridge Devices</a></li>
<li role="presentation"><a href="#/system">Bridge Control</a></li> <li role="presentation"><a href="#/system">Bridge Control</a></li>
<li role="presentation"><a href="#/logs">Logs</a></li> <li role="presentation"><a href="#/logs">Logs</a></li>
<li ng-if="bridge.showVera" role="presentation"><a href="#/veradevices">Vera Devices</a></li> <li ng-if="bridge.showVera" role="presentation"><a
<li ng-if="bridge.showVera" role="presentation"><a href="#/verascenes">Vera Scenes</a></li> href="#/veradevices">Vera Devices</a></li>
<li ng-if="bridge.showHarmony" role="presentation"><a href="#/harmonyactivities">Harmony Activities</a></li> <li ng-if="bridge.showVera" role="presentation"><a
<li ng-if="bridge.showHarmony" role="presentation"><a href="#/harmonydevices">Harmony Devices</a></li> href="#/verascenes">Vera Scenes</a></li>
<li ng-if="bridge.showNest" role="presentation"><a href="#/nest">Nest</a></li> <li ng-if="bridge.showHarmony" role="presentation"><a
<li ng-if="bridge.showHue" role="presentation"><a href="#/huedevices">Hue Devices</a></li> href="#/harmonyactivities">Harmony Activities</a></li>
<li role="presentation" class="active"><a href="#/haldevices">HAL Devices</a></li> <li ng-if="bridge.showHarmony" role="presentation"><a
<li role="presentation"><a href="#/editor">Manual Add</a></li> href="#/harmonydevices">Harmony Devices</a></li>
</ul> <li ng-if="bridge.showNest" role="presentation"><a href="#/nest">Nest</a></li>
<li ng-if="bridge.showHue" role="presentation"><a
href="#/huedevices">Hue Devices</a></li>
<li role="presentation" class="active"><a href="#/haldevices">HAL
Devices</a></li>
<li role="presentation"><a href="#/editor">Manual Add</a></li>
</ul>
<div class="panel panel-default bridgeServer"> <div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
<h2 class="panel-title">HAL Device List ({{bridge.haldevices.length}})</h2> <h2 class="panel-title">HAL Device List
({{bridge.haldevices.length}})</h2>
</div> </div>
<ul class="list-group"> <div class="panel-body">
<li class="list-group-item"> <p class="text-muted">For any HAL Device, use the action buttons
<p class="text-muted">For any HAL Device, use the action buttons to generate the device addition information below automatically. to generate the device addition information below automatically. Then
Then you can modify the name to anything you want that will be the keyword for Alexa. Click the 'Add Bridge Device' to finish that selection setup. you can modify the name to anything you want that will be the keyword
The 'Already Configured HAL Devices' list below will show what is already setup for your HAL.</p> for Alexa. Click the 'Add Bridge Device' to finish that selection
<p>Also, use this select menu for which type of dim setup. The 'Already Configured HAL Devices' list below will show what
control you would like to be generated: is already setup for your HAL.</p>
<select name="device-dim-control" id="device-dim-control" ng-model="device_dim_control"> <p>
<option value="">none</option> Also, use this select menu for which type of dim control you would
<option value="${intensity.byte}">Pass-thru Value</option> like to be generated: <select name="device-dim-control"
<option value="${intensity.percent}">Percentage</option> id="device-dim-control" ng-model="device_dim_control">
<option value="${intensity.math(X*1)}">Custom Math</option> <option value="">none</option>
</select> <option value="${intensity.byte}">Pass-thru Value</option>
</p> <option value="${intensity.percent}">Percentage</option>
<p>Use the check boxes by the names to use the bulk addition feature. Select your items and dim control type if wanted, then click bulk add below. <option value="${intensity.math(X*1)}">Custom Math</option>
Your items will be added with on and off or dim and off if selected with the name of the device from the HAL. </select>
</p> </p>
<scrollable-table watch="bridge.haldevices"> <p>Use the check boxes by the names to use the bulk addition
<table class="table table-bordered table-striped table-hover"> feature. Select your items and dim control type if wanted, then click
<thead> bulk add below. Your items will be added with on and off or dim and
<tr> off if selected with the name of the device from the HAL.</p>
<th>Row</th> </div>
<th sortable-header col="name">Name</th> <scrollable-table watch="bridge.haldevices">
<th sortable-header col="category">Category</th> <table class="table table-bordered table-striped table-hover">
<th sortable-header col="halname">HAL</th> <thead>
<th>Actions</th> <tr>
</tr> <th>Row</th>
</thead> <th sortable-header col="name">Name</th>
<tr ng-repeat="haldevice in bridge.haldevices | availableHalDeviceId"> <th sortable-header col="category">Category</th>
<td>{{$index+1}}</td> <th sortable-header col="halname">HAL</th>
<td><input type="checkbox" name="bulk.devices[]" value="{{haldevice.haldevicename}}" ng-checked="bulk.devices.indexOf(haldevice.haldevicename) > -1" ng-click="toggleSelection(haldevice.haldevicename)"> {{haldevice.haldevicename}}</td> <th>Actions</th>
<td>{{haldevice.haldevicetype}}</td> </tr>
<td>{{haldevice.halname}}</td> </thead>
<td> <tr ng-repeat="haldevice in bridge.haldevices | availableHalDeviceId">
<button class="btn btn-success" type="submit" <td>{{$index+1}}</td>
ng-click="buildDeviceUrls(haldevice, device_dim_control)">Generate Bridge Device</button> <td><input type="checkbox" name="bulk.devices[]"
</td> value="{{haldevice.haldevicename}}"
</tr> ng-checked="bulk.devices.indexOf(haldevice.haldevicename) > -1"
</table> ng-click="toggleSelection(haldevice.haldevicename)">
</scrollable-table> {{haldevice.haldevicename}}</td>
<p> <td>{{haldevice.haldevicetype}}</td>
<td>{{haldevice.halname}}</td>
<td>
<button class="btn btn-success" type="submit" <button class="btn btn-success" type="submit"
ng-click="bulkAddDevices(device_dim_control)">Bulk Add ({{bulk.devices.length}})</button> ng-click="buildDeviceUrls(haldevice, device_dim_control)">Generate
</p> Bridge Device</button>
</li> </td>
</ul> </tr>
<div class="panel-heading"> </table>
<h2 class="panel-title">Already Configured HAL Devices <a ng-click="toggleButtons()"><span class={{imgButtonsUrl}} aria-hidden="true"></span></a></a></h2> </scrollable-table>
<div class="panel-footer">
<button class="btn btn-success" type="submit"
ng-click="bulkAddDevices(device_dim_control)">Bulk Add
({{bulk.devices.length}})</button>
</div> </div>
<ul ng-if="buttonsVisible" class="list-group">
<li class="list-group-item">
<scrollable-table watch="bridge.haldevices">
<table class="table table-bordered table-striped table-hover">
<thead>
<tr>
<th>Row</th>
<th sortable-header col="name">Name</th>
<th sortable-header col="category">Category</th>
<th sortable-header col="halname">HAL</th>
<th>Actions</th>
</tr>
</thead>
<tr ng-repeat="haldevice in bridge.haldevices | unavailableHalDeviceId">
<td>{{$index+1}}</td>
<td>{{haldevice.haldevicename}}</td>
<td>{{haldevice.haldevicetype}}</td>
<td>{{haldevice.halname}}</td>
<td>
<button class="btn btn-danger" type="submit"
ng-click="deleteDeviceByMapId(haldevice.haldevicename, 'halDevice')">Delete</button>
</td>
</tr>
</table>
</scrollable-table>
</li>
</ul>
</div> </div>
<div class="panel panel-default bridgeServer"> <div class="panel panel-default">
<div class="panel-heading">
<h2 class="panel-title">
Already Configured HAL Devices <a ng-click="toggleButtons()"><span
class={{imgButtonsUrl}} aria-hidden="true"></span></a></a>
</h2>
</div>
<scrollable-table ng-if="buttonsVisible" watch="bridge.haldevices">
<table class="table table-bordered table-striped table-hover">
<thead>
<tr>
<th>Row</th>
<th sortable-header col="name">Name</th>
<th sortable-header col="category">Category</th>
<th sortable-header col="halname">HAL</th>
<th>Actions</th>
</tr>
</thead>
<tr
ng-repeat="haldevice in bridge.haldevices | unavailableHalDeviceId">
<td>{{$index+1}}</td>
<td>{{haldevice.haldevicename}}</td>
<td>{{haldevice.haldevicetype}}</td>
<td>{{haldevice.halname}}</td>
<td>
<button class="btn btn-danger" type="submit"
ng-click="deleteDeviceByMapId(haldevice.haldevicename, haldevice.halname, 'halDevice')">Delete</button>
</td>
</tr>
</table>
</scrollable-table>
</div>
<div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
<h2 class="panel-title">Add Bridge Device for a HAL Device</h2> <h2 class="panel-title">Add Bridge Device for a HAL Device</h2>
</div> </div>
<ul class="list-group"> <div class="panel-body">
<li class="list-group-item"> <form class="form-horizontal">
<form class="form-horizontal"> <div class="form-group">
<div class="form-group"> <label class="col-xs-12 col-sm-2 control-label" for="device-name">Name
<label class="col-xs-12 col-sm-2 control-label" for="device-name">Name </label>
</label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<input type="text" class="form-control" id="device-name" <input type="text" class="form-control" id="device-name"
ng-model="device.name" placeholder="Device Name"> ng-model="device.name" placeholder="Device Name">
</div>
<button type="submit" class="col-xs-4 col-sm-2 btn btn-primary" ng-click="addDevice()">
Add Bridge Device</button>
</div> </div>
<div class="form-group"> <button type="submit" class="col-xs-4 col-sm-2 btn btn-primary"
<div class="row"> ng-click="addDevice()">Add Bridge Device</button>
</div>
<div class="form-group">
<div class="row">
<label class="col-xs-12 col-sm-2 control-label" for="device-on-url">On <label class="col-xs-12 col-sm-2 control-label" for="device-on-url">On
URL </label> URL </label>
@@ -125,30 +142,29 @@
</div> </div>
<div class="form-group"> <div class="form-group">
<div class="row"> <div class="row">
<label class="col-xs-12 col-sm-2 control-label" for="device-dim-url">Dim <label class="col-xs-12 col-sm-2 control-label"
URL </label> for="device-dim-url">Dim URL </label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<textarea rows="3" class="form-control" id="device-dim-url" <textarea rows="3" class="form-control" id="device-dim-url"
ng-model="device.dimUrl" placeholder="URL to dim device"></textarea> ng-model="device.dimUrl" placeholder="URL to dim device"></textarea>
</div> </div>
</div> </div>
</div> </div>
<div class="form-group"> <div class="form-group">
<div class="row"> <div class="row">
<label class="col-xs-12 col-sm-2 control-label" <label class="col-xs-12 col-sm-2 control-label"
for="device-off-url">Off URL </label> for="device-off-url">Off URL </label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<textarea rows="3" class="form-control" id="device-off-url" <textarea rows="3" class="form-control" id="device-off-url"
ng-model="device.offUrl" placeholder="URL to turn device off"></textarea> ng-model="device.offUrl" placeholder="URL to turn device off"></textarea>
</div>
</div> </div>
</div> </form>
</form> </div>
</li>
</ul>
</div> </div>
<script type="text/ng-template" id="deleteMapandIdDialog"> <script type="text/ng-template" id="deleteMapandIdDialog">
<div class="ngdialog-message"> <div class="ngdialog-message">
<h2>Device Map and Id?</h2> <h2>Device Map and Id?</h2>
<p>{{mapandid.mapType}} with {{mapandid.id}}</p> <p>{{mapandid.mapType}} with {{mapandid.id}}</p>

View File

@@ -1,101 +1,113 @@
<ul class="nav nav-pills" role="tablist"> <ul class="nav nav-pills" role="tablist">
<li role="presentation"><a href="#">Bridge Devices</a></li> <li role="presentation"><a href="#">Bridge Devices</a></li>
<li role="presentation"><a href="#/system">Bridge Control</a></li> <li role="presentation"><a href="#/system">Bridge Control</a></li>
<li role="presentation"><a href="#/logs">Logs</a></li> <li role="presentation"><a href="#/logs">Logs</a></li>
<li ng-if="bridge.showVera" role="presentation"><a href="#/veradevices">Vera Devices</a></li> <li ng-if="bridge.showVera" role="presentation"><a
<li ng-if="bridge.showVera" role="presentation"><a href="#/verascenes">Vera Scenes</a></li> href="#/veradevices">Vera Devices</a></li>
<li role="presentation" class="active"><a href="#/harmonyactivities">Harmony Activities</a></li> <li ng-if="bridge.showVera" role="presentation"><a
<li role="presentation"><a href="#/harmonydevices">Harmony Devices</a></li> href="#/verascenes">Vera Scenes</a></li>
<li ng-if="bridge.showNest" role="presentation"><a href="#/nest">Nest</a></li> <li role="presentation" class="active"><a
<li ng-if="bridge.showHue" role="presentation"><a href="#/huedevices">Hue Devices</a></li> href="#/harmonyactivities">Harmony Activities</a></li>
<li ng-if="bridge.showHal" role="presentation"><a href="#/haldevices">HAL Devices</a></li> <li role="presentation"><a href="#/harmonydevices">Harmony
<li role="presentation"><a href="#/editor">Manual Add</a></li> Devices</a></li>
</ul> <li ng-if="bridge.showNest" role="presentation"><a href="#/nest">Nest</a></li>
<li ng-if="bridge.showHue" role="presentation"><a
href="#/huedevices">Hue Devices</a></li>
<li ng-if="bridge.showHal" role="presentation"><a
href="#/haldevices">HAL Devices</a></li>
<li role="presentation"><a href="#/editor">Manual Add</a></li>
</ul>
<div class="panel panel-default bridgeServer"> <div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
<h2 class="panel-title">Harmony Activity List</h2> <h2 class="panel-title">Harmony Activity List</h2>
</div> </div>
<ul class="list-group"> <div class="panel-body">
<li class="list-group-item"> <p class="text-muted">For any Harmony Activity, use the action
<p class="text-muted">For any Harmony Activity, use the action buttons to generate the device addition information below automatically. buttons to generate the device addition information below
Then you can modify the name to anything you want that will be the keyword for Alexa. Click the 'Add Bridge Device' to finish that selection setup. automatically. Then you can modify the name to anything you want that
The 'Already Configured Activities' list below will show what is already setup for your Harmony Hubs.</p> will be the keyword for Alexa. Click the 'Add Bridge Device' to
finish that selection setup. The 'Already Configured Activities' list
<scrollable-table watch="bridge.harmonyactivities"> below will show what is already setup for your Harmony Hubs.</p>
<table class="table table-bordered table-striped table-hover">
<thead>
<tr>
<th>Row</th>
<th sortable-header col="name">Name</th>
<th sortable-header col="id">Id</th>
<th sortable-header col="hub">Hub</th>
<th>Actions</th>
</tr>
</thead>
<tr ng-repeat="harmonyactivity in bridge.harmonyactivities | availableHarmonyActivityId">
<td>{{$index+1}}</td>
<td>{{harmonyactivity.activity.label}}</td>
<td>{{harmonyactivity.activity.id}}</td>
<td>{{harmonyactivity.hub}}</td>
<td>
<button class="btn btn-success" type="submit"
ng-click="buildActivityUrls(harmonyactivity)">Generate Bridge Device</button>
</td>
</tr>
</table>
</scrollable-table>
</li>
</ul>
<div class="panel-heading">
<h2 class="panel-title">Already Configured Activities <a ng-click="toggleButtons()"><span class={{imgButtonsUrl}} aria-hidden="true"></span></a></h2>
</div> </div>
<ul ng-if="buttonsVisible" class="list-group">
<li class="list-group-item"> <scrollable-table watch="bridge.harmonyactivities">
<scrollable-table watch="bridge.harmonyactivities"> <table class="table table-bordered table-striped table-hover">
<table class="table table-bordered table-striped table-hover"> <thead>
<thead> <tr>
<tr> <th>Row</th>
<th>Row</th> <th sortable-header col="name">Name</th>
<th sortable-header col="name">Name</th> <th sortable-header col="id">Id</th>
<th sortable-header col="id">Id</th> <th sortable-header col="hub">Hub</th>
<th sortable-header col="hub">Hub</th> <th>Actions</th>
<th>Actions</th> </tr>
</tr> </thead>
</thead> <tr
<tr ng-repeat="harmonyactivity in bridge.harmonyactivities | unavailableHarmonyActivityId"> ng-repeat="harmonyactivity in bridge.harmonyactivities | availableHarmonyActivityId">
<td>{{$index+1}}</td> <td>{{$index+1}}</td>
<td>{{harmonyactivity.activity.label}}</td> <td>{{harmonyactivity.activity.label}}</td>
<td>{{harmonyactivity.activity.id}}</td> <td>{{harmonyactivity.activity.id}}</td>
<td>{{harmonyactivity.hub}}</td> <td>{{harmonyactivity.hub}}</td>
<td><button class="btn btn-danger" type="submit" <td>
ng-click="deleteDeviceByMapId(harmonyactivity.activity.id, 'harmonyActivity')">Delete</button></td> <button class="btn btn-success" type="submit"
</tr> ng-click="buildActivityUrls(harmonyactivity)">Generate
</table> Bridge Device</button>
</scrollable-table> </td>
</li> </tr>
</ul> </table>
</scrollable-table>
</div> </div>
<div class="panel panel-default bridgeServer"> <div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
<h2 class="panel-title">Add a Bridge Device for a Harmony Activity</h2> <h2 class="panel-title">
Already Configured Activities <a ng-click="toggleButtons()"><span
class={{imgButtonsUrl}} aria-hidden="true"></span></a>
</h2>
</div> </div>
<ul class="list-group"> <scrollable-table ng-if="buttonsVisible"
<li class="list-group-item"> watch="bridge.harmonyactivities">
<form class="form-horizontal"> <table class="table table-bordered table-striped table-hover">
<div class="form-group"> <thead>
<label class="col-xs-12 col-sm-2 control-label" for="device-name">Name <tr>
</label> <th>Row</th>
<th sortable-header col="name">Name</th>
<th sortable-header col="id">Id</th>
<th sortable-header col="hub">Hub</th>
<th>Actions</th>
</tr>
</thead>
<tr
ng-repeat="harmonyactivity in bridge.harmonyactivities | unavailableHarmonyActivityId">
<td>{{$index+1}}</td>
<td>{{harmonyactivity.activity.label}}</td>
<td>{{harmonyactivity.activity.id}}</td>
<td>{{harmonyactivity.hub}}</td>
<td><button class="btn btn-danger" type="submit"
ng-click="deleteDeviceByMapId(harmonyactivity.activity.id, 'harmonyActivity')">Delete</button></td>
</tr>
</table>
</scrollable-table>
</div>
<div class="panel panel-default">
<div class="panel-heading">
<h2 class="panel-title">Add a Bridge Device for a Harmony
Activity</h2>
</div>
<div class="panel-body">
<form class="form-horizontal">
<div class="form-group">
<label class="col-xs-12 col-sm-2 control-label" for="device-name">Name
</label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<input type="text" class="form-control" id="device-name" <input type="text" class="form-control" id="device-name"
ng-model="device.name" placeholder="Device Name"> ng-model="device.name" placeholder="Device Name">
</div>
<button type="submit" class="col-xs-4 col-sm-2 btn btn-primary" ng-click="addDevice()">
Add Bridge Device</button>
</div> </div>
<div class="form-group"> <button type="submit" class="col-xs-4 col-sm-2 btn btn-primary"
<div class="row"> ng-click="addDevice()">Add Bridge Device</button>
</div>
<div class="form-group">
<div class="row">
<label class="col-xs-12 col-sm-2 control-label" for="device-on-url">On <label class="col-xs-12 col-sm-2 control-label" for="device-on-url">On
URL </label> URL </label>
@@ -105,10 +117,10 @@
</div> </div>
<button class="btn btn-danger" ng-click="clearDevice()"> <button class="btn btn-danger" ng-click="clearDevice()">
Clear Device</button> Clear Device</button>
</div>
</div> </div>
<div class="form-group"> </div>
<div class="row"> <div class="form-group">
<div class="row">
<label class="col-xs-12 col-sm-2 control-label" <label class="col-xs-12 col-sm-2 control-label"
for="device-off-url">Off URL </label> for="device-off-url">Off URL </label>
@@ -116,13 +128,12 @@
<textarea rows="3" class="form-control" id="device-off-url" <textarea rows="3" class="form-control" id="device-off-url"
ng-model="device.offUrl" placeholder="URL to turn device off"></textarea> ng-model="device.offUrl" placeholder="URL to turn device off"></textarea>
</div> </div>
</div>
</div> </div>
</form> </div>
</li> </form>
</ul> </div>
</div> </div>
<script type="text/ng-template" id="deleteMapandIdDialog"> <script type="text/ng-template" id="deleteMapandIdDialog">
<div class="ngdialog-message"> <div class="ngdialog-message">
<h2>Device Map and Id?</h2> <h2>Device Map and Id?</h2>
<p>{{mapandid.mapType}} with {{mapandid.id}}</p> <p>{{mapandid.mapType}} with {{mapandid.id}}</p>

View File

@@ -1,122 +1,137 @@
<ul class="nav nav-pills" role="tablist"> <ul class="nav nav-pills" role="tablist">
<li role="presentation"><a href="#">Bridge Devices</a></li> <li role="presentation"><a href="#">Bridge Devices</a></li>
<li role="presentation"><a href="#/system">Bridge Control</a></li> <li role="presentation"><a href="#/system">Bridge Control</a></li>
<li role="presentation"><a href="#/logs">Logs</a></li> <li role="presentation"><a href="#/logs">Logs</a></li>
<li ng-if="bridge.showVera" role="presentation"><a href="#/veradevices">Vera Devices</a></li> <li ng-if="bridge.showVera" role="presentation"><a
<li ng-if="bridge.showVera" role="presentation"><a href="#/verascenes">Vera Scenes</a></li> href="#/veradevices">Vera Devices</a></li>
<li role="presentation"><a href="#/harmonyactivities">Harmony Activities</a></li> <li ng-if="bridge.showVera" role="presentation"><a
<li role="presentation" class="active"><a href="#/harmonydevices">Harmony Devices</a></li> href="#/verascenes">Vera Scenes</a></li>
<li ng-if="bridge.showNest" role="presentation"><a href="#/nest">Nest</a></li> <li role="presentation"><a href="#/harmonyactivities">Harmony
<li ng-if="bridge.showHue" role="presentation"><a href="#/huedevices">Hue Devices</a></li> Activities</a></li>
<li ng-if="bridge.showHal" role="presentation"><a href="#/haldevices">HAL Devices</a></li> <li role="presentation" class="active"><a href="#/harmonydevices">Harmony
<li role="presentation"><a href="#/editor">Manual Add</a></li> Devices</a></li>
</ul> <li ng-if="bridge.showNest" role="presentation"><a href="#/nest">Nest</a></li>
<li ng-if="bridge.showHue" role="presentation"><a
href="#/huedevices">Hue Devices</a></li>
<li ng-if="bridge.showHal" role="presentation"><a
href="#/haldevices">HAL Devices</a></li>
<li role="presentation"><a href="#/editor">Manual Add</a></li>
</ul>
<div class="panel panel-default bridgeServer"> <div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
<h2 class="panel-title">Harmony Device List</h2> <h2 class="panel-title">Harmony Device List</h2>
</div> </div>
<ul class="list-group"> <div class="panel-body">
<li class="list-group-item"> <p class="text-muted">For any Harmony Device and Buttons, use the
<p class="text-muted">For any Harmony Device and Buttons, use the build button to generate the configuration for this bridge device. You can add button presses by build button to generate the configuration for this bridge device.
selecting yoru devic and buttons and then selecting the Build Button. This will allow multiple button presses to be built for a given device. You can add button presses by selecting yoru devic and buttons and
Then you can modify the name to anything you want that will be the keyword for Alexa. Click the 'Add Bridge Device' to finish that selection setup. then selecting the Build Button. This will allow multiple button
The 'Already Configured Harmony Buttons' list below will show what is already setup for your Harmony Hubs.</p> presses to be built for a given device. Then you can modify the name
to anything you want that will be the keyword for Alexa. Click the
<scrollable-table watch="bridge.harmonydevices"> 'Add Bridge Device' to finish that selection setup. The 'Already
<table class="table table-bordered table-striped table-hover"> Configured Harmony Buttons' list below will show what is already
<thead> setup for your Harmony Hubs.</p>
<tr>
<th>Row</th>
<th sortable-header col="name">Name</th>
<th sortable-header col="id">Id</th>
<th sortable-header col="hub">Hub</th>
<th>On Button</th>
<th>Off Button</th>
<th>Actions</th>
</tr>
</thead>
<tr ng-repeat="harmonydevice in bridge.harmonydevices">
<td>{{$index+1}}</td>
<td>{{harmonydevice.device.label}}</td>
<td>{{harmonydevice.device.id}}</td>
<td>{{harmonydevice.hub}}</td>
<td>
<select name="device-ctrlon" id="device-ctrlon" ng-model="devicectrlon">
<optgroup ng-repeat="ctrlon in harmonydevice.device.controlGroup" label="{{ctrlon.name}}">
<option ng-repeat="funcon in ctrlon.function" value="{{funcon.action}}">{{funcon.label}}</option>
</optgroup >
</select>
</td>
<td>
<select name="device-ctrloff" id="device-ctrloff" ng-model="devicectrloff">
<optgroup ng-repeat="ctrloff in harmonydevice.device.controlGroup" label="{{ctrloff.name}}">
<option ng-repeat="funcoff in ctrloff.function" value="{{funcoff.action}}">{{funcoff.label}}</option>
</optgroup >
</select>
</td>
<td>
<button class="btn btn-success" type="submit"
ng-click="buildButtonUrls(harmonydevice, devicectrlon, devicectrloff)">Build A Button</button>
</td>
</tr>
</table>
</scrollable-table>
</li>
</ul>
<div class="panel-heading">
<h2 class="panel-title">Already Configured Harmony Buttons <a ng-click="toggleButtons()"><span class={{imgButtonsUrl}} aria-hidden="true"></span></a></h2>
</div> </div>
<ul ng-if="buttonsVisible" class="list-group">
<li class="list-group-item"> <scrollable-table watch="bridge.harmonydevices">
<scrollable-table watch="bridge.harmonydevices"> <table class="table table-bordered table-striped table-hover">
<table class="table table-bordered table-striped table-hover"> <thead>
<thead> <tr>
<tr> <th>Row</th>
<th>Row</th> <th sortable-header col="name">Name</th>
<th sortable-header col="name">Name</th> <th sortable-header col="id">Id</th>
<th sortable-header col="id">Device Id</th> <th sortable-header col="hub">Hub</th>
<th sortable-header col="targetDevice">Hub</th> <th>On Button</th>
<th>Harmony Device-Button On-Button Off</th> <th>Off Button</th>
<th>Actions</th> <th>Actions</th>
</tr> </tr>
</thead> </thead>
<tr ng-repeat="device in bridge.devices | configuredButtons | orderBy:predicate:reverse"> <tr ng-repeat="harmonydevice in bridge.harmonydevices">
<td>{{$index+1}}</td> <td>{{$index+1}}</td>
<td>{{device.name}}</td> <td>{{harmonydevice.device.label}}</td>
<td>{{device.id}}</td> <td>{{harmonydevice.device.id}}</td>
<td>{{device.targetDevice}}</td> <td>{{harmonydevice.hub}}</td>
<td>{{device.mapId}}</td> <td><select name="device-ctrlon" id="device-ctrlon"
<td> ng-model="devicectrlon">
<button class="btn btn-danger" type="submit" <optgroup ng-repeat="ctrlon in harmonydevice.device.controlGroup"
ng-click="deleteDeviceByMapId(device.mapId, device.mapType)">Delete</button> label="{{ctrlon.name}}">
</td> <option ng-repeat="funcon in ctrlon.function"
</tr> value="{{funcon.action}}">{{funcon.label}}</option>
</table> </optgroup>
</scrollable-table> </select></td>
</li> <td><select name="device-ctrloff" id="device-ctrloff"
ng-model="devicectrloff">
<optgroup ng-repeat="ctrloff in harmonydevice.device.controlGroup"
label="{{ctrloff.name}}">
<option ng-repeat="funcoff in ctrloff.function"
value="{{funcoff.action}}">{{funcoff.label}}</option>
</optgroup>
</select></td>
<td>
<button class="btn btn-success" type="submit"
ng-click="buildButtonUrls(harmonydevice, devicectrlon, devicectrloff)">Build
A Button</button>
</td>
</tr>
</table>
</scrollable-table>
</li>
</ul> </ul>
</div> </div>
<div class="panel panel-default bridgeServer"> <div class="panel panel-default">
<div class="panel-heading">
<h2 class="panel-title">
Already Configured Harmony Buttons <a ng-click="toggleButtons()"><span
class={{imgButtonsUrl}} aria-hidden="true"></span></a>
</h2>
</div>
<scrollable-table ng-if="buttonsVisible" watch="bridge.harmonydevices">
<table class="table table-bordered table-striped table-hover">
<thead>
<tr>
<th>Row</th>
<th sortable-header col="name">Name</th>
<th sortable-header col="id">Device Id</th>
<th sortable-header col="targetDevice">Hub</th>
<th>Harmony Device-Button On-Button Off</th>
<th>Actions</th>
</tr>
</thead>
<tr
ng-repeat="device in bridge.devices | configuredButtons | orderBy:predicate:reverse">
<td>{{$index+1}}</td>
<td>{{device.name}}</td>
<td>{{device.id}}</td>
<td>{{device.targetDevice}}</td>
<td>{{device.mapId}}</td>
<td>
<button class="btn btn-danger" type="submit"
ng-click="deleteDeviceByMapId(device.mapId, device.mapType)">Delete</button>
</td>
</tr>
</table>
</scrollable-table>
</div>
<div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
<h2 class="panel-title">Add a Bridge Device for Harmony Buttons</h2> <h2 class="panel-title">Add a Bridge Device for Harmony Buttons</h2>
</div> </div>
<ul class="list-group"> <div class="panel-body">
<li class="list-group-item"> <form class="form-horizontal">
<form class="form-horizontal"> <div class="form-group">
<div class="form-group"> <label class="col-xs-12 col-sm-2 control-label" for="device-name">Name
<label class="col-xs-12 col-sm-2 control-label" for="device-name">Name </label>
</label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<input type="text" class="form-control" id="device-name" <input type="text" class="form-control" id="device-name"
ng-model="device.name" placeholder="Device Name"> ng-model="device.name" placeholder="Device Name">
</div>
<button type="submit" class="col-xs-4 col-sm-2 btn btn-primary" ng-click="addDevice()">
Add Bridge Device</button>
</div> </div>
<div class="form-group"> <button type="submit" class="col-xs-4 col-sm-2 btn btn-primary"
<div class="row"> ng-click="addDevice()">Add Bridge Device</button>
</div>
<div class="form-group">
<div class="row">
<label class="col-xs-12 col-sm-2 control-label" for="device-on-url">On <label class="col-xs-12 col-sm-2 control-label" for="device-on-url">On
URL </label> URL </label>
@@ -126,10 +141,10 @@
</div> </div>
<button class="btn btn-danger" ng-click="clearDevice()"> <button class="btn btn-danger" ng-click="clearDevice()">
Clear Device</button> Clear Device</button>
</div>
</div> </div>
<div class="form-group"> </div>
<div class="row"> <div class="form-group">
<div class="row">
<label class="col-xs-12 col-sm-2 control-label" <label class="col-xs-12 col-sm-2 control-label"
for="device-off-url">Off URL </label> for="device-off-url">Off URL </label>
@@ -137,13 +152,12 @@
<textarea rows="3" class="form-control" id="device-off-url" <textarea rows="3" class="form-control" id="device-off-url"
ng-model="device.offUrl" placeholder="URL to turn device off"></textarea> ng-model="device.offUrl" placeholder="URL to turn device off"></textarea>
</div> </div>
</div>
</div> </div>
</form> </div>
</li> </form>
</ul> </div>
</div> </div>
<script type="text/ng-template" id="deleteMapandIdDialog"> <script type="text/ng-template" id="deleteMapandIdDialog">
<div class="ngdialog-message"> <div class="ngdialog-message">
<h2>Device Map and Id?</h2> <h2>Device Map and Id?</h2>
<p>{{mapandid.mapType}} with {{mapandid.id}}</p> <p>{{mapandid.mapType}} with {{mapandid.id}}</p>

View File

@@ -1,109 +1,125 @@
<ul class="nav nav-pills" role="tablist"> <ul class="nav nav-pills" role="tablist">
<li role="presentation"><a href="#">Bridge Devices</a></li> <li role="presentation"><a href="#">Bridge Devices</a></li>
<li role="presentation"><a href="#/system">Bridge Control</a></li> <li role="presentation"><a href="#/system">Bridge Control</a></li>
<li role="presentation"><a href="#/logs">Logs</a></li> <li role="presentation"><a href="#/logs">Logs</a></li>
<li ng-if="bridge.showVera" role="presentation"><a href="#/veradevices">Vera Devices</a></li> <li ng-if="bridge.showVera" role="presentation"><a
<li ng-if="bridge.showVera" role="presentation"><a href="#/verascenes">Vera Scenes</a></li> href="#/veradevices">Vera Devices</a></li>
<li ng-if="bridge.showHarmony" role="presentation"><a href="#/harmonyactivities">Harmony Activities</a></li> <li ng-if="bridge.showVera" role="presentation"><a
<li ng-if="bridge.showHarmony" role="presentation"><a href="#/harmonydevices">Harmony Devices</a></li> href="#/verascenes">Vera Scenes</a></li>
<li ng-if="bridge.showNest" role="presentation"><a href="#/nest">Nest</a></li> <li ng-if="bridge.showHarmony" role="presentation"><a
<li role="presentation" class="active"><a href="#/huedevices">Hue Devices</a></li> href="#/harmonyactivities">Harmony Activities</a></li>
<li ng-if="bridge.showHal" role="presentation"><a href="#/haldevices">HAL Devices</a></li> <li ng-if="bridge.showHarmony" role="presentation"><a
<li role="presentation"><a href="#/editor">Manual Add</a></li> href="#/harmonydevices">Harmony Devices</a></li>
</ul> <li ng-if="bridge.showNest" role="presentation"><a href="#/nest">Nest</a></li>
<li role="presentation" class="active"><a href="#/huedevices">Hue
Devices</a></li>
<li ng-if="bridge.showHal" role="presentation"><a
href="#/haldevices">HAL Devices</a></li>
<li role="presentation"><a href="#/editor">Manual Add</a></li>
</ul>
<div class="panel panel-default bridgeServer"> <div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
<h2 class="panel-title">Hue Device List ({{bridge.huedevices.length}})</h2> <h2 class="panel-title">Hue Device List
({{bridge.huedevices.length}})</h2>
</div> </div>
<ul class="list-group"> <div class="panel-body">
<li class="list-group-item"> <p class="text-muted">For any Hue Device, use the action buttons
<p class="text-muted">For any Hue Device, use the action buttons to generate the device addition information below automatically. to generate the device addition information below automatically. Then
Then you can modify the name to anything you want that will be the keyword for Alexa. Click the 'Add Bridge Device' to finish that selection setup. you can modify the name to anything you want that will be the keyword
The 'Already Configured Hue Devices' list below will show what is already setup for your Hue.</p> for Alexa. Click the 'Add Bridge Device' to finish that selection
<p>Use the check boxes by the names to use the bulk addition feature. Select your items, then click bulk add below. setup. The 'Already Configured Hue Devices' list below will show what
Your items will be added with on and off or dim and off if selected with the name of the device from the Hue. is already setup for your Hue.</p>
</p> <p>Use the check boxes by the names to use the bulk addition
<scrollable-table watch="bridge.huedevices"> feature. Select your items, then click bulk add below. Your items
<table class="table table-bordered table-striped table-hover"> will be added with on and off or dim and off if selected with the
<thead> name of the device from the Hue.</p>
<tr> </div>
<th>Row</th> <scrollable-table watch="bridge.huedevices">
<th sortable-header col="name">Name</th> <table class="table table-bordered table-striped table-hover">
<th sortable-header col="id">Id</th> <thead>
<th sortable-header col="huename">Hue</th> <tr>
<th>Actions</th> <th>Row</th>
</tr> <th sortable-header col="name">Name</th>
</thead> <th sortable-header col="id">Id</th>
<tr ng-repeat="huedevice in bridge.huedevices | availableHueDeviceId"> <th sortable-header col="huename">Hue</th>
<td>{{$index+1}}</td> <th>Actions</th>
<td><input type="checkbox" name="bulk.devices[]" value="{{huedevice.device.uniqueid}}" ng-checked="bulk.devices.indexOf(huedevice.device.uniqueid) > -1" ng-click="toggleSelection(huedevice.device.uniqueid)"> {{huedevice.device.name}}</td> </tr>
<td>{{huedevice.device.uniqueid}}</td> </thead>
<td>{{huedevice.huename}}</td> <tr ng-repeat="huedevice in bridge.huedevices | availableHueDeviceId">
<td> <td>{{$index+1}}</td>
<button class="btn btn-success" type="submit" <td><input type="checkbox" name="bulk.devices[]"
ng-click="buildDeviceUrls(huedevice)">Generate Bridge Device</button> value="{{huedevice.device.uniqueid}}"
</td> ng-checked="bulk.devices.indexOf(huedevice.device.uniqueid) > -1"
</tr> ng-click="toggleSelection(huedevice.device.uniqueid)">
</table> {{huedevice.device.name}}</td>
</scrollable-table> <td>{{huedevice.device.uniqueid}}</td>
<p> <td>{{huedevice.huename}}</td>
<td>
<button class="btn btn-success" type="submit" <button class="btn btn-success" type="submit"
ng-click="bulkAddDevices()">Bulk Add ({{bulk.devices.length}})</button> ng-click="buildDeviceUrls(huedevice)">Generate Bridge
</p> Device</button>
</li> </td>
</ul> </tr>
<div class="panel-heading"> </table>
<h2 class="panel-title">Already Configured Hue Devices <a ng-click="toggleButtons()"><span class={{imgButtonsUrl}} aria-hidden="true"></span></a></a></h2> </scrollable-table>
<div class="panel-footer">
<button class="btn btn-success" type="submit"
ng-click="bulkAddDevices()">Bulk Add
({{bulk.devices.length}})</button>
</div> </div>
<ul ng-if="buttonsVisible" class="list-group">
<li class="list-group-item">
<scrollable-table watch="bridge.huedevices">
<table class="table table-bordered table-striped table-hover">
<thead>
<tr>
<th>Row</th>
<th sortable-header col="name">Name</th>
<th sortable-header col="id">Id</th>
<th sortable-header col="huename">hue</th>
<th>Actions</th>
</tr>
</thead>
<tr ng-repeat="huedevice in bridge.huedevices | unavailableHueDeviceId">
<td>{{$index+1}}</td>
<td>{{huedevice.device.name}}</td>
<td>{{huedevice.device.uniqueid}}</td>
<td>{{huedevice.huename}}</td>
<td>
<button class="btn btn-danger" type="submit"
ng-click="deleteDeviceByMapId(huedevice.device.uniqueid, 'hueDevice')">Delete</button>
</td>
</tr>
</table>
</scrollable-table>
</li>
</ul>
</div> </div>
<div class="panel panel-default bridgeServer"> <div class="panel panel-default">
<div class="panel-heading">
<h2 class="panel-title">
Already Configured Hue Devices <a ng-click="toggleButtons()"><span
class={{imgButtonsUrl}} aria-hidden="true"></span></a></a>
</h2>
</div>
<scrollable-table ng-if="buttonsVisible" watch="bridge.huedevices">
<table class="table table-bordered table-striped table-hover">
<thead>
<tr>
<th>Row</th>
<th sortable-header col="name">Name</th>
<th sortable-header col="id">Id</th>
<th sortable-header col="huename">hue</th>
<th>Actions</th>
</tr>
</thead>
<tr
ng-repeat="huedevice in bridge.huedevices | unavailableHueDeviceId">
<td>{{$index+1}}</td>
<td>{{huedevice.device.name}}</td>
<td>{{huedevice.device.uniqueid}}</td>
<td>{{huedevice.huename}}</td>
<td>
<button class="btn btn-danger" type="submit"
ng-click="deleteDeviceByMapId(huedevice.device.uniqueid, 'hueDevice')">Delete</button>
</td>
</tr>
</table>
</scrollable-table>
</div>
<div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
<h2 class="panel-title">Add Bridge Device for a Hue Device</h2> <h2 class="panel-title">Add Bridge Device for a Hue Device</h2>
</div> </div>
<ul class="list-group"> <div class="panel-body">
<li class="list-group-item"> <form class="form-horizontal">
<form class="form-horizontal"> <div class="form-group">
<div class="form-group"> <label class="col-xs-12 col-sm-2 control-label" for="device-name">Name
<label class="col-xs-12 col-sm-2 control-label" for="device-name">Name </label>
</label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<input type="text" class="form-control" id="device-name" <input type="text" class="form-control" id="device-name"
ng-model="device.name" placeholder="Device Name"> ng-model="device.name" placeholder="Device Name">
</div>
<button type="submit" class="col-xs-4 col-sm-2 btn btn-primary" ng-click="addDevice()">
Add Bridge Device</button>
</div> </div>
<div class="form-group"> <button type="submit" class="col-xs-4 col-sm-2 btn btn-primary"
<div class="row"> ng-click="addDevice()">Add Bridge Device</button>
</div>
<div class="form-group">
<div class="row">
<label class="col-xs-12 col-sm-2 control-label" for="device-on-url">On <label class="col-xs-12 col-sm-2 control-label" for="device-on-url">On
URL </label> URL </label>
@@ -114,11 +130,10 @@
<button class="btn btn-danger" ng-click="clearDevice()"> <button class="btn btn-danger" ng-click="clearDevice()">
Clear Device</button> Clear Device</button>
</div> </div>
</form> </form>
</li> </div>
</ul>
</div> </div>
<script type="text/ng-template" id="deleteMapandIdDialog"> <script type="text/ng-template" id="deleteMapandIdDialog">
<div class="ngdialog-message"> <div class="ngdialog-message">
<h2>Device Map and Id?</h2> <h2>Device Map and Id?</h2>
<p>{{mapandid.mapType}} with {{mapandid.id}}</p> <p>{{mapandid.mapType}} with {{mapandid.id}}</p>

View File

@@ -1,77 +1,85 @@
<ul class="nav nav-pills" role="tablist"> <ul class="nav nav-pills" role="tablist">
<li role="presentation"><a href="#">Bridge Devices</a></li> <li role="presentation"><a href="#">Bridge Devices</a></li>
<li role="presentation"><a href="#/system">Bridge Control</a></li> <li role="presentation"><a href="#/system">Bridge Control</a></li>
<li role="presentation" class="active"><a href="#/logs">Logs</a></li> <li role="presentation" class="active"><a href="#/logs">Logs</a></li>
<li ng-if="bridge.showVera" role="presentation"><a href="#/veradevices">Vera Devices</a></li> <li ng-if="bridge.showVera" role="presentation"><a
<li ng-if="bridge.showVera" role="presentation"><a href="#/verascenes">Vera Scenes</a></li> href="#/veradevices">Vera Devices</a></li>
<li ng-if="bridge.showHarmony" role="presentation"><a href="#/harmonyactivities">Harmony Activities</a></li> <li ng-if="bridge.showVera" role="presentation"><a
<li ng-if="bridge.showHarmony" role="presentation"><a href="#/harmonydevices">Harmony Devices</a></li> href="#/verascenes">Vera Scenes</a></li>
<li ng-if="bridge.showNest" role="presentation"><a href="#/nest">Nest</a></li> <li ng-if="bridge.showHarmony" role="presentation"><a
<li ng-if="bridge.showHue" role="presentation"><a href="#/huedevices">Hue Devices</a></li> href="#/harmonyactivities">Harmony Activities</a></li>
<li ng-if="bridge.showHal" role="presentation"><a href="#/haldevices">HAL Devices</a></li> <li ng-if="bridge.showHarmony" role="presentation"><a
<li role="presentation"><a href="#/editor">Manual Add</a></li> href="#/harmonydevices">Harmony Devices</a></li>
</ul> <li ng-if="bridge.showNest" role="presentation"><a href="#/nest">Nest</a></li>
<li ng-if="bridge.showHue" role="presentation"><a
href="#/huedevices">Hue Devices</a></li>
<li ng-if="bridge.showHal" role="presentation"><a
href="#/haldevices">HAL Devices</a></li>
<li role="presentation"><a href="#/editor">Manual Add</a></li>
</ul>
<div class="panel panel-default bridgeServer"> <div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
<h1 class="panel-title">Log Messages</h1> <h1 class="panel-title">Log Messages</h1>
</div>
<div class="panel-body">
<p>
<button class="btn btn-primary" type="submit"
ng-click="updateLogs()">Update Log</button>
</p>
<scrollable-table watch="bridge.logMsgs">
<table class="table table-striped table-bordered table-hover">
<thead>
<tr>
<th sortable-header col="time">Time</th>
<th sortable-header col="level">Level</th>
<th sortable-header col="message">Message</th>
<th sortable-header col="component">Component</th>
</tr>
</thead>
<tr ng-repeat="logMessage in bridge.logMsgs">
<td>{{logMessage.time}}</td>
<td>{{logMessage.level}}</td>
<td>{{logMessage.message}}</td>
<td>{{logMessage.component}}</td>
</tr>
</table>
</scrollable-table>
</div>
</div> </div>
<div class="panel panel-default logconfig"> <div class="panel-body">
<div class="panel-heading"> <p>
<h1 class="panel-title">Logging Configuration <a ng-click="toggle()"><span class={{imgUrl}} aria-hidden="true"></a></h1> <button class="btn btn-primary" type="submit" ng-click="updateLogs()">Update
</div> Log</button>
<div ng-if="visible" class="animate-if" class="panel-body"> </p>
<p>
<button class="btn btn-primary" type="submit"
ng-click="updateLoggers()">Update Log Levels</button>
Show All Loggers <input type="checkbox" ng-model="bridge.logShowAll"
ng-change="reloadLoggers()" ng-true-value=true ng-false-value=false> {{bridge.logShowAll}}
</p>
<scrollable-table watch="bridge.loggerInfo">
<table class="table table-bordered table-striped table-hover">
<thead>
<tr>
<th sortable-header col="logLevel">Log Level</th>
<th sortable-header col="loggerName">Component</th>
<th>New Log Level</th>
</tr>
</thead>
<tr ng-repeat="logInfo in bridge.loggerInfo">
<td>{{logInfo.logLevel.substr(0,logInfo.logLevel.indexOf("_"))}}</td>
<td>{{logInfo.loggerName}}</td>
<td>
<select name="new-log-level" id="new-log-level" ng-change="addToUpdate(logInfo)" ng-model="logInfo.newLogLevel">
<option ng-repeat="alevel in levels" value="{{alevel}}">{{alevel.substr(0,alevel.indexOf("_"))}}</option>
</select>
</td>
</tr>
</table>
</scrollable-table>
</div>
</div> </div>
<scrollable-table watch="bridge.logMsgs">
<table class="table table-striped table-bordered table-hover">
<thead>
<tr>
<th sortable-header col="time">Time</th>
<th sortable-header col="level">Level</th>
<th sortable-header col="message">Message</th>
<th sortable-header col="component">Component</th>
</tr>
</thead>
<tr ng-repeat="logMessage in bridge.logMsgs">
<td>{{logMessage.time}}</td>
<td>{{logMessage.level}}</td>
<td>{{logMessage.message}}</td>
<td>{{logMessage.component}}</td>
</tr>
</table>
</scrollable-table>
</div>
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">
Logging Configuration <a ng-click="toggle()"><span
class={{imgUrl}} aria-hidden="true"></a>
</h1>
</div>
<div ng-if="visible" class="animate-if" class="panel-body">
<p>
<button class="btn btn-primary" type="submit"
ng-click="updateLoggers()">Update Log Levels</button>
Show All Loggers <input type="checkbox" ng-model="bridge.logShowAll"
ng-change="reloadLoggers()" ng-true-value=true ng-false-value=false>
{{bridge.logShowAll}}
</p>
<scrollable-table watch="bridge.loggerInfo">
<table class="table table-bordered table-striped table-hover">
<thead>
<tr>
<th sortable-header col="logLevel">Log Level</th>
<th sortable-header col="loggerName">Component</th>
<th>New Log Level</th>
</tr>
</thead>
<tr ng-repeat="logInfo in bridge.loggerInfo">
<td>{{logInfo.logLevel.substr(0,logInfo.logLevel.indexOf("_"))}}</td>
<td>{{logInfo.loggerName}}</td>
<td><select name="new-log-level" id="new-log-level"
ng-change="addToUpdate(logInfo)" ng-model="logInfo.newLogLevel">
<option ng-repeat="alevel in levels" value="{{alevel}}">{{alevel.substr(0,alevel.indexOf("_"))}}</option>
</select></td>
</tr>
</table>
</scrollable-table>
</div>
</div>

View File

@@ -1,123 +1,132 @@
<ul class="nav nav-pills" role="tablist"> <ul class="nav nav-pills" role="tablist">
<li role="presentation"><a href="#">Bridge Devices</a></li> <li role="presentation"><a href="#">Bridge Devices</a></li>
<li role="presentation"><a href="#/system">Bridge Control</a></li> <li role="presentation"><a href="#/system">Bridge Control</a></li>
<li role="presentation"><a href="#/logs">Logs</a></li> <li role="presentation"><a href="#/logs">Logs</a></li>
<li ng-if="bridge.showVera" role="presentation"><a href="#/veradevices">Vera Devices</a></li> <li ng-if="bridge.showVera" role="presentation"><a
<li ng-if="bridge.showVera" role="presentation"><a href="#/verascenes">Vera Scenes</a></li> href="#/veradevices">Vera Devices</a></li>
<li ng-if="bridge.showHarmony" role="presentation"><a href="#/harmonyactivities">Harmony Activities</a></li> <li ng-if="bridge.showVera" role="presentation"><a
<li ng-if="bridge.showHarmony" role="presentation"><a href="#/harmonydevices">Harmony Devices</a></li> href="#/verascenes">Vera Scenes</a></li>
<li role="presentation" class="active"><a href="#/nest">Nest</a></li> <li ng-if="bridge.showHarmony" role="presentation"><a
<li ng-if="bridge.showHue" role="presentation"><a href="#/huedevices">Hue Devices</a></li> href="#/harmonyactivities">Harmony Activities</a></li>
<li ng-if="bridge.showHal" role="presentation"><a href="#/haldevices">HAL Devices</a></li> <li ng-if="bridge.showHarmony" role="presentation"><a
<li role="presentation"><a href="#/editor">Manual Add</a></li> href="#/harmonydevices">Harmony Devices</a></li>
</ul> <li role="presentation" class="active"><a href="#/nest">Nest</a></li>
<li ng-if="bridge.showHue" role="presentation"><a
href="#/huedevices">Hue Devices</a></li>
<li ng-if="bridge.showHal" role="presentation"><a
href="#/haldevices">HAL Devices</a></li>
<li role="presentation"><a href="#/editor">Manual Add</a></li>
</ul>
<div class="panel panel-default bridgeServer"> <div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
<h2 class="panel-title">Nest Items List</h2> <h2 class="panel-title">Nest Items List</h2>
</div> </div>
<ul class="list-group"> <div class="panel-body">
<li class="list-group-item"> <p class="text-muted">For any Nest Item, use the action buttons to
<p class="text-muted">For any Nest Item, use the action buttons to generate the device addition information below automatically. generate the device addition information below automatically. Then
Then you can modify the name to anything you want that will be the keyword for Alexa. Click the 'Add Bridge Device' to finish that selection setup. you can modify the name to anything you want that will be the keyword
The 'Already Configured Nest Items' list below will show what is already setup for your Nest.</p> for Alexa. Click the 'Add Bridge Device' to finish that selection
setup. The 'Already Configured Nest Items' list below will show what
<scrollable-table watch="bridge.nestitems"> is already setup for your Nest.</p>
<table class="table table-bordered table-striped table-hover">
<thead>
<tr>
<th>Row</th>
<th sortable-header col="name">Name</th>
<th sortable-header col="type">Type</th>
<th sortable-header col="location">Location</th>
<th>Actions</th>
</tr>
</thead>
<tr ng-repeat="nestitem in bridge.nestitems | availableNestItemId | orderBy:predicate:reverse">
<td>{{$index+1}}</td>
<td>{{nestitem.name}}</td>
<td>{{nestitem.type}}</td>
<td>{{nestitem.location}}</td>
<td>
<ul class="list-group">
<li ng-if="nestitem.type ==='Home' " class="list-group-item">
<button class="btn btn-success" type="submit"
ng-click="buildNestHomeUrls(nestitem)">Home/Away</button>
</li>
<li ng-if="nestitem.type ==='Thermostat' " class="list-group-item">
<p>
<button class="btn btn-success" type="submit"
ng-click="buildNestTempUrls(nestitem)">Temp</button>
<button class="btn btn-success" type="submit"
ng-click="buildNestHeatUrls(nestitem)">Heat</button>
<button class="btn btn-success" type="submit"
ng-click="buildNestCoolUrls(nestitem)">Cool</button>
</p>
<p>
<button class="btn btn-success" type="submit"
ng-click="buildNestRangeUrls(nestitem)">Range</button>
<button class="btn btn-success" type="submit"
ng-click="buildNestOffUrls(nestitem)">Off</button>
<button class="btn btn-success" type="submit"
ng-click="buildNestFanUrls(nestitem)">Fan</button>
</p>
</li>
</ul>
</td>
</tr>
</table>
</scrollable-table>
</li>
</ul>
<div class="panel-heading">
<h2 class="panel-title">Already Configured Nest Items <a ng-click="toggleButtons()"><span class={{imgButtonsUrl}} aria-hidden="true"></span></a></h2>
</div> </div>
<ul ng-if="buttonsVisible" class="list-group">
<li class="list-group-item"> <scrollable-table watch="bridge.nestitems">
<scrollable-table watch="bridge.nestitems"> <table class="table table-bordered table-striped table-hover">
<table class="table table-bordered table-striped table-hover"> <thead>
<thead> <tr>
<tr> <th>Row</th>
<th>Row</th> <th sortable-header col="name">Name</th>
<th sortable-header col="name">Name</th> <th sortable-header col="type">Type</th>
<th sortable-header col="id">Device Id</th> <th sortable-header col="location">Location</th>
<th>mapId</th> <th>Actions</th>
<th>Actions</th> </tr>
</tr> </thead>
</thead> <tr
<tr ng-repeat="device in bridge.devices | unavailableNestItemId | orderBy:predicate:reverse"> ng-repeat="nestitem in bridge.nestitems | availableNestItemId | orderBy:predicate:reverse">
<td>{{$index+1}}</td> <td>{{$index+1}}</td>
<td>{{device.name}}</td> <td>{{nestitem.name}}</td>
<td>{{device.id}}</td> <td>{{nestitem.type}}</td>
<td>{{device.mapId}}</td> <td>{{nestitem.location}}</td>
<td><button class="btn btn-danger" type="submit" <td>
ng-click="deleteDeviceByMapId(device.mapId, 'nest')">Delete</button></td> <ul class="list-group">
</tr> <li ng-if="nestitem.type ==='Home' " class="list-group-item">
</table> <button class="btn btn-success" type="submit"
</scrollable-table> ng-click="buildNestHomeUrls(nestitem)">Home/Away</button>
</li> </li>
</ul> <li ng-if="nestitem.type ==='Thermostat' " class="list-group-item">
<p>
<button class="btn btn-success" type="submit"
ng-click="buildNestTempUrls(nestitem)">Temp</button>
<button class="btn btn-success" type="submit"
ng-click="buildNestHeatUrls(nestitem)">Heat</button>
<button class="btn btn-success" type="submit"
ng-click="buildNestCoolUrls(nestitem)">Cool</button>
</p>
<p>
<button class="btn btn-success" type="submit"
ng-click="buildNestRangeUrls(nestitem)">Range</button>
<button class="btn btn-success" type="submit"
ng-click="buildNestOffUrls(nestitem)">Off</button>
<button class="btn btn-success" type="submit"
ng-click="buildNestFanUrls(nestitem)">Fan</button>
</p>
</li>
</ul>
</td>
</tr>
</table>
</scrollable-table>
</div> </div>
<div class="panel panel-default bridgeServer"> <div class="panel panel-default">
<div class="panel-heading">
<h2 class="panel-title">
Already Configured Nest Items <a ng-click="toggleButtons()"><span
class={{imgButtonsUrl}} aria-hidden="true"></span></a>
</h2>
</div>
<scrollable-table ng-if="buttonsVisible" watch="bridge.nestitems">
<table class="table table-bordered table-striped table-hover">
<thead>
<tr>
<th>Row</th>
<th sortable-header col="name">Name</th>
<th sortable-header col="id">Device Id</th>
<th>mapId</th>
<th>Actions</th>
</tr>
</thead>
<tr
ng-repeat="device in bridge.devices | unavailableNestItemId | orderBy:predicate:reverse">
<td>{{$index+1}}</td>
<td>{{device.name}}</td>
<td>{{device.id}}</td>
<td>{{device.mapId}}</td>
<td><button class="btn btn-danger" type="submit"
ng-click="deleteDeviceByMapId(device.mapId, 'nest')">Delete</button></td>
</tr>
</table>
</scrollable-table>
</div>
<div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
<h2 class="panel-title">Add a Bridge Device for a Nest Item</h2> <h2 class="panel-title">Add a Bridge Device for a Nest Item</h2>
</div> </div>
<ul class="list-group"> <div class="panel-body">
<li class="list-group-item"> <form class="form-horizontal">
<form class="form-horizontal"> <div class="form-group">
<div class="form-group"> <label class="col-xs-12 col-sm-2 control-label" for="device-name">Name
<label class="col-xs-12 col-sm-2 control-label" for="device-name">Name </label>
</label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<input type="text" class="form-control" id="device-name" <input type="text" class="form-control" id="device-name"
ng-model="device.name" placeholder="Device Name"> ng-model="device.name" placeholder="Device Name">
</div>
<button type="submit" class="col-xs-4 col-sm-2 btn btn-primary" ng-click="addDevice()">
Add Bridge Device</button>
</div> </div>
<div class="form-group"> <button type="submit" class="col-xs-4 col-sm-2 btn btn-primary"
<div class="row"> ng-click="addDevice()">Add Bridge Device</button>
</div>
<div class="form-group">
<div class="row">
<label class="col-xs-12 col-sm-2 control-label" for="device-on-url">On <label class="col-xs-12 col-sm-2 control-label" for="device-on-url">On
URL </label> URL </label>
@@ -127,10 +136,10 @@
</div> </div>
<button class="btn btn-danger" ng-click="clearDevice()"> <button class="btn btn-danger" ng-click="clearDevice()">
Clear Device</button> Clear Device</button>
</div>
</div> </div>
<div class="form-group"> </div>
<div class="row"> <div class="form-group">
<div class="row">
<label class="col-xs-12 col-sm-2 control-label" <label class="col-xs-12 col-sm-2 control-label"
for="device-off-url">Off URL </label> for="device-off-url">Off URL </label>
@@ -138,13 +147,12 @@
<textarea rows="3" class="form-control" id="device-off-url" <textarea rows="3" class="form-control" id="device-off-url"
ng-model="device.offUrl" placeholder="URL to turn device off"></textarea> ng-model="device.offUrl" placeholder="URL to turn device off"></textarea>
</div> </div>
</div>
</div> </div>
</form> </div>
</li> </form>
</ul> </div>
</div> </div>
<script type="text/ng-template" id="deleteMapandIdDialog"> <script type="text/ng-template" id="deleteMapandIdDialog">
<div class="ngdialog-message"> <div class="ngdialog-message">
<h2>Device Map and Id?</h2> <h2>Device Map and Id?</h2>
<p>{{mapandid.mapType}} with {{mapandid.id}}</p> <p>{{mapandid.mapType}} with {{mapandid.id}}</p>

View File

@@ -1,50 +1,57 @@
<ul class="nav nav-pills" role="tablist"> <ul class="nav nav-pills" role="tablist">
<li role="presentation"><a href="#">Bridge Devices</a></li> <li role="presentation"><a href="#">Bridge Devices</a></li>
<li role="presentation" class="active"><a href="#/system">Bridge Control</a></li> <li role="presentation" class="active"><a href="#/system">Bridge
<li role="presentation"><a href="#/logs">Logs</a></li> Control</a></li>
<li ng-if="bridge.showVera" role="presentation"><a href="#/veradevices">Vera Devices</a></li> <li role="presentation"><a href="#/logs">Logs</a></li>
<li ng-if="bridge.showVera" role="presentation"><a href="#/verascenes">Vera Scenes</a></li> <li ng-if="bridge.showVera" role="presentation"><a
<li ng-if="bridge.showHarmony" role="presentation"><a href="#/harmonyactivities">Harmony Activities</a></li> href="#/veradevices">Vera Devices</a></li>
<li ng-if="bridge.showHarmony" role="presentation"><a href="#/harmonydevices">Harmony Devices</a></li> <li ng-if="bridge.showVera" role="presentation"><a
<li ng-if="bridge.showNest" role="presentation"><a href="#/nest">Nest</a></li> href="#/verascenes">Vera Scenes</a></li>
<li ng-if="bridge.showHue" role="presentation"><a href="#/huedevices">Hue Devices</a></li> <li ng-if="bridge.showHarmony" role="presentation"><a
<li ng-if="bridge.showHal" role="presentation"><a href="#/haldevices">HAL Devices</a></li> href="#/harmonyactivities">Harmony Activities</a></li>
<li role="presentation"><a href="#/editor">Manual Add</a></li> <li ng-if="bridge.showHarmony" role="presentation"><a
</ul> href="#/harmonydevices">Harmony Devices</a></li>
<li ng-if="bridge.showNest" role="presentation"><a href="#/nest">Nest</a></li>
<li ng-if="bridge.showHue" role="presentation"><a
href="#/huedevices">Hue Devices</a></li>
<li ng-if="bridge.showHal" role="presentation"><a
href="#/haldevices">HAL Devices</a></li>
<li role="presentation"><a href="#/editor">Manual Add</a></li>
</ul>
<div class="panel panel-default bridgeServer"> <div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
<h1 class="panel-title">Bridge Settings</h1> <h1 class="panel-title">Bridge Settings</h1>
</div> </div>
<div class="panel-body"> <div class="panel-body">
<form class="form-horizontal"> <form class="form-horizontal">
<div class="form-group"> <div class="form-group">
<label class="col-xs-12 col-sm-2 control-label" for="bridge-base">Bridge <label class="col-xs-12 col-sm-2 control-label" for="bridge-base">Bridge
server</label> server</label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<input id="bridge-base" class="form-control" type="text" <input id="bridge-base" class="form-control" type="text"
ng-model="bridge.base" placeholder="URL to bridge"> ng-model="bridge.base" placeholder="URL to bridge">
</div>
<button type="submit" class="col-xs-2 col-sm-1 btn btn-primary"
ng-click="goBridgeUrl(bridge.base)">Test</button>
</div> </div>
</form> <button type="submit" class="col-xs-2 col-sm-1 btn btn-primary"
<form name="form"> ng-click="goBridgeUrl(bridge.base)">Test</button>
</div>
</form>
<form name="form">
<p> <p>
<button ng-disabled="form.$pristine || bridge.isInControl" class="btn btn-success" type="submit" <button ng-disabled="form.$pristine || bridge.isInControl"
ng-click="saveSettings()">Save</button> class="btn btn-success" type="submit" ng-click="saveSettings()">Save</button>
<button ng-disabled="bridge.isInControl" class="btn btn-warning" type="submit" <button ng-disabled="bridge.isInControl" class="btn btn-warning"
ng-click="bridgeReinit()">Bridge Reinitialize</button> type="submit" ng-click="bridgeReinit()">Bridge
<button ng-disabled="bridge.isInControl" class="btn btn-danger" type="submit" Reinitialize</button>
ng-click="bridgeStop()">Bridge Stop</button> <button ng-disabled="bridge.isInControl" class="btn btn-danger"
<button class="btn btn-primary" type="submit" type="submit" ng-click="bridgeStop()">Bridge Stop</button>
onclick="myRefresh()">Refresh</button> <button class="btn btn-primary" type="submit" onclick="myRefresh()">Refresh</button>
<script> <script>
function myRefresh() { function myRefresh() {
location.reload(); location.reload();
} }
</script> </script>
</p> </p>
<table class="table table-bordered table-striped table-hover"> <table class="table table-bordered table-striped table-hover">
@@ -56,32 +63,41 @@
</thead> </thead>
<tr> <tr>
<td>Configuration Path and File</td> <td>Configuration Path and File</td>
<td><input id="bridge-settings-configfile" class="form-control" type="text" <td><input id="bridge-settings-configfile"
ng-model="bridge.settings.configfile" placeholder="data/ha-bridge.config"></td> class="form-control" type="text"
ng-model="bridge.settings.configfile"
placeholder="data/ha-bridge.config"></td>
</tr> </tr>
<tr> <tr>
<td>Device DB Path and File</td> <td>Device DB Path and File</td>
<td><input id="bridge-settings-upnpdevicedb" class="form-control" type="text" <td><input id="bridge-settings-upnpdevicedb"
ng-model="bridge.settings.upnpdevicedb" placeholder="data/device.db"></td> class="form-control" type="text"
ng-model="bridge.settings.upnpdevicedb"
placeholder="data/device.db"></td>
</tr> </tr>
<tr> <tr>
<td>UPNP IP Address</td> <td>UPNP IP Address</td>
<td><input id="bridge-settings-upnpconfigaddress" class="form-control" type="text" <td><input id="bridge-settings-upnpconfigaddress"
ng-model="bridge.settings.upnpconfigaddress" placeholder="192.168.1.1"></td> class="form-control" type="text"
ng-model="bridge.settings.upnpconfigaddress"
placeholder="192.168.1.1"></td>
</tr> </tr>
<tr> <tr>
<td>Web Server Port</td> <td>Web Server Port</td>
<td><input id="bridge-settings-serverport" class="form-control" type="number" <td><input id="bridge-settings-serverport"
ng-model="bridge.settings.serverport" min="1" max="65535"></td> class="form-control" type="number"
ng-model="bridge.settings.serverport" min="1" max="65535"></td>
</tr> </tr>
<tr> <tr>
<td>UPNP Response Port</td> <td>UPNP Response Port</td>
<td><input id="bridge-settings-upnpresponseport" class="form-control" type="number" <td><input id="bridge-settings-upnpresponseport"
ng-model="bridge.settings.upnpresponseport" min="1" max="65535"></td> class="form-control" type="number"
ng-model="bridge.settings.upnpresponseport" min="1" max="65535"></td>
</tr> </tr>
<tr> <tr>
<td>Vera Names and IP Addresses</td> <td>Vera Names and IP Addresses</td>
<td><table class="table table-bordered table-striped table-hover"> <td><table
class="table table-bordered table-striped table-hover">
<thead> <thead>
<tr> <tr>
<th>Name</th> <th>Name</th>
@@ -96,19 +112,21 @@
ng-click="removeVeratoSettings(vera.name, vera.ip)">Del</button></td> ng-click="removeVeratoSettings(vera.name, vera.ip)">Del</button></td>
</tr> </tr>
<tr> <tr>
<td><input id="bridge-settings-next-vera-name" class="form-control" type="text" <td><input id="bridge-settings-next-vera-name"
ng-model="newveraname" placeholder="A Vera"></td> class="form-control" type="text" ng-model="newveraname"
<td><input id="bridge-settings-next-vera-ip" class="form-control" type="text" placeholder="A Vera"></td>
ng-model="newveraip" placeholder="192.168.1.2"></td> <td><input id="bridge-settings-next-vera-ip"
<td><button class="btn btn-success" type="submit" class="form-control" type="text" ng-model="newveraip"
placeholder="192.168.1.2"></td>
<td><button class="btn btn-success" type="submit"
ng-click="addVeratoSettings(newveraname, newveraip)">Add</button></td> ng-click="addVeratoSettings(newveraname, newveraip)">Add</button></td>
</tr> </tr>
</table> </table></td>
</td>
</tr> </tr>
<tr> <tr>
<td>Harmony Names and IP Addresses</td> <td>Harmony Names and IP Addresses</td>
<td><table class="table table-bordered table-striped table-hover"> <td><table
class="table table-bordered table-striped table-hover">
<thead> <thead>
<tr> <tr>
<th>Name</th> <th>Name</th>
@@ -123,29 +141,34 @@
ng-click="removeHarmonytoSettings(harmony.name, harmony.ip)">Del</button></td> ng-click="removeHarmonytoSettings(harmony.name, harmony.ip)">Del</button></td>
</tr> </tr>
<tr> <tr>
<td><input id="bridge-settings-next-harmony-name" class="form-control" type="text" <td><input id="bridge-settings-next-harmony-name"
ng-model="newharmonyname" placeholder="A Harmony"></td> class="form-control" type="text" ng-model="newharmonyname"
<td><input id="bridge-settings-next-harmony-ip" class="form-control" type="text" placeholder="A Harmony"></td>
ng-model="newharmonyip" placeholder="192.168.1.3"></td> <td><input id="bridge-settings-next-harmony-ip"
<td><button class="btn btn-success" type="submit" class="form-control" type="text" ng-model="newharmonyip"
placeholder="192.168.1.3"></td>
<td><button class="btn btn-success" type="submit"
ng-click="addHarmonytoSettings(newharmonyname, newharmonyip)">Add</button></td> ng-click="addHarmonytoSettings(newharmonyname, newharmonyip)">Add</button></td>
</tr> </tr>
</table> </table></td>
</td>
</tr> </tr>
<tr> <tr>
<td>Harmony Username</td> <td>Harmony Username</td>
<td><input id="bridge-settings-harmonyuser" class="form-control" type="text" <td><input id="bridge-settings-harmonyuser"
ng-model="bridge.settings.harmonyuser" placeholder="someone@gmail.com"></td> class="form-control" type="text"
ng-model="bridge.settings.harmonyuser"
placeholder="someone@gmail.com"></td>
</tr> </tr>
<tr> <tr>
<td>Harmony Password</td> <td>Harmony Password</td>
<td><input id="bridge-settings-harmonypwd" class="form-control" type="password" <td><input id="bridge-settings-harmonypwd"
ng-model="bridge.settings.harmonypwd" placeholder="thepassword"></td> class="form-control" type="password"
ng-model="bridge.settings.harmonypwd" placeholder="thepassword"></td>
</tr> </tr>
<tr> <tr>
<td>Hue Names and IP Addresses</td> <td>Hue Names and IP Addresses</td>
<td><table class="table table-bordered table-striped table-hover"> <td><table
class="table table-bordered table-striped table-hover">
<thead> <thead>
<tr> <tr>
<th>Name</th> <th>Name</th>
@@ -160,19 +183,21 @@
ng-click="removeHuetoSettings(hue.name, hue.ip)">Del</button></td> ng-click="removeHuetoSettings(hue.name, hue.ip)">Del</button></td>
</tr> </tr>
<tr> <tr>
<td><input id="bridge-settings-next-hue-name" class="form-control" type="text" <td><input id="bridge-settings-next-hue-name"
ng-model="newhuename" placeholder="A Hue"></td> class="form-control" type="text" ng-model="newhuename"
<td><input id="bridge-settings-next-hue-ip" class="form-control" type="text" placeholder="A Hue"></td>
ng-model="newhueip" placeholder="192.168.1.3"></td> <td><input id="bridge-settings-next-hue-ip"
<td><button class="btn btn-success" type="submit" class="form-control" type="text" ng-model="newhueip"
placeholder="192.168.1.3"></td>
<td><button class="btn btn-success" type="submit"
ng-click="addHuetoSettings(newhuename, newhueip)">Add</button></td> ng-click="addHuetoSettings(newhuename, newhueip)">Add</button></td>
</tr> </tr>
</table> </table></td>
</td>
</tr> </tr>
<tr> <tr>
<td>HAL Names and IP Addresses</td> <td>HAL Names and IP Addresses</td>
<td><table class="table table-bordered table-striped table-hover"> <td><table
class="table table-bordered table-striped table-hover">
<thead> <thead>
<tr> <tr>
<th>Name</th> <th>Name</th>
@@ -187,94 +212,108 @@
ng-click="removeHaltoSettings(hal.name, hal.ip)">Del</button></td> ng-click="removeHaltoSettings(hal.name, hal.ip)">Del</button></td>
</tr> </tr>
<tr> <tr>
<td><input id="bridge-settings-next-hal-name" class="form-control" type="text" <td><input id="bridge-settings-next-hal-name"
ng-model="newhalname" placeholder="A Hal"></td> class="form-control" type="text" ng-model="newhalname"
<td><input id="bridge-settings-next-hal-ip" class="form-control" type="text" placeholder="A Hal"></td>
ng-model="newhalip" placeholder="192.168.1.3"></td> <td><input id="bridge-settings-next-hal-ip"
<td><button class="btn btn-success" type="submit" class="form-control" type="text" ng-model="newhalip"
placeholder="192.168.1.3:82"></td>
<td><button class="btn btn-success" type="submit"
ng-click="addHaltoSettings(newhalname, newhalip)">Add</button></td> ng-click="addHaltoSettings(newhalname, newhalip)">Add</button></td>
</tr> </tr>
</table> </table></td>
</td>
</tr> </tr>
<tr> <tr>
<td>HAL Token</td> <td>HAL Token</td>
<td><input id="bridge-settings-haltoken" class="form-control" type="password" <td><input id="bridge-settings-haltoken" class="form-control"
ng-model="bridge.settings.haltoken" placeholder="thetoken"></td> type="password" ng-model="bridge.settings.haltoken"
placeholder="thetoken"></td>
</tr> </tr>
<tr> <tr>
<td>Nest Username</td> <td>Nest Username</td>
<td><input id="bridge-settings-nestuser" class="form-control" type="text" <td><input id="bridge-settings-nestuser" class="form-control"
ng-model="bridge.settings.nestuser" placeholder="someone@gmail.com"></td> type="text" ng-model="bridge.settings.nestuser"
placeholder="someone@gmail.com"></td>
</tr> </tr>
<tr> <tr>
<td>Nest Password</td> <td>Nest Password</td>
<td><input id="bridge-settings-nestpwd" class="form-control" type="password" <td><input id="bridge-settings-nestpwd" class="form-control"
ng-model="bridge.settings.nestpwd" placeholder="thepassword"></td> type="password" ng-model="bridge.settings.nestpwd"
placeholder="thepassword"></td>
</tr> </tr>
<tr> <tr>
<td>Nest Temp Farenheit</td> <td>Nest Temp Farenheit</td>
<td><input type="checkbox" ng-model="bridge.settings.farenheit" <td><input type="checkbox"
ng-true-value=true ng-false-value=false> {{bridge.settings.farenheit}}</td> ng-model="bridge.settings.farenheit" ng-true-value=true
ng-false-value=false> {{bridge.settings.farenheit}}</td>
</tr> </tr>
<tr> <tr>
<td>Button Press/Call Item Loop Sleep Interval (ms)</td> <td>Button Press/Call Item Loop Sleep Interval (ms)</td>
<td><input id="bridge-settings-buttonsleep" class="form-control" type="number" name="input" <td><input id="bridge-settings-buttonsleep"
ng-model="bridge.settings.buttonsleep" min="100" max="9999"></td> class="form-control" type="number" name="input"
ng-model="bridge.settings.buttonsleep" min="100" max="9999"></td>
</tr> </tr>
<tr> <tr>
<td>Log Messages to Buffer</td> <td>Log Messages to Buffer</td>
<td><input id="bridge-settings-numberoflogmessages" class="form-control" type="number" <td><input id="bridge-settings-numberoflogmessages"
ng-model="bridge.settings.numberoflogmessages" min="100" max="65535"></td> class="form-control" type="number"
ng-model="bridge.settings.numberoflogmessages" min="100"
max="65535"></td>
</tr> </tr>
<tr> <tr>
<td>UPNP Strict Handling</td> <td>UPNP Strict Handling</td>
<td><input type="checkbox" ng-model="bridge.settings.upnpstrict" <td><input type="checkbox"
ng-true-value=true ng-false-value=false> {{bridge.settings.upnpstrict}}</td> ng-model="bridge.settings.upnpstrict" ng-true-value=true
ng-false-value=false> {{bridge.settings.upnpstrict}}</td>
</tr> </tr>
<tr> <tr>
<td>Trace UPNP Calls</td> <td>Trace UPNP Calls</td>
<td><input type="checkbox" ng-model="bridge.settings.traceupnp" <td><input type="checkbox"
ng-true-value=true ng-false-value=false> {{bridge.settings.traceupnp}}</td> ng-model="bridge.settings.traceupnp" ng-true-value=true
ng-false-value=false> {{bridge.settings.traceupnp}}</td>
</tr> </tr>
</table> </table>
</form> </form>
</div>
</div> </div>
<div class="panel panel-default backup"> </div>
<div class="panel-heading"> <div class="panel panel-default">
<h1 class="panel-title">Bridge Settings Backup <a ng-click="toggle()"><span class={{imgUrl}} aria-hidden="true"></a></h1> <div class="panel-heading">
</div> <h1 class="panel-title">
<div ng-if="visible" class="animate-if" class="panel-body"> Bridge Settings Backup <a ng-click="toggle()"><span
<form class="form-horizontal"> class={{imgUrl}} aria-hidden="true"></a>
<div class="form-group"> </h1>
<label class="col-xs-12 col-sm-2 control-label" for="backup-name">Backup Settings File Name</label> </div>
<div ng-if="visible" class="animate-if" class="panel-body">
<form class="form-horizontal">
<div class="form-group">
<label class="col-xs-12 col-sm-2 control-label" for="backup-name">Backup
Settings File Name</label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<input id="backup-name" class="form-control" type="text" <input id="backup-name" class="form-control" type="text"
ng-model="optionalbackupname" placeholder="Optional"> ng-model="optionalbackupname" placeholder="Optional">
</div>
<button type="submit" class="btn btn-primary"
ng-click="backupSettings(optionalbackupname)">Backup Settings</button>
</div> </div>
</form> <button type="submit" class="btn btn-primary"
<table class="table table-bordered table-striped table-hover"> ng-click="backupSettings(optionalbackupname)">Backup
<thead> Settings</button>
<tr> </div>
<th>Filename</th> </form>
<th>Actions</th> <table class="table table-bordered table-striped table-hover">
</tr> <thead>
</thead> <tr>
<tr ng-repeat="backup in bridge.configs"> <th>Filename</th>
<td>{{backup}}</td> <th>Actions</th>
<td>
<button class="btn btn-danger" type="submit"
ng-click="restoreSettings(backup)">Restore</button>
<button class="btn btn-warning" type="submit"
ng-click="deleteSettingsBackup(backup)">Delete</button>
</td>
</tr> </tr>
</table> </thead>
</div> <tr ng-repeat="backup in bridge.configs">
<td>{{backup}}</td>
<td>
<button class="btn btn-danger" type="submit"
ng-click="restoreSettings(backup)">Restore</button>
<button class="btn btn-warning" type="submit"
ng-click="deleteSettingsBackup(backup)">Delete</button>
</td>
</tr>
</table>
</div> </div>
</div>

View File

@@ -1,126 +1,143 @@
<ul class="nav nav-pills" role="tablist"> <ul class="nav nav-pills" role="tablist">
<li role="presentation"><a href="#">Bridge Devices</a></li> <li role="presentation"><a href="#">Bridge Devices</a></li>
<li role="presentation"><a href="#/system">Bridge Control</a></li> <li role="presentation"><a href="#/system">Bridge Control</a></li>
<li role="presentation"><a href="#/logs">Logs</a></li> <li role="presentation"><a href="#/logs">Logs</a></li>
<li role="presentation" class="active"><a href="#/veradevices">Vera Devices</a></li> <li role="presentation" class="active"><a href="#/veradevices">Vera
<li role="presentation"><a href="#/verascenes">Vera Scenes</a></li> Devices</a></li>
<li ng-if="bridge.showHarmony" role="presentation"><a href="#/harmonyactivities">Harmony Activities</a></li> <li role="presentation"><a href="#/verascenes">Vera Scenes</a></li>
<li ng-if="bridge.showHarmony" role="presentation"><a href="#/harmonydevices">Harmony Devices</a></li> <li ng-if="bridge.showHarmony" role="presentation"><a
<li ng-if="bridge.showNest" role="presentation"><a href="#/nest">Nest</a></li> href="#/harmonyactivities">Harmony Activities</a></li>
<li ng-if="bridge.showHue" role="presentation"><a href="#/huedevices">Hue Devices</a></li> <li ng-if="bridge.showHarmony" role="presentation"><a
<li ng-if="bridge.showHal" role="presentation"><a href="#/haldevices">HAL Devices</a></li> href="#/harmonydevices">Harmony Devices</a></li>
<li role="presentation"><a href="#/editor">Manual Add</a></li> <li ng-if="bridge.showNest" role="presentation"><a href="#/nest">Nest</a></li>
</ul> <li ng-if="bridge.showHue" role="presentation"><a
href="#/huedevices">Hue Devices</a></li>
<li ng-if="bridge.showHal" role="presentation"><a
href="#/haldevices">HAL Devices</a></li>
<li role="presentation"><a href="#/editor">Manual Add</a></li>
</ul>
<div class="panel panel-default bridgeServer"> <div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
<h2 class="panel-title">Vera Device List ({{bridge.veradevices.length}})</h2> <h2 class="panel-title">Vera Device List
({{bridge.veradevices.length}})</h2>
</div> </div>
<ul class="list-group"> <div class="panel-body">
<li class="list-group-item"> <p class="text-muted">For any Vera Device, use the action buttons
<p class="text-muted">For any Vera Device, use the action buttons to generate the device addition information below automatically. to generate the device addition information below automatically. Then
Then you can modify the name to anything you want that will be the keyword for Alexa. Click the 'Add Bridge Device' to finish that selection setup. you can modify the name to anything you want that will be the keyword
The 'Already Configured Vera Devices' list below will show what is already setup for your Vera.</p> for Alexa. Click the 'Add Bridge Device' to finish that selection
<p>Also, use this select menu for which type of dim setup. The 'Already Configured Vera Devices' list below will show
control you would like to be generated: what is already setup for your Vera.</p>
<select name="device-dim-control" id="device-dim-control" ng-model="device_dim_control"> <p>
<option value="">none</option> Also, use this select menu for which type of dim control you would
<option value="${intensity.byte}">Pass-thru Value</option> like to be generated: <select name="device-dim-control"
<option value="${intensity.percent}">Percentage</option> id="device-dim-control" ng-model="device_dim_control">
<option value="${intensity.math(X*1)}">Custom Math</option> <option value="">none</option>
</select> <option value="${intensity.byte}">Pass-thru Value</option>
</p> <option value="${intensity.percent}">Percentage</option>
<p>Use the check boxes by the names to use the bulk addition feature. Select your items and dim control type if wanted, then click bulk add below. <option value="${intensity.math(X*1)}">Custom Math</option>
Your items will be added with on and off or dim and off if selected with the name of the device from the Vera. </select>
</p> </p>
<scrollable-table watch="bridge.veradevices"> <p>Use the check boxes by the names to use the bulk addition
<table class="table table-bordered table-striped table-hover"> feature. Select your items and dim control type if wanted, then click
<thead> bulk add below. Your items will be added with on and off or dim and
<tr> off if selected with the name of the device from the Vera.</p>
<th>Row</th> </div>
<th sortable-header col="name">Name</th> <scrollable-table watch="bridge.veradevices">
<th sortable-header col="id">Id</th> <table class="table table-bordered table-striped table-hover">
<th sortable-header col="category">Category</th> <thead>
<th sortable-header col="room">Room</th> <tr>
<th sortable-header col="veraname">Vera</th> <th>Row</th>
<th>Actions</th> <th sortable-header col="name">Name</th>
</tr> <th sortable-header col="id">Id</th>
</thead> <th sortable-header col="category">Category</th>
<tr ng-repeat="veradevice in bridge.veradevices | availableVeraDeviceId"> <th sortable-header col="room">Room</th>
<td>{{$index+1}}</td> <th sortable-header col="veraname">Vera</th>
<td><input type="checkbox" name="bulk.devices[]" value="{{veradevice.id}}" ng-checked="bulk.devices.indexOf(veradevice.id) > -1" ng-click="toggleSelection(veradevice.id)"> {{veradevice.name}}</td> <th>Actions</th>
<td>{{veradevice.id}}</td> </tr>
<td>{{veradevice.category}}</td> </thead>
<td>{{veradevice.room}}</td> <tr
<td>{{veradevice.veraname}}</td> ng-repeat="veradevice in bridge.veradevices | availableVeraDeviceId">
<td> <td>{{$index+1}}</td>
<button class="btn btn-success" type="submit" <td><input type="checkbox" name="bulk.devices[]"
ng-click="buildDeviceUrls(veradevice, device_dim_control)">Generate Bridge Device</button> value="{{veradevice.id}}"
</td> ng-checked="bulk.devices.indexOf(veradevice.id) > -1"
</tr> ng-click="toggleSelection(veradevice.id)">
</table> {{veradevice.name}}</td>
</scrollable-table> <td>{{veradevice.id}}</td>
<p> <td>{{veradevice.category}}</td>
<td>{{veradevice.room}}</td>
<td>{{veradevice.veraname}}</td>
<td>
<button class="btn btn-success" type="submit" <button class="btn btn-success" type="submit"
ng-click="bulkAddDevices(device_dim_control)">Bulk Add ({{bulk.devices.length}})</button> ng-click="buildDeviceUrls(veradevice, device_dim_control)">Generate
</p> Bridge Device</button>
</li> </td>
</ul> </tr>
<div class="panel-heading"> </table>
<h2 class="panel-title">Already Configured Vera Devices <a ng-click="toggleButtons()"><span class={{imgButtonsUrl}} aria-hidden="true"></span></a></a></h2> </scrollable-table>
<div class="panel-footer">
<button class="btn btn-success" type="submit"
ng-click="bulkAddDevices(device_dim_control)">Bulk Add
({{bulk.devices.length}})</button>
</div> </div>
<ul ng-if="buttonsVisible" class="list-group">
<li class="list-group-item">
<scrollable-table watch="bridge.veradevices">
<table class="table table-bordered table-striped table-hover">
<thead>
<tr>
<th>Row</th>
<th sortable-header col="name">Name</th>
<th sortable-header col="id">Id</th>
<th sortable-header col="category">Category</th>
<th sortable-header col="room">Room</th>
<th sortable-header col="veraname">Vera</th>
<th>Actions</th>
</tr>
</thead>
<tr ng-repeat="veradevice in bridge.veradevices | unavailableVeraDeviceId">
<td>{{$index+1}}</td>
<td>{{veradevice.name}}</td>
<td>{{veradevice.id}}</td>
<td>{{veradevice.category}}</td>
<td>{{veradevice.room}}</td>
<td>{{veradevice.veraname}}</td>
<td>
<button class="btn btn-danger" type="submit"
ng-click="deleteDeviceByMapId(veradevice.id, 'veraDevice')">Delete</button>
</td>
</tr>
</table>
</scrollable-table>
</li>
</ul>
</div> </div>
<div class="panel panel-default bridgeServer"> <div class="panel panel-default">
<div class="panel-heading">
<h2 class="panel-title">
Already Configured Vera Devices <a ng-click="toggleButtons()"><span
class={{imgButtonsUrl}} aria-hidden="true"></span></a></a>
</h2>
</div>
<scrollable-table ng-if="buttonsVisible" watch="bridge.veradevices">
<table class="table table-bordered table-striped table-hover">
<thead>
<tr>
<th>Row</th>
<th sortable-header col="name">Name</th>
<th sortable-header col="id">Id</th>
<th sortable-header col="category">Category</th>
<th sortable-header col="room">Room</th>
<th sortable-header col="veraname">Vera</th>
<th>Actions</th>
</tr>
</thead>
<tr
ng-repeat="veradevice in bridge.veradevices | unavailableVeraDeviceId">
<td>{{$index+1}}</td>
<td>{{veradevice.name}}</td>
<td>{{veradevice.id}}</td>
<td>{{veradevice.category}}</td>
<td>{{veradevice.room}}</td>
<td>{{veradevice.veraname}}</td>
<td>
<button class="btn btn-danger" type="submit"
ng-click="deleteDeviceByMapId(veradevice.id, 'veraDevice')">Delete</button>
</td>
</tr>
</table>
</scrollable-table>
</div>
<div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
<h2 class="panel-title">Add Bridge Device for a Vera Device</h2> <h2 class="panel-title">Add Bridge Device for a Vera Device</h2>
</div> </div>
<ul class="list-group"> <div class="panel-body">
<li class="list-group-item"> <form class="form-horizontal">
<form class="form-horizontal"> <div class="form-group">
<div class="form-group"> <label class="col-xs-12 col-sm-2 control-label" for="device-name">Name
<label class="col-xs-12 col-sm-2 control-label" for="device-name">Name </label>
</label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<input type="text" class="form-control" id="device-name" <input type="text" class="form-control" id="device-name"
ng-model="device.name" placeholder="Device Name"> ng-model="device.name" placeholder="Device Name">
</div>
<button type="submit" class="col-xs-4 col-sm-2 btn btn-primary" ng-click="addDevice()">
Add Bridge Device</button>
</div> </div>
<div class="form-group"> <button type="submit" class="col-xs-4 col-sm-2 btn btn-primary"
<div class="row"> ng-click="addDevice()">Add Bridge Device</button>
</div>
<div class="form-group">
<div class="row">
<label class="col-xs-12 col-sm-2 control-label" for="device-on-url">On <label class="col-xs-12 col-sm-2 control-label" for="device-on-url">On
URL </label> URL </label>
@@ -133,30 +150,29 @@
</div> </div>
<div class="form-group"> <div class="form-group">
<div class="row"> <div class="row">
<label class="col-xs-12 col-sm-2 control-label" for="device-dim-url">Dim <label class="col-xs-12 col-sm-2 control-label"
URL </label> for="device-dim-url">Dim URL </label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<textarea rows="3" class="form-control" id="device-dim-url" <textarea rows="3" class="form-control" id="device-dim-url"
ng-model="device.dimUrl" placeholder="URL to dim device"></textarea> ng-model="device.dimUrl" placeholder="URL to dim device"></textarea>
</div> </div>
</div> </div>
</div> </div>
<div class="form-group"> <div class="form-group">
<div class="row"> <div class="row">
<label class="col-xs-12 col-sm-2 control-label" <label class="col-xs-12 col-sm-2 control-label"
for="device-off-url">Off URL </label> for="device-off-url">Off URL </label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<textarea rows="3" class="form-control" id="device-off-url" <textarea rows="3" class="form-control" id="device-off-url"
ng-model="device.offUrl" placeholder="URL to turn device off"></textarea> ng-model="device.offUrl" placeholder="URL to turn device off"></textarea>
</div>
</div> </div>
</div> </form>
</form> </div>
</li>
</ul>
</div> </div>
<script type="text/ng-template" id="deleteMapandIdDialog"> <script type="text/ng-template" id="deleteMapandIdDialog">
<div class="ngdialog-message"> <div class="ngdialog-message">
<h2>Device Map and Id?</h2> <h2>Device Map and Id?</h2>
<p>{{mapandid.mapType}} with {{mapandid.id}}</p> <p>{{mapandid.mapType}} with {{mapandid.id}}</p>

View File

@@ -1,107 +1,115 @@
<ul class="nav nav-pills" role="tablist"> <ul class="nav nav-pills" role="tablist">
<li role="presentation"><a href="#">Bridge Devices</a></li> <li role="presentation"><a href="#">Bridge Devices</a></li>
<li role="presentation"><a href="#/system">Bridge Control</a></li> <li role="presentation"><a href="#/system">Bridge Control</a></li>
<li role="presentation"><a href="#/logs">Logs</a></li> <li role="presentation"><a href="#/logs">Logs</a></li>
<li role="presentation"><a href="#/veradevices">Vera Devices</a></li> <li role="presentation"><a href="#/veradevices">Vera Devices</a></li>
<li role="presentation" class="active"><a href="#/verascenes">Vera Scenes</a></li> <li role="presentation" class="active"><a href="#/verascenes">Vera
<li ng-if="bridge.showHarmony" role="presentation"><a href="#/harmonyactivities">Harmony Activities</a></li> Scenes</a></li>
<li ng-if="bridge.showHarmony" role="presentation"><a href="#/harmonydevices">Harmony Devices</a></li> <li ng-if="bridge.showHarmony" role="presentation"><a
<li ng-if="bridge.showNest" role="presentation"><a href="#/nest">Nest</a></li> href="#/harmonyactivities">Harmony Activities</a></li>
<li ng-if="bridge.showHue" role="presentation"><a href="#/huedevices">Hue Devices</a></li> <li ng-if="bridge.showHarmony" role="presentation"><a
<li ng-if="bridge.showHal" role="presentation"><a href="#/haldevices">HAL Devices</a></li> href="#/harmonydevices">Harmony Devices</a></li>
<li role="presentation"><a href="#/editor">Manual Add</a></li> <li ng-if="bridge.showNest" role="presentation"><a href="#/nest">Nest</a></li>
</ul> <li ng-if="bridge.showHue" role="presentation"><a
href="#/huedevices">Hue Devices</a></li>
<li ng-if="bridge.showHal" role="presentation"><a
href="#/haldevices">HAL Devices</a></li>
<li role="presentation"><a href="#/editor">Manual Add</a></li>
</ul>
<div class="panel panel-default bridgeServer"> <div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
<h2 class="panel-title">Vera Scene List</h2> <h2 class="panel-title">Vera Scene List</h2>
</div> </div>
<ul class="list-group"> <div class="panel-body">
<li class="list-group-item"> <p class="text-muted">For any Vera Scene, use the action buttons
<p class="text-muted">For any Vera Scene, use the action buttons to generate the device addition information below automatically. to generate the device addition information below automatically. Then
Then you can modify the name to anything you want that will be the keyword for Alexa. Click the 'Add Bridge Device' to finish that selection setup. you can modify the name to anything you want that will be the keyword
The 'Already Configured Vera Scenes' list below will show what is already setup for your Vera.</p> for Alexa. Click the 'Add Bridge Device' to finish that selection
setup. The 'Already Configured Vera Scenes' list below will show what
<scrollable-table watch="bridge.verascenes"> is already setup for your Vera.</p>
<table class="table table-bordered table-striped table-hover">
<thead>
<tr>
<th>Row</th>
<th sortable-header col="name">Name</th>
<th sortable-header col="id">Id</th>
<th sortable-header col="room">Room</th>
<th sortable-header col="veraname">Vera</th>
<th>Actions</th>
</tr>
</thead>
<tr ng-repeat="verascene in bridge.verascenes | availableVeraSceneId">
<td>{{$index+1}}</td>
<td>{{verascene.name}}</td>
<td>{{verascene.id}}</td>
<td>{{verascene.room}}</td>
<td>{{verascene.veraname}}</td>
<td>
<button class="btn btn-success" type="submit"
ng-click="buildSceneUrls(verascene)">Generate Bridge Device</button>
</td>
</tr>
</table>
</scrollable-table>
</li>
</ul>
<div class="panel-heading">
<h2 class="panel-title">Already Configured Vera Scenes <a ng-click="toggleButtons()"><span class={{imgButtonsUrl}} aria-hidden="true"></span></a></h2>
</div> </div>
<ul ng-if="buttonsVisible" class="list-group">
<li class="list-group-item"> <scrollable-table watch="bridge.verascenes">
<scrollable-table watch="bridge.verascenes"> <table class="table table-bordered table-striped table-hover">
<table class="table table-bordered table-striped table-hover"> <thead>
<thead> <tr>
<tr> <th>Row</th>
<th>Row</th> <th sortable-header col="name">Name</th>
<th sortable-header col="name">Name</th> <th sortable-header col="id">Id</th>
<th sortable-header col="id">Id</th> <th sortable-header col="room">Room</th>
<th sortable-header col="room">Room</th> <th sortable-header col="veraname">Vera</th>
<th sortable-header col="veraname">Vera</th> <th>Actions</th>
<th>Actions</th> </tr>
</tr> </thead>
</thead> <tr ng-repeat="verascene in bridge.verascenes | availableVeraSceneId">
<tr ng-repeat="verascene in bridge.verascenes | unavailableVeraSceneId"> <td>{{$index+1}}</td>
<td>{{$index+1}}</td> <td>{{verascene.name}}</td>
<td>{{verascene.name}}</td> <td>{{verascene.id}}</td>
<td>{{verascene.id}}</td> <td>{{verascene.room}}</td>
<td>{{verascene.room}}</td> <td>{{verascene.veraname}}</td>
<td>{{verascene.veraname}}</td> <td>
<td> <button class="btn btn-success" type="submit"
<button class="btn btn-danger" type="submit" ng-click="buildSceneUrls(verascene)">Generate Bridge
ng-click="deleteDeviceByMapId(verascene.id, 'veraScene')">Delete</button> Device</button>
</td> </td>
</tr> </tr>
</table> </table>
</scrollable-table> </scrollable-table>
</li>
</ul>
</div> </div>
<div class="panel panel-default bridgeServer"> <div class="panel panel-default">
<div class="panel-heading">
<h2 class="panel-title">
Already Configured Vera Scenes <a ng-click="toggleButtons()"><span
class={{imgButtonsUrl}} aria-hidden="true"></span></a>
</h2>
</div>
<scrollable-table ng-if="buttonsVisible" watch="bridge.verascenes">
<table class="table table-bordered table-striped table-hover">
<thead>
<tr>
<th>Row</th>
<th sortable-header col="name">Name</th>
<th sortable-header col="id">Id</th>
<th sortable-header col="room">Room</th>
<th sortable-header col="veraname">Vera</th>
<th>Actions</th>
</tr>
</thead>
<tr
ng-repeat="verascene in bridge.verascenes | unavailableVeraSceneId">
<td>{{$index+1}}</td>
<td>{{verascene.name}}</td>
<td>{{verascene.id}}</td>
<td>{{verascene.room}}</td>
<td>{{verascene.veraname}}</td>
<td>
<button class="btn btn-danger" type="submit"
ng-click="deleteDeviceByMapId(verascene.id, 'veraScene')">Delete</button>
</td>
</tr>
</table>
</scrollable-table>
</div>
<div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
<h2 class="panel-title">Add a Bridge Device for a Vera scene</h2> <h2 class="panel-title">Add a Bridge Device for a Vera scene</h2>
</div> </div>
<ul class="list-group"> <div class="panel-body">
<li class="list-group-item"> <form class="form-horizontal">
<form class="form-horizontal"> <div class="form-group">
<div class="form-group"> <label class="col-xs-12 col-sm-2 control-label" for="device-name">Name
<label class="col-xs-12 col-sm-2 control-label" for="device-name">Name </label>
</label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<input type="text" class="form-control" id="device-name" <input type="text" class="form-control" id="device-name"
ng-model="device.name" placeholder="Device Name"> ng-model="device.name" placeholder="Device Name">
</div>
<button type="submit" class="col-xs-4 col-sm-2 btn btn-primary" ng-click="addDevice()">
Add Bridge Device</button>
</div> </div>
<div class="form-group"> <button type="submit" class="col-xs-4 col-sm-2 btn btn-primary"
<div class="row"> ng-click="addDevice()">Add Bridge Device</button>
</div>
<div class="form-group">
<div class="row">
<label class="col-xs-12 col-sm-2 control-label" for="device-on-url">On <label class="col-xs-12 col-sm-2 control-label" for="device-on-url">On
URL </label> URL </label>
@@ -114,19 +122,18 @@
</div> </div>
<div class="form-group"> <div class="form-group">
<div class="row"> <div class="row">
<label class="col-xs-12 col-sm-2 control-label" <label class="col-xs-12 col-sm-2 control-label"
for="device-off-url">Off URL </label> for="device-off-url">Off URL </label>
<div class="col-xs-8 col-sm-7"> <div class="col-xs-8 col-sm-7">
<textarea rows="3" class="form-control" id="device-off-url" <textarea rows="3" class="form-control" id="device-off-url"
ng-model="device.offUrl" placeholder="URL to turn device off"></textarea> ng-model="device.offUrl" placeholder="URL to turn device off"></textarea>
</div>
</div> </div>
</div> </form>
</form> </div>
</li>
</ul>
</div> </div>
<script type="text/ng-template" id="deleteMapandIdDialog"> <script type="text/ng-template" id="deleteMapandIdDialog">
<div class="ngdialog-message"> <div class="ngdialog-message">
<h2>Device Map and Id?</h2> <h2>Device Map and Id?</h2>
<p>{{mapandid.mapType}} with {{mapandid.id}}</p> <p>{{mapandid.mapType}} with {{mapandid.id}}</p>