mirror of
https://github.com/openstf/stf
synced 2025-10-04 02:09:32 +02:00
30 lines
603 B
JavaScript
30 lines
603 B
JavaScript
define(['./module'], function(mod) {
|
|
function DeviceListCtrl($scope, deviceService, groupService) {
|
|
$scope.devices = deviceService.devices
|
|
|
|
$scope.invite = function(device) {
|
|
groupService.invite({
|
|
serial: {
|
|
value: device.serial
|
|
, match: 'exact'
|
|
}
|
|
})
|
|
}
|
|
|
|
$scope.kick = function(device) {
|
|
groupService.kick({
|
|
serial: {
|
|
value: device.serial
|
|
, match: 'exact'
|
|
}
|
|
})
|
|
}
|
|
}
|
|
|
|
mod.controller('DeviceListCtrl'
|
|
, [ '$scope'
|
|
, 'deviceService'
|
|
, 'groupService'
|
|
, DeviceListCtrl
|
|
])
|
|
})
|