| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Loader: | 2 * Loader: |
| 3 * Reads GM result reports written out by results.py, and imports | 3 * Reads GM result reports written out by results.py, and imports |
| 4 * them into $scope.categories and $scope.testData . | 4 * them into $scope.categories and $scope.testData . |
| 5 */ | 5 */ |
| 6 var Loader = angular.module( | 6 var Loader = angular.module( |
| 7 'Loader', | 7 'Loader', |
| 8 [] | 8 [] |
| 9 ); | 9 ); |
| 10 | 10 |
| (...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 57 | 57 |
| 58 $scope.header = data.header; | 58 $scope.header = data.header; |
| 59 $scope.categories = data.categories; | 59 $scope.categories = data.categories; |
| 60 $scope.testData = data.testData; | 60 $scope.testData = data.testData; |
| 61 $scope.sortColumn = 'test'; | 61 $scope.sortColumn = 'test'; |
| 62 $scope.showTodos = false; | 62 $scope.showTodos = false; |
| 63 | 63 |
| 64 $scope.showSubmitAdvancedSettings = false; | 64 $scope.showSubmitAdvancedSettings = false; |
| 65 $scope.submitAdvancedSettings = {}; | 65 $scope.submitAdvancedSettings = {}; |
| 66 $scope.submitAdvancedSettings['reviewed-by-human'] = true; | 66 $scope.submitAdvancedSettings['reviewed-by-human'] = true; |
| 67 $scope.submitAdvancedSettings['ignore-failures'] = false; | 67 $scope.submitAdvancedSettings['ignore-failure'] = false; |
| 68 $scope.submitAdvancedSettings['bug'] = ''; | 68 $scope.submitAdvancedSettings['bug'] = ''; |
| 69 | 69 |
| 70 // Create the list of tabs (lists into which the user can file each | 70 // Create the list of tabs (lists into which the user can file each |
| 71 // test). This may vary, depending on isEditable. | 71 // test). This may vary, depending on isEditable. |
| 72 $scope.tabs = [ | 72 $scope.tabs = [ |
| 73 'Unfiled', 'Hidden' | 73 'Unfiled', 'Hidden' |
| 74 ]; | 74 ]; |
| 75 if (data.header.isEditable) { | 75 if (data.header.isEditable) { |
| 76 $scope.tabs = $scope.tabs.concat( | 76 $scope.tabs = $scope.tabs.concat( |
| 77 ['Pending Approval']); | 77 ['Pending Approval']); |
| (...skipping 283 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 361 }; | 361 }; |
| 362 if (0 == expectedResult.config.indexOf('comparison-')) { | 362 if (0 == expectedResult.config.indexOf('comparison-')) { |
| 363 encounteredComparisonConfig = true; | 363 encounteredComparisonConfig = true; |
| 364 } | 364 } |
| 365 | 365 |
| 366 // Advanced settings... | 366 // Advanced settings... |
| 367 expectedResult['reviewed-by-human'] = | 367 expectedResult['reviewed-by-human'] = |
| 368 $scope.submitAdvancedSettings['reviewed-by-human']; | 368 $scope.submitAdvancedSettings['reviewed-by-human']; |
| 369 if (true == $scope.submitAdvancedSettings['ignore-failure']) { | 369 if (true == $scope.submitAdvancedSettings['ignore-failure']) { |
| 370 // if it's false, don't send it at all (just keep the default) | 370 // if it's false, don't send it at all (just keep the default) |
| 371 expectedResult['ignoreFailure'] = true; | 371 expectedResult['ignore-failure'] = true; |
| 372 } | 372 } |
| 373 expectedResult['bugs'] = bugs; | 373 expectedResult['bugs'] = bugs; |
| 374 | 374 |
| 375 newResults.push(expectedResult); | 375 newResults.push(expectedResult); |
| 376 } | 376 } |
| 377 if (encounteredComparisonConfig) { | 377 if (encounteredComparisonConfig) { |
| 378 alert("Approval failed -- you cannot approve results with config " + | 378 alert("Approval failed -- you cannot approve results with config " + |
| 379 "type comparison-*"); | 379 "type comparison-*"); |
| 380 $scope.submitPending = false; | 380 $scope.submitPending = false; |
| 381 return; | 381 return; |
| (...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 501 * | 501 * |
| 502 * @param secondsPastEpoch (numeric): seconds past epoch in UTC | 502 * @param secondsPastEpoch (numeric): seconds past epoch in UTC |
| 503 */ | 503 */ |
| 504 $scope.localTimeString = function(secondsPastEpoch) { | 504 $scope.localTimeString = function(secondsPastEpoch) { |
| 505 var d = new Date(secondsPastEpoch * 1000); | 505 var d = new Date(secondsPastEpoch * 1000); |
| 506 return d.toString(); | 506 return d.toString(); |
| 507 } | 507 } |
| 508 | 508 |
| 509 } | 509 } |
| 510 ); | 510 ); |
| OLD | NEW |