Skip to content

Commit 871caca

Browse files
committed
fixed #5 added node name when asking for history
1 parent 6954f55 commit 871caca

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

deployment/http-root/ajs/app/components/commands_panel/commandHistoryCtrl.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ angular.module('codeine').controller('commandHistoryCtrl',['$scope', '$rootScope
66
if ($routeParams.node_name !== undefined) {
77
$scope.historyUrl += '&node=' + encodeURI($routeParams.node_name);
88
}
9-
CodeineService.getProjectCommandHistory($scope.projectName).success(function(data) {
9+
CodeineService.getProjectCommandHistory($scope.projectName, $routeParams.node_name).success(function(data) {
1010
$scope.history = data;
1111
});
1212
var maxUpdatesNotInFocus = 100;

deployment/http-root/ajs/app/components/services/codeineService.js

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -75,8 +75,12 @@ angular.module('codeine').factory('CodeineService', ['Constants', '$http', funct
7575
getProjectStatus : function(project) {
7676
return $http.get(Constants.CODEINE_WEB_SERVER + "/api/project-status2", {params: { project: project } ,cache: false });
7777
},
78-
getProjectCommandHistory: function(project) {
79-
return $http.get(Constants.CODEINE_WEB_SERVER + "/api/commands-log", {params: { project: project } ,cache: false });
78+
getProjectCommandHistory: function(project,node) {
79+
var paramsForRequest = { project: project };
80+
if (node !== undefined) {
81+
paramsForRequest.node = node;
82+
}
83+
return $http.get(Constants.CODEINE_WEB_SERVER + "/api/commands-log", {params: paramsForRequest ,cache: false });
8084
},
8185
getRunningCommands: function() {
8286
return $http.get(Constants.CODEINE_WEB_SERVER + "/api/commands-status", { cache: false });

0 commit comments

Comments
 (0)