MCPcopy Create free account
hub / github.com/apache/mesos / goBack

Function goBack

src/webui/app/controllers.js:1054–1067  ·  view source on GitHub ↗
(flashMessageOrOptions)

Source from the content-addressed store, hash-verified

1052 function($alert, $http, $location, $routeParams, $scope, $window) {
1053
1054 function goBack(flashMessageOrOptions) {
1055 if (flashMessageOrOptions) {
1056 $alert.danger(flashMessageOrOptions);
1057 }
1058
1059 if ($window.history.length > 1) {
1060 // If the browser has something in its history, just go back.
1061 $window.history.back();
1062 } else {
1063 // Otherwise navigate to the framework page, which is likely the
1064 // previous page anyway.
1065 $location.path('/frameworks/' + $routeParams.framework_id).replace();
1066 }
1067 }
1068
1069 var reroute = function() {
1070 var agent = $scope.agents[$routeParams.agent_id];

Callers 1

rerouteFunction · 0.85

Calls 1

pathMethod · 0.45

Tested by

no test coverage detected