CLIMATE-374 UI runEvaluation doesnt use $window or $location for results 
transition


Project: http://git-wip-us.apache.org/repos/asf/climate/repo
Commit: http://git-wip-us.apache.org/repos/asf/climate/commit/4a64b62b
Tree: http://git-wip-us.apache.org/repos/asf/climate/tree/4a64b62b
Diff: http://git-wip-us.apache.org/repos/asf/climate/diff/4a64b62b

Branch: refs/heads/master
Commit: 4a64b62bb73ee4d12448833b67e06ca4becf0528
Parents: c7c1aeb
Author: Michael Anderson <michaelanderson@Michaels-iMac.local>
Authored: Sun Jan 7 16:09:59 2018 -0500
Committer: Michael Anderson <michaelanderson@Michaels-iMac.local>
Committed: Sun Jan 7 16:09:59 2018 -0500

----------------------------------------------------------------------
 .../frontend/app/scripts/controllers/parameterselect.js | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/climate/blob/4a64b62b/ocw-ui/frontend/app/scripts/controllers/parameterselect.js
----------------------------------------------------------------------
diff --git a/ocw-ui/frontend/app/scripts/controllers/parameterselect.js 
b/ocw-ui/frontend/app/scripts/controllers/parameterselect.js
index 565b054..a2554f4 100644
--- a/ocw-ui/frontend/app/scripts/controllers/parameterselect.js
+++ b/ocw-ui/frontend/app/scripts/controllers/parameterselect.js
@@ -166,17 +166,17 @@ angular.module('ocwUiApp')
       data['lon_min'] = $scope.displayParams.lonMin,
       data['lon_max'] = $scope.displayParams.lonMax,
 
-      $http.post(`${$rootScope.baseURL}/processing/run_evaluation/`, data).
-      success((data) => {
-        const evalWorkDir = data.eval_work_dir;
+      $http.post($rootScope.baseURL + '/processing/run_evaluation/', data).
+      success(function(data) {
+        var evalWorkDir = data['eval_work_dir'];
 
         $scope.runningEval = false;
 
-        $timeout(() => {
-          let url = (evalWorkDir) ? `/results/${evalWorkDir}` : '/results';
+        $timeout(function() {
+          var url = (evalWorkDir) ? '/results/' + evalWorkDir : '/results';
           $location.url(url)
         }, 100);
-      }).error(() => {
+      }).error(function() {
         $scope.runningEval = false;
       });
     };

Reply via email to