More features

This commit is contained in:
Dobie Wollert
2015-08-23 22:40:30 -07:00
parent 447d80f1b8
commit 68b2c8114b
8 changed files with 38 additions and 10 deletions

View File

@ -40,6 +40,8 @@ function testRunAddController($scope, Devices, CheckLists, TestRuns, $location,
field.result = (field.value == 'true');
} else if (field.type == 'range') {
field.result = field.value >= field.min && field.value <= field.max;
} else if (field.type == 'text') {
field.result = true;
}
$scope.model.result &= field.result;
@ -55,4 +57,4 @@ function testRunAddController($scope, Devices, CheckLists, TestRuns, $location,
function testRunViewController($scope, Devices, CheckLists, TestRuns, $location, $filter, $routeParams) {
$scope.model = TestRuns.get($routeParams);
}
}