Web_Manager_Develope
wu ming 8 years ago
parent db2884438d
commit 9fba2532f1

File diff suppressed because one or more lines are too long

@ -36,7 +36,6 @@ module Configs{
$scope.editRow = (volume) => {
var fVolume = formatVolume(volume);
console.log(fVolume);
ngDialog.open({
template: 'newDialog.html',
width: 1005,

@ -13,8 +13,10 @@ module Configs{
}]);
export var VolumeController = controller('VolumeController', ['$scope', '$http', ($scope, $http) => {
$scope.status = $scope.ngDialogData.status;
$scope.save = (entity) =>{
changeStatus(entity);
console.log(entity);
$scope.closeThisDialog();
}
@ -41,27 +43,20 @@ module Configs{
}
$scope.stopVolume = (volume) =>{
volume.status="false";
volume.status = false;
//$scope. status=
}
$scope.startVolume = (volume) =>{
volume.status="true";
volume.status = true;
}
$scope.$watch("ngDialogData.status", (newValue, oldValue) => {
if(newValue && newValue != oldValue){
$scope.$apply();
console.log($scope.volume)
}
});
function changeStatus(entity){
angular.forEach(entity.brick, (brick) =>{
brick["ip"] = brick.ip.join(".");
});
console.log(entity);
$http({
url: "/java/console/api/volume/update",

Loading…
Cancel
Save