fix add interface bug

Change-Id: I88ba7fa074dee9acad5d673536b25359c60fc3fb
This commit is contained in:
Ming He 2016-01-11 15:40:56 -08:00
parent 9797a4c4a6
commit aa0038deea
5 changed files with 11 additions and 11 deletions

View File

@ -1,5 +1,5 @@
00:01:02:03:04:11,8,127.0.0.1
00:01:02:03:04:12,8,127.0.0.1
00:01:02:03:04:13,8,127.0.0.1
00:01:02:03:04:14,8,127.0.0.1
00:01:02:03:04:15,8,127.0.0.1
00:01:02:03:04:05,8,127.0.0.1
00:01:02:03:04:06,8,127.0.0.1
00:01:02:03:04:07,8,127.0.0.1
00:01:02:03:04:08,8,127.0.0.1
00:01:02:03:04:09,8,127.0.0.1

View File

@ -545,8 +545,6 @@ define(['./baseController'], ()->
wizardService.displayDataInTable($scope, $scope.servers)
$scope.reload = ->
wizardService.displayDataInTable($scope, $scope.servers)
]
.animation '.fade-animation', [->
return{

View File

@ -621,6 +621,8 @@ define(['./baseService'], ()->
)
addInterface: ($scope, newInterface) ->
isExist = false
if !$scope.interfaces
$scope.interfaces = {}
if newInterface
for key, value of $scope.interfaces
if key == newInterface.name

View File

@ -631,10 +631,7 @@
$scope.commit = function(sendRequest) {
return wizardService.reviewCommit($scope, sendRequest);
};
wizardService.displayDataInTable($scope, $scope.servers);
return $scope.reload = function() {
return wizardService.displayDataInTable($scope, $scope.servers);
};
return wizardService.displayDataInTable($scope, $scope.servers);
}
]).animation('.fade-animation', [
function() {

View File

@ -945,6 +945,9 @@
WizardService.prototype.addInterface = function($scope, newInterface) {
var isExist, key, value, _ref;
isExist = false;
if (!$scope.interfaces) {
$scope.interfaces = {};
}
if (newInterface) {
_ref = $scope.interfaces;
for (key in _ref) {