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(
function () {
$scope.clearDevice(); $scope.clearDevice();
bridgeService.viewDevices(); bridgeService.viewDevices();
bridgeService.viewVeraDevices(); bridgeService.viewVeraDevices();
bridgeService.viewVeraScenes(); 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(
function () {
$scope.clearDevice(); $scope.clearDevice();
bridgeService.viewDevices(); bridgeService.viewDevices();
bridgeService.viewHueDevices(); 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(
function () {
$scope.clearDevice(); $scope.clearDevice();
bridgeService.viewDevices(); bridgeService.viewDevices();
bridgeService.viewHalDevices(); 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,20 +1,29 @@
<ul class="nav nav-pills" role="tablist">
<li role="presentation" class="active"><a href="#">Bridge Devices</a></li> <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="#/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.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.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.showHue" role="presentation"><a
<li ng-if="bridge.showHal" role="presentation"><a href="#/haldevices">HAL Devices</a></li> 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> <li role="presentation"><a href="#/editor">Manual Add</a></li>
</ul> </ul>
<div class="panel panel-default"> <div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
<h2 class="panel-title">Current devices ({{bridge.devices.length}}) </h2> <h2 class="panel-title">Current devices
({{bridge.devices.length}})</h2>
</div> </div>
<scrollable-table watch="bridge.devices"> <scrollable-table watch="bridge.devices">
<table class="table table-bordered table-striped table-hover"> <table class="table table-bordered table-striped table-hover">
@@ -51,22 +60,27 @@
</tr> </tr>
</table> </table>
</scrollable-table> </scrollable-table>
</div> </div>
<div class="panel panel-default backup"> <div class="panel panel-default backup">
<div class="panel-heading"> <div class="panel-heading">
<h1 class="panel-title">Bridge Device DB Backup <a ng-click="toggleBk()"><span class={{imgBkUrl}} aria-hidden="true"></a></h1> <h1 class="panel-title">
Bridge Device DB Backup <a ng-click="toggleBk()"><span
class={{imgBkUrl}} aria-hidden="true"></a>
</h1>
</div> </div>
<div ng-if="visibleBk" class="animate-if" class="panel-body"> <div ng-if="visibleBk" class="animate-if" 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="backup-name">Backup File Name</label> <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"> <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> </div>
<button type="submit" class="btn btn-primary" <button type="submit" class="btn btn-primary"
ng-click="backupDeviceDb(optionalbackupname)">Backup Device DB</button> ng-click="backupDeviceDb(optionalbackupname)">Backup
Device DB</button>
</div> </div>
</form> </form>
<table class="table table-bordered table-striped table-hover"> <table class="table table-bordered table-striped table-hover">
@@ -87,9 +101,9 @@
</tr> </tr>
</table> </table>
</div> </div>
</div> </div>
<script type="text/ng-template" id="valueDialog"> <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,27 +1,37 @@
<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.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.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.showHue" role="presentation"><a
href="#/huedevices">Hue Devices</a></li>
<li role="presentation"><a href="#/editor">Manual Add</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 ng-if="bridge.showHal" role="presentation"><a
<li role="presentation" class="active"><a href="#/editdevice">Edit Device</a></li> href="#/haldevices">HAL Devices</a></li>
</ul> <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>
<p>When copying, update the name and select the "Add Bridge
Device" Button.</p>
</div>
<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
@@ -31,8 +41,8 @@
<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
@@ -42,17 +52,19 @@
<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="">---Types if needed---</option>
<!-- not selected / blank option -->
<option value="custom">Custom</option> <option value="custom">Custom</option>
<option value="UDP">UDP</option> <option value="UDP">UDP</option>
<option value="TCP">TCP</option> <option value="TCP">TCP</option>
@@ -69,12 +81,14 @@
</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-map-type">Map Type <label class="col-xs-12 col-sm-2 control-label"
</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="">---Please select---</option>
<!-- not selected / blank option -->
<option value="veraDevice">Vera Device</option> <option value="veraDevice">Vera Device</option>
<option value="veraScene">Vera Scene</option> <option value="veraScene">Vera Scene</option>
<option value="harmonyActivity">Harmony Activity</option> <option value="harmonyActivity">Harmony Activity</option>
@@ -89,8 +103,8 @@
</div> </div>
</div> </div>
<div ng-if="device.mapType" class="form-group"> <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 class="col-xs-12 col-sm-2 control-label" for="device-map-id">Map
</label> 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"
@@ -121,8 +135,8 @@
</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
for="device-off-url">Off 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-off-url" <textarea rows="3" class="form-control" id="device-off-url"
@@ -132,23 +146,26 @@
</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-headers">HTTP
for="device-headers">HTTP Headers </label> 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"
placeholder="format like: [{&quot;name&quot;:&quot;A name&quot;,&quot;value&quot;:&quot;a value&quot;}]"></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" for="device-http-verb">Http Verb <label class="col-xs-12 col-sm-2 control-label"
</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="">---Please select---</option>
<!-- not selected / blank option -->
<option value="GET">GET</option> <option value="GET">GET</option>
<option value="PUT">PUT</option> <option value="PUT">PUT</option>
<option value="POST">POST</option> <option value="POST">POST</option>
@@ -158,12 +175,14 @@
</div> </div>
<div ng-if="device.httpVerb" class="form-group"> <div ng-if="device.httpVerb" class="form-group">
<div class="row"> <div class="row">
<label class="col-xs-12 col-sm-2 control-label" for="device-content-type">Content Type <label class="col-xs-12 col-sm-2 control-label"
</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="">---Please select---</option>
<!-- not selected / blank option -->
<option value="application/atom+xml">application/atom+xml</option> <option value="application/atom+xml">application/atom+xml</option>
<option value="application/x-www-form-urlencoded">application/x-www-form-urlencoded</option> <option value="application/x-www-form-urlencoded">application/x-www-form-urlencoded</option>
<option value="application/json">application/json</option> <option value="application/json">application/json</option>
@@ -188,7 +207,8 @@
<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"
placeholder="Content Body On for specific GET/PUT/POST type"></textarea>
</div> </div>
<div class="clearfix visible-xs"></div> <div class="clearfix visible-xs"></div>
</div> </div>
@@ -199,13 +219,12 @@
for="device-content-body-off">Content Body Off</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"
placeholder="Content Body Off for specific GET/PUT/POST type"></textarea>
</div> </div>
<div class="clearfix visible-xs"></div> <div class="clearfix visible-xs"></div>
</div> </div>
</div> </div>
</form> </form>
</li>
</ul>
</div> </div>

View File

@@ -1,27 +1,33 @@
<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.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.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.showHue" role="presentation"><a
<li ng-if="bridge.showHal" role="presentation"><a href="#/haldevices">HAL Devices</a></li> href="#/huedevices">Hue Devices</a></li>
<li role="presentation" class="active"><a href="#/editor">Manual Add</a></li> <li ng-if="bridge.showHal" role="presentation"><a
</ul> 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"> <form class="form-horizontal">
<div class="form-group"> <div class="form-group">
<label class="col-xs-12 col-sm-2 control-label" for="vera-base">Vera <label class="col-xs-12 col-sm-2 control-label" for="vera-base">Vera
@@ -51,10 +57,12 @@
</div> </div>
</div> </div>
<div class="form-group"> <div class="form-group">
<label class="col-xs-2 col-sm-2 control-label" for="device-dim-control">Device Dim Control</label> <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">
<select name="device-dim-control" id="device-dim-control" ng-model="device_dim_control"> <select name="device-dim-control" id="device-dim-control"
ng-model="device_dim_control">
<option value="">none</option> <option value="">none</option>
<option value="${intensity..byte}">Pass-thru Value</option> <option value="${intensity..byte}">Pass-thru Value</option>
<option value="${intensity.percent}">Percentage</option> <option value="${intensity.percent}">Percentage</option>
@@ -63,28 +71,32 @@
</div> </div>
</div> </div>
<div class="form-group"> <div class="form-group">
<button type="submit" ng-click="buildUrlsUsingDevice(device_dim_control)" <button type="submit"
class="col-xs-2 col-sm-2 col-xs-offset-2 col-sm-offset-2 btn btn-success">Generate Device ng-click="buildUrlsUsingDevice(device_dim_control)"
URLs</button> class="col-xs-2 col-sm-2 col-xs-offset-2 col-sm-offset-2 btn btn-success">Generate
Device URLs</button>
<button type="submit" ng-click="buildUrlsUsingScene()" <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 class="col-xs-2 col-sm-2 col-xs-offset-2 col-sm-offset-2 btn btn-success">Generate
URLs</button> Scene URLs</button>
</div> </div>
</form> </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
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)}) will
also work.</p>
</div>
<form class="form-horizontal"> <form class="form-horizontal">
<div class="form-group"> <div class="form-group">
<div class="row"> <div class="row">
@@ -95,18 +107,20 @@
<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-primary" ng-click="addDevice()"> <button type="submit" class="col-xs-4 col-sm-2 btn btn-primary"
Add Bridge Device</button> ng-click="addDevice()">Add Bridge Device</button>
</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-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="">---Types if needed---</option>
<!-- not selected / blank option -->
<option value="custom">Custom</option> <option value="custom">Custom</option>
<option value="UDP">UDP</option> <option value="UDP">UDP</option>
<option value="TCP">TCP</option> <option value="TCP">TCP</option>
@@ -141,8 +155,8 @@
</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
for="device-off-url">Off 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-off-url" <textarea rows="3" class="form-control" id="device-off-url"
@@ -152,23 +166,26 @@
</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-headers">HTTP
for="device-headers">HTTP Headers </label> 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"
placeholder="format like: [{&quot;name&quot;:&quot;A name&quot;,&quot;value&quot;:&quot;a value&quot;}]"></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" for="device-http-verb">Http Verb <label class="col-xs-12 col-sm-2 control-label"
</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="">---Please select---</option>
<!-- not selected / blank option -->
<option value="GET">GET</option> <option value="GET">GET</option>
<option value="PUT">PUT</option> <option value="PUT">PUT</option>
<option value="POST">POST</option> <option value="POST">POST</option>
@@ -178,12 +195,14 @@
</div> </div>
<div ng-if="device.httpVerb" class="form-group"> <div ng-if="device.httpVerb" class="form-group">
<div class="row"> <div class="row">
<label class="col-xs-12 col-sm-2 control-label" for="device-content-type">Content Type <label class="col-xs-12 col-sm-2 control-label"
</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="">---Please select---</option>
<!-- not selected / blank option -->
<option value="application/atom+xml">application/atom+xml</option> <option value="application/atom+xml">application/atom+xml</option>
<option value="application/x-www-form-urlencoded">application/x-www-form-urlencoded</option> <option value="application/x-www-form-urlencoded">application/x-www-form-urlencoded</option>
<option value="application/json">application/json</option> <option value="application/json">application/json</option>
@@ -208,7 +227,8 @@
<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"
placeholder="Content Body On for specific GET/PUT/POST type"></textarea>
</div> </div>
<div class="clearfix visible-xs"></div> <div class="clearfix visible-xs"></div>
</div> </div>
@@ -219,13 +239,12 @@
for="device-content-body-off">Content Body Off</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"
placeholder="Content Body Off for specific GET/PUT/POST type"></textarea>
</div> </div>
<div class="clearfix visible-xs"></div> <div class="clearfix visible-xs"></div>
</div> </div>
</div> </div>
</form> </form>
</li>
</ul>
</div> </div>

View File

@@ -1,38 +1,50 @@
<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.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.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.showHue" role="presentation"><a
<li role="presentation" class="active"><a href="#/haldevices">HAL Devices</a></li> 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> <li role="presentation"><a href="#/editor">Manual Add</a></li>
</ul> </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>
Also, use this select menu for which type of dim control you would
like to be generated: <select name="device-dim-control"
id="device-dim-control" ng-model="device_dim_control">
<option value="">none</option> <option value="">none</option>
<option value="${intensity.byte}">Pass-thru Value</option> <option value="${intensity.byte}">Pass-thru Value</option>
<option value="${intensity.percent}">Percentage</option> <option value="${intensity.percent}">Percentage</option>
<option value="${intensity.math(X*1)}">Custom Math</option> <option value="${intensity.math(X*1)}">Custom Math</option>
</select> </select>
</p> </p>
<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. <p>Use the check boxes by the names to use the bulk addition
Your items will be added with on and off or dim and off if selected with the name of the device from the HAL. feature. Select your items and dim control type if wanted, then click
</p> bulk add below. Your items will be added with on and off or dim and
off if selected with the name of the device from the HAL.</p>
</div>
<scrollable-table watch="bridge.haldevices"> <scrollable-table watch="bridge.haldevices">
<table class="table table-bordered table-striped table-hover"> <table class="table table-bordered table-striped table-hover">
<thead> <thead>
@@ -46,28 +58,35 @@
</thead> </thead>
<tr ng-repeat="haldevice in bridge.haldevices | availableHalDeviceId"> <tr ng-repeat="haldevice in bridge.haldevices | availableHalDeviceId">
<td>{{$index+1}}</td> <td>{{$index+1}}</td>
<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> <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>
<td>{{haldevice.haldevicetype}}</td> <td>{{haldevice.haldevicetype}}</td>
<td>{{haldevice.halname}}</td> <td>{{haldevice.halname}}</td>
<td> <td>
<button class="btn btn-success" type="submit" <button class="btn btn-success" type="submit"
ng-click="buildDeviceUrls(haldevice, device_dim_control)">Generate Bridge Device</button> ng-click="buildDeviceUrls(haldevice, device_dim_control)">Generate
Bridge Device</button>
</td> </td>
</tr> </tr>
</table> </table>
</scrollable-table> </scrollable-table>
<p> <div class="panel-footer">
<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="bulkAddDevices(device_dim_control)">Bulk Add
</p> ({{bulk.devices.length}})</button>
</li>
</ul>
<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> </div>
<ul ng-if="buttonsVisible" class="list-group"> </div>
<li class="list-group-item"> <div class="panel panel-default">
<scrollable-table watch="bridge.haldevices"> <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"> <table class="table table-bordered table-striped table-hover">
<thead> <thead>
<tr> <tr>
@@ -78,27 +97,25 @@
<th>Actions</th> <th>Actions</th>
</tr> </tr>
</thead> </thead>
<tr ng-repeat="haldevice in bridge.haldevices | unavailableHalDeviceId"> <tr
ng-repeat="haldevice in bridge.haldevices | unavailableHalDeviceId">
<td>{{$index+1}}</td> <td>{{$index+1}}</td>
<td>{{haldevice.haldevicename}}</td> <td>{{haldevice.haldevicename}}</td>
<td>{{haldevice.haldevicetype}}</td> <td>{{haldevice.haldevicetype}}</td>
<td>{{haldevice.halname}}</td> <td>{{haldevice.halname}}</td>
<td> <td>
<button class="btn btn-danger" type="submit" <button class="btn btn-danger" type="submit"
ng-click="deleteDeviceByMapId(haldevice.haldevicename, 'halDevice')">Delete</button> ng-click="deleteDeviceByMapId(haldevice.haldevicename, haldevice.halname, 'halDevice')">Delete</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"> <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
@@ -108,8 +125,8 @@
<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-primary" ng-click="addDevice()"> <button type="submit" class="col-xs-4 col-sm-2 btn btn-primary"
Add Bridge Device</button> ng-click="addDevice()">Add Bridge Device</button>
</div> </div>
<div class="form-group"> <div class="form-group">
<div class="row"> <div class="row">
@@ -125,8 +142,8 @@
</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"
@@ -145,10 +162,9 @@
</div> </div>
</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,26 +1,35 @@
<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 role="presentation" class="active"><a
href="#/harmonyactivities">Harmony Activities</a></li>
<li 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.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.showHue" role="presentation"><a
<li ng-if="bridge.showHal" role="presentation"><a href="#/haldevices">HAL Devices</a></li> 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> <li role="presentation"><a href="#/editor">Manual Add</a></li>
</ul> </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
below will show what is already setup for your Harmony Hubs.</p>
</div>
<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">
@@ -33,26 +42,30 @@
<th>Actions</th> <th>Actions</th>
</tr> </tr>
</thead> </thead>
<tr ng-repeat="harmonyactivity in bridge.harmonyactivities | availableHarmonyActivityId"> <tr
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> <td>
<button class="btn btn-success" type="submit" <button class="btn btn-success" type="submit"
ng-click="buildActivityUrls(harmonyactivity)">Generate Bridge Device</button> ng-click="buildActivityUrls(harmonyactivity)">Generate
Bridge Device</button>
</td> </td>
</tr> </tr>
</table> </table>
</scrollable-table> </scrollable-table>
</li> </div>
</ul> <div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
<h2 class="panel-title">Already Configured Activities <a ng-click="toggleButtons()"><span class={{imgButtonsUrl}} aria-hidden="true"></span></a></h2> <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"> <scrollable-table ng-if="buttonsVisible"
<li class="list-group-item"> 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>
@@ -63,7 +76,8 @@
<th>Actions</th> <th>Actions</th>
</tr> </tr>
</thead> </thead>
<tr ng-repeat="harmonyactivity in bridge.harmonyactivities | unavailableHarmonyActivityId"> <tr
ng-repeat="harmonyactivity in bridge.harmonyactivities | unavailableHarmonyActivityId">
<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>
@@ -73,15 +87,13 @@
</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"> <div class="panel-heading">
<h2 class="panel-title">Add a Bridge Device for a Harmony Activity</h2> <h2 class="panel-title">Add a Bridge Device for a Harmony
Activity</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
@@ -91,8 +103,8 @@
<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-primary" ng-click="addDevice()"> <button type="submit" class="col-xs-4 col-sm-2 btn btn-primary"
Add Bridge Device</button> ng-click="addDevice()">Add Bridge Device</button>
</div> </div>
<div class="form-group"> <div class="form-group">
<div class="row"> <div class="row">
@@ -119,10 +131,9 @@
</div> </div>
</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,27 +1,38 @@
<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 role="presentation"><a href="#/harmonyactivities">Harmony
Activities</a></li>
<li role="presentation" class="active"><a href="#/harmonydevices">Harmony
Devices</a></li>
<li ng-if="bridge.showNest" role="presentation"><a href="#/nest">Nest</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.showHue" role="presentation"><a
<li ng-if="bridge.showHal" role="presentation"><a href="#/haldevices">HAL Devices</a></li> 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> <li role="presentation"><a href="#/editor">Manual Add</a></li>
</ul> </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
'Add Bridge Device' to finish that selection setup. The 'Already
Configured Harmony Buttons' list below will show what is already
setup for your Harmony Hubs.</p>
</div>
<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">
@@ -41,35 +52,41 @@
<td>{{harmonydevice.device.label}}</td> <td>{{harmonydevice.device.label}}</td>
<td>{{harmonydevice.device.id}}</td> <td>{{harmonydevice.device.id}}</td>
<td>{{harmonydevice.hub}}</td> <td>{{harmonydevice.hub}}</td>
<td> <td><select name="device-ctrlon" id="device-ctrlon"
<select name="device-ctrlon" id="device-ctrlon" ng-model="devicectrlon"> ng-model="devicectrlon">
<optgroup ng-repeat="ctrlon in harmonydevice.device.controlGroup" label="{{ctrlon.name}}"> <optgroup ng-repeat="ctrlon in harmonydevice.device.controlGroup"
<option ng-repeat="funcon in ctrlon.function" value="{{funcon.action}}">{{funcon.label}}</option> label="{{ctrlon.name}}">
</optgroup > <option ng-repeat="funcon in ctrlon.function"
</select> value="{{funcon.action}}">{{funcon.label}}</option>
</td> </optgroup>
<td> </select></td>
<select name="device-ctrloff" id="device-ctrloff" ng-model="devicectrloff"> <td><select name="device-ctrloff" id="device-ctrloff"
<optgroup ng-repeat="ctrloff in harmonydevice.device.controlGroup" label="{{ctrloff.name}}"> ng-model="devicectrloff">
<option ng-repeat="funcoff in ctrloff.function" value="{{funcoff.action}}">{{funcoff.label}}</option> <optgroup ng-repeat="ctrloff in harmonydevice.device.controlGroup"
</optgroup > label="{{ctrloff.name}}">
</select> <option ng-repeat="funcoff in ctrloff.function"
</td> value="{{funcoff.action}}">{{funcoff.label}}</option>
</optgroup>
</select></td>
<td> <td>
<button class="btn btn-success" type="submit" <button class="btn btn-success" type="submit"
ng-click="buildButtonUrls(harmonydevice, devicectrlon, devicectrloff)">Build A Button</button> ng-click="buildButtonUrls(harmonydevice, devicectrlon, devicectrloff)">Build
A Button</button>
</td> </td>
</tr> </tr>
</table> </table>
</scrollable-table> </scrollable-table>
</li> </li>
</ul> </ul>
</div>
<div class="panel panel-default">
<div class="panel-heading"> <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> <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"> <scrollable-table ng-if="buttonsVisible" watch="bridge.harmonydevices">
<li class="list-group-item">
<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>
@@ -81,7 +98,8 @@
<th>Actions</th> <th>Actions</th>
</tr> </tr>
</thead> </thead>
<tr ng-repeat="device in bridge.devices | configuredButtons | orderBy:predicate:reverse"> <tr
ng-repeat="device in bridge.devices | configuredButtons | orderBy:predicate:reverse">
<td>{{$index+1}}</td> <td>{{$index+1}}</td>
<td>{{device.name}}</td> <td>{{device.name}}</td>
<td>{{device.id}}</td> <td>{{device.id}}</td>
@@ -94,15 +112,12 @@
</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"> <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
@@ -112,8 +127,8 @@
<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-primary" ng-click="addDevice()"> <button type="submit" class="col-xs-4 col-sm-2 btn btn-primary"
Add Bridge Device</button> ng-click="addDevice()">Add Bridge Device</button>
</div> </div>
<div class="form-group"> <div class="form-group">
<div class="row"> <div class="row">
@@ -140,10 +155,9 @@
</div> </div>
</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,29 +1,40 @@
<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.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.showNest" role="presentation"><a href="#/nest">Nest</a></li>
<li role="presentation" class="active"><a href="#/huedevices">Hue Devices</a></li> <li role="presentation" class="active"><a href="#/huedevices">Hue
<li ng-if="bridge.showHal" role="presentation"><a href="#/haldevices">HAL Devices</a></li> 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> <li role="presentation"><a href="#/editor">Manual Add</a></li>
</ul> </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 class="panel-body">
<p class="text-muted">For any Hue Device, use the action buttons
to generate the device addition information below automatically. 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. The 'Already Configured Hue Devices' list below will show what
is already setup for your Hue.</p>
<p>Use the check boxes by the names to use the bulk addition
feature. Select your items, then click bulk add below. Your items
will be added with on and off or dim and off if selected with the
name of the device from the Hue.</p>
</div> </div>
<ul class="list-group">
<li class="list-group-item">
<p class="text-muted">For any Hue Device, use the action buttons to generate the device addition information below automatically.
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.
The 'Already Configured Hue Devices' list below will show what is already setup for your Hue.</p>
<p>Use the check boxes by the names to use the bulk addition feature. Select your items, then click bulk add below.
Your items will be added with on and off or dim and off if selected with the name of the device from the Hue.
</p>
<scrollable-table watch="bridge.huedevices"> <scrollable-table watch="bridge.huedevices">
<table class="table table-bordered table-striped table-hover"> <table class="table table-bordered table-striped table-hover">
<thead> <thead>
@@ -37,28 +48,35 @@
</thead> </thead>
<tr ng-repeat="huedevice in bridge.huedevices | availableHueDeviceId"> <tr ng-repeat="huedevice in bridge.huedevices | availableHueDeviceId">
<td>{{$index+1}}</td> <td>{{$index+1}}</td>
<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> <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>
<td>{{huedevice.device.uniqueid}}</td> <td>{{huedevice.device.uniqueid}}</td>
<td>{{huedevice.huename}}</td> <td>{{huedevice.huename}}</td>
<td> <td>
<button class="btn btn-success" type="submit" <button class="btn btn-success" type="submit"
ng-click="buildDeviceUrls(huedevice)">Generate Bridge Device</button> ng-click="buildDeviceUrls(huedevice)">Generate Bridge
Device</button>
</td> </td>
</tr> </tr>
</table> </table>
</scrollable-table> </scrollable-table>
<p> <div class="panel-footer">
<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="bulkAddDevices()">Bulk Add
</p> ({{bulk.devices.length}})</button>
</li>
</ul>
<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> </div>
<ul ng-if="buttonsVisible" class="list-group"> </div>
<li class="list-group-item"> <div class="panel panel-default">
<scrollable-table watch="bridge.huedevices"> <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"> <table class="table table-bordered table-striped table-hover">
<thead> <thead>
<tr> <tr>
@@ -69,7 +87,8 @@
<th>Actions</th> <th>Actions</th>
</tr> </tr>
</thead> </thead>
<tr ng-repeat="huedevice in bridge.huedevices | unavailableHueDeviceId"> <tr
ng-repeat="huedevice in bridge.huedevices | unavailableHueDeviceId">
<td>{{$index+1}}</td> <td>{{$index+1}}</td>
<td>{{huedevice.device.name}}</td> <td>{{huedevice.device.name}}</td>
<td>{{huedevice.device.uniqueid}}</td> <td>{{huedevice.device.uniqueid}}</td>
@@ -81,15 +100,12 @@
</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"> <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
@@ -99,8 +115,8 @@
<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-primary" ng-click="addDevice()"> <button type="submit" class="col-xs-4 col-sm-2 btn btn-primary"
Add Bridge Device</button> ng-click="addDevice()">Add Bridge Device</button>
</div> </div>
<div class="form-group"> <div class="form-group">
<div class="row"> <div class="row">
@@ -115,10 +131,9 @@
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,26 +1,33 @@
<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.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.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.showHue" role="presentation"><a
<li ng-if="bridge.showHal" role="presentation"><a href="#/haldevices">HAL Devices</a></li> 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> <li role="presentation"><a href="#/editor">Manual Add</a></li>
</ul> </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>
<div class="panel-body"> <div class="panel-body">
<p> <p>
<button class="btn btn-primary" type="submit" <button class="btn btn-primary" type="submit" ng-click="updateLogs()">Update
ng-click="updateLogs()">Update Log</button> Log</button>
</p> </p>
</div>
<scrollable-table watch="bridge.logMsgs"> <scrollable-table watch="bridge.logMsgs">
<table class="table table-striped table-bordered table-hover"> <table class="table table-striped table-bordered table-hover">
<thead> <thead>
@@ -39,18 +46,21 @@
</tr> </tr>
</table> </table>
</scrollable-table> </scrollable-table>
</div> </div>
</div> <div class="panel panel-default">
<div class="panel panel-default logconfig">
<div class="panel-heading"> <div class="panel-heading">
<h1 class="panel-title">Logging Configuration <a ng-click="toggle()"><span class={{imgUrl}} aria-hidden="true"></a></h1> <h1 class="panel-title">
Logging Configuration <a ng-click="toggle()"><span
class={{imgUrl}} aria-hidden="true"></a>
</h1>
</div> </div>
<div ng-if="visible" class="animate-if" class="panel-body"> <div ng-if="visible" class="animate-if" class="panel-body">
<p> <p>
<button class="btn btn-primary" type="submit" <button class="btn btn-primary" type="submit"
ng-click="updateLoggers()">Update Log Levels</button> ng-click="updateLoggers()">Update Log Levels</button>
Show All Loggers <input type="checkbox" ng-model="bridge.logShowAll" Show All Loggers <input type="checkbox" ng-model="bridge.logShowAll"
ng-change="reloadLoggers()" ng-true-value=true ng-false-value=false> {{bridge.logShowAll}} ng-change="reloadLoggers()" ng-true-value=true ng-false-value=false>
{{bridge.logShowAll}}
</p> </p>
<scrollable-table watch="bridge.loggerInfo"> <scrollable-table watch="bridge.loggerInfo">
<table class="table table-bordered table-striped table-hover"> <table class="table table-bordered table-striped table-hover">
@@ -64,14 +74,12 @@
<tr ng-repeat="logInfo in bridge.loggerInfo"> <tr ng-repeat="logInfo in bridge.loggerInfo">
<td>{{logInfo.logLevel.substr(0,logInfo.logLevel.indexOf("_"))}}</td> <td>{{logInfo.logLevel.substr(0,logInfo.logLevel.indexOf("_"))}}</td>
<td>{{logInfo.loggerName}}</td> <td>{{logInfo.loggerName}}</td>
<td> <td><select name="new-log-level" id="new-log-level"
<select name="new-log-level" id="new-log-level" ng-change="addToUpdate(logInfo)" ng-model="logInfo.newLogLevel"> ng-change="addToUpdate(logInfo)" ng-model="logInfo.newLogLevel">
<option ng-repeat="alevel in levels" value="{{alevel}}">{{alevel.substr(0,alevel.indexOf("_"))}}</option> <option ng-repeat="alevel in levels" value="{{alevel}}">{{alevel.substr(0,alevel.indexOf("_"))}}</option>
</select> </select></td>
</td>
</tr> </tr>
</table> </table>
</scrollable-table> </scrollable-table>
</div> </div>
</div> </div>

View File

@@ -1,26 +1,35 @@
<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.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 role="presentation" class="active"><a href="#/nest">Nest</a></li> <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.showHue" role="presentation"><a
<li ng-if="bridge.showHal" role="presentation"><a href="#/haldevices">HAL Devices</a></li> 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> <li role="presentation"><a href="#/editor">Manual Add</a></li>
</ul> </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
is already setup for your Nest.</p>
</div>
<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">
@@ -33,7 +42,8 @@
<th>Actions</th> <th>Actions</th>
</tr> </tr>
</thead> </thead>
<tr ng-repeat="nestitem in bridge.nestitems | availableNestItemId | orderBy:predicate:reverse"> <tr
ng-repeat="nestitem in bridge.nestitems | availableNestItemId | orderBy:predicate:reverse">
<td>{{$index+1}}</td> <td>{{$index+1}}</td>
<td>{{nestitem.name}}</td> <td>{{nestitem.name}}</td>
<td>{{nestitem.type}}</td> <td>{{nestitem.type}}</td>
@@ -67,14 +77,15 @@
</tr> </tr>
</table> </table>
</scrollable-table> </scrollable-table>
</li> </div>
</ul> <div class="panel panel-default">
<div class="panel-heading"> <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> <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"> <scrollable-table ng-if="buttonsVisible" watch="bridge.nestitems">
<li class="list-group-item">
<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>
@@ -85,7 +96,8 @@
<th>Actions</th> <th>Actions</th>
</tr> </tr>
</thead> </thead>
<tr ng-repeat="device in bridge.devices | unavailableNestItemId | orderBy:predicate:reverse"> <tr
ng-repeat="device in bridge.devices | unavailableNestItemId | orderBy:predicate:reverse">
<td>{{$index+1}}</td> <td>{{$index+1}}</td>
<td>{{device.name}}</td> <td>{{device.name}}</td>
<td>{{device.id}}</td> <td>{{device.id}}</td>
@@ -95,15 +107,12 @@
</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"> <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
@@ -113,8 +122,8 @@
<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-primary" ng-click="addDevice()"> <button type="submit" class="col-xs-4 col-sm-2 btn btn-primary"
Add Bridge Device</button> ng-click="addDevice()">Add Bridge Device</button>
</div> </div>
<div class="form-group"> <div class="form-group">
<div class="row"> <div class="row">
@@ -141,10 +150,9 @@
</div> </div>
</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,18 +1,25 @@
<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
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.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.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.showHue" role="presentation"><a
<li ng-if="bridge.showHal" role="presentation"><a href="#/haldevices">HAL Devices</a></li> 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> <li role="presentation"><a href="#/editor">Manual Add</a></li>
</ul> </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>
@@ -33,14 +40,14 @@
</form> </form>
<form name="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();
@@ -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"
class="form-control" type="number"
ng-model="bridge.settings.serverport" min="1" max="65535"></td> 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"
class="form-control" type="number"
ng-model="bridge.settings.upnpresponseport" min="1" max="65535"></td> 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"
class="form-control" type="text" ng-model="newveraip"
placeholder="192.168.1.2"></td>
<td><button class="btn btn-success" type="submit" <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"
class="form-control" type="text" ng-model="newharmonyip"
placeholder="192.168.1.3"></td>
<td><button class="btn btn-success" type="submit" <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"
class="form-control" type="password"
ng-model="bridge.settings.harmonypwd" placeholder="thepassword"></td> 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"
class="form-control" type="text" ng-model="newhueip"
placeholder="192.168.1.3"></td>
<td><button class="btn btn-success" type="submit" <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,75 +212,90 @@
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"
class="form-control" type="text" ng-model="newhalip"
placeholder="192.168.1.3:82"></td>
<td><button class="btn btn-success" type="submit" <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"
class="form-control" type="number" name="input"
ng-model="bridge.settings.buttonsleep" min="100" max="9999"></td> 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>
<div class="panel panel-default backup"> <div class="panel panel-default">
<div class="panel-heading"> <div class="panel-heading">
<h1 class="panel-title">Bridge Settings Backup <a ng-click="toggle()"><span class={{imgUrl}} aria-hidden="true"></a></h1> <h1 class="panel-title">
Bridge Settings Backup <a ng-click="toggle()"><span
class={{imgUrl}} aria-hidden="true"></a>
</h1>
</div> </div>
<div ng-if="visible" class="animate-if" class="panel-body"> <div ng-if="visible" class="animate-if" 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="backup-name">Backup Settings File Name</label> <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> </div>
<button type="submit" class="btn btn-primary" <button type="submit" class="btn btn-primary"
ng-click="backupSettings(optionalbackupname)">Backup Settings</button> ng-click="backupSettings(optionalbackupname)">Backup
Settings</button>
</div> </div>
</form> </form>
<table class="table table-bordered table-striped table-hover"> <table class="table table-bordered table-striped table-hover">
@@ -276,5 +316,4 @@
</tr> </tr>
</table> </table>
</div> </div>
</div> </div>

View File

@@ -1,38 +1,49 @@
<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
Devices</a></li>
<li role="presentation"><a href="#/verascenes">Vera Scenes</a></li> <li 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
<li ng-if="bridge.showHarmony" role="presentation"><a href="#/harmonydevices">Harmony Devices</a></li> 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.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.showHue" role="presentation"><a
<li ng-if="bridge.showHal" role="presentation"><a href="#/haldevices">HAL Devices</a></li> 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> <li role="presentation"><a href="#/editor">Manual Add</a></li>
</ul> </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>
Also, use this select menu for which type of dim control you would
like to be generated: <select name="device-dim-control"
id="device-dim-control" ng-model="device_dim_control">
<option value="">none</option> <option value="">none</option>
<option value="${intensity.byte}">Pass-thru Value</option> <option value="${intensity.byte}">Pass-thru Value</option>
<option value="${intensity.percent}">Percentage</option> <option value="${intensity.percent}">Percentage</option>
<option value="${intensity.math(X*1)}">Custom Math</option> <option value="${intensity.math(X*1)}">Custom Math</option>
</select> </select>
</p> </p>
<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. <p>Use the check boxes by the names to use the bulk addition
Your items will be added with on and off or dim and off if selected with the name of the device from the Vera. feature. Select your items and dim control type if wanted, then click
</p> bulk add below. Your items will be added with on and off or dim and
off if selected with the name of the device from the Vera.</p>
</div>
<scrollable-table watch="bridge.veradevices"> <scrollable-table watch="bridge.veradevices">
<table class="table table-bordered table-striped table-hover"> <table class="table table-bordered table-striped table-hover">
<thead> <thead>
@@ -46,32 +57,40 @@
<th>Actions</th> <th>Actions</th>
</tr> </tr>
</thead> </thead>
<tr ng-repeat="veradevice in bridge.veradevices | availableVeraDeviceId"> <tr
ng-repeat="veradevice in bridge.veradevices | availableVeraDeviceId">
<td>{{$index+1}}</td> <td>{{$index+1}}</td>
<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> <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>
<td>{{veradevice.id}}</td> <td>{{veradevice.id}}</td>
<td>{{veradevice.category}}</td> <td>{{veradevice.category}}</td>
<td>{{veradevice.room}}</td> <td>{{veradevice.room}}</td>
<td>{{veradevice.veraname}}</td> <td>{{veradevice.veraname}}</td>
<td> <td>
<button class="btn btn-success" type="submit" <button class="btn btn-success" type="submit"
ng-click="buildDeviceUrls(veradevice, device_dim_control)">Generate Bridge Device</button> ng-click="buildDeviceUrls(veradevice, device_dim_control)">Generate
Bridge Device</button>
</td> </td>
</tr> </tr>
</table> </table>
</scrollable-table> </scrollable-table>
<p> <div class="panel-footer">
<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="bulkAddDevices(device_dim_control)">Bulk Add
</p> ({{bulk.devices.length}})</button>
</li>
</ul>
<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> </div>
<ul ng-if="buttonsVisible" class="list-group"> </div>
<li class="list-group-item"> <div class="panel panel-default">
<scrollable-table watch="bridge.veradevices"> <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"> <table class="table table-bordered table-striped table-hover">
<thead> <thead>
<tr> <tr>
@@ -84,7 +103,8 @@
<th>Actions</th> <th>Actions</th>
</tr> </tr>
</thead> </thead>
<tr ng-repeat="veradevice in bridge.veradevices | unavailableVeraDeviceId"> <tr
ng-repeat="veradevice in bridge.veradevices | unavailableVeraDeviceId">
<td>{{$index+1}}</td> <td>{{$index+1}}</td>
<td>{{veradevice.name}}</td> <td>{{veradevice.name}}</td>
<td>{{veradevice.id}}</td> <td>{{veradevice.id}}</td>
@@ -98,15 +118,12 @@
</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"> <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
@@ -116,8 +133,8 @@
<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-primary" ng-click="addDevice()"> <button type="submit" class="col-xs-4 col-sm-2 btn btn-primary"
Add Bridge Device</button> ng-click="addDevice()">Add Bridge Device</button>
</div> </div>
<div class="form-group"> <div class="form-group">
<div class="row"> <div class="row">
@@ -133,8 +150,8 @@
</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"
@@ -153,10 +170,9 @@
</div> </div>
</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,26 +1,34 @@
<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
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.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.showHue" role="presentation"><a
<li ng-if="bridge.showHal" role="presentation"><a href="#/haldevices">HAL Devices</a></li> 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> <li role="presentation"><a href="#/editor">Manual Add</a></li>
</ul> </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
is already setup for your Vera.</p>
</div>
<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">
@@ -42,19 +50,21 @@
<td>{{verascene.veraname}}</td> <td>{{verascene.veraname}}</td>
<td> <td>
<button class="btn btn-success" type="submit" <button class="btn btn-success" type="submit"
ng-click="buildSceneUrls(verascene)">Generate Bridge Device</button> ng-click="buildSceneUrls(verascene)">Generate Bridge
Device</button>
</td> </td>
</tr> </tr>
</table> </table>
</scrollable-table> </scrollable-table>
</li> </div>
</ul> <div class="panel panel-default">
<div class="panel-heading"> <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> <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"> <scrollable-table ng-if="buttonsVisible" watch="bridge.verascenes">
<li class="list-group-item">
<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>
@@ -66,7 +76,8 @@
<th>Actions</th> <th>Actions</th>
</tr> </tr>
</thead> </thead>
<tr ng-repeat="verascene in bridge.verascenes | unavailableVeraSceneId"> <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>
@@ -79,15 +90,12 @@
</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"> <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
@@ -97,8 +105,8 @@
<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-primary" ng-click="addDevice()"> <button type="submit" class="col-xs-4 col-sm-2 btn btn-primary"
Add Bridge Device</button> ng-click="addDevice()">Add Bridge Device</button>
</div> </div>
<div class="form-group"> <div class="form-group">
<div class="row"> <div class="row">
@@ -123,10 +131,9 @@
</div> </div>
</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>