mirror of
https://github.com/openstf/stf
synced 2025-10-04 18:29:17 +02:00
Load devices with Oboe.
This commit is contained in:
parent
c119e2c3d2
commit
4c45a7288b
3 changed files with 30 additions and 7 deletions
|
@ -1,5 +1,12 @@
|
|||
define(['./module'], function(mod) {
|
||||
mod.controller('DeviceListCtrl', ['$scope', '$http', 'devices', function($scope, $http) {
|
||||
define(['./module', 'oboe'], function(mod, oboe) {
|
||||
mod.controller('DeviceListCtrl', ['$scope', function($scope) {
|
||||
$scope.devices = []
|
||||
|
||||
oboe('/api/v1/devices')
|
||||
.node('$devices[*]', function(devicesLoadedSoFar) {
|
||||
$scope.$apply(function() {
|
||||
$scope.devices = devicesLoadedSoFar
|
||||
})
|
||||
})
|
||||
}])
|
||||
})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue