Commit 13c77858bc5c92e03790ac0a2cb239cccbb946c5
1 parent
9ba323fa
invisible issue is fixed
Showing
1 changed file
with
15 additions
and
4 deletions
400-SOURCECODE/AIAHTML5.Web/app/controllers/LabExercController.js
... | ... | @@ -539,11 +539,22 @@ function ($scope, $rootScope, pages, log, $http,$timeout, DataService, $filter, |
539 | 539 | $.each(Options, function (inx, value2) { |
540 | 540 | if (Options[inx].BoxName == id.split('-')[1]) { |
541 | 541 | if ($scope.DraggedList != null) { |
542 | - $.each($scope.DraggedList, function (inx1, value3) { | |
543 | - if ($scope.DraggedList[inx1].Value == dataText) { | |
544 | - $scope.DraggedList.splice(inx1, 1); | |
542 | + //$.each($scope.DraggedList, function (inx1, value3) { | |
543 | + // if ($scope.DraggedList[inx1].Value == dataText) { | |
544 | + // $scope.DraggedList.splice(inx1, 1); | |
545 | + // } | |
546 | + //}); | |
547 | + for (var i = 0; i <= $scope.DraggedList.length - 1; i++) { | |
548 | + | |
549 | + if ($scope.DraggedList[i].Value == undefined) { | |
550 | + i = 0; | |
551 | + continue; | |
545 | 552 | } |
546 | - }); | |
553 | + | |
554 | + if ($scope.DraggedList[i].Value == dataText) { | |
555 | + $scope.DraggedList.splice(i, 1); | |
556 | + } | |
557 | + } | |
547 | 558 | } |
548 | 559 | // $scope.UserAttempt.push({ "BlankBoxName": id.split('-')[1], "OptionName": $scope.dragableId.split('-')[1] }); |
549 | 560 | //$scope.UserAttempt.push({ balnkBox: +$scope.dragableId.split('-')[1] }); | ... | ... |