Fix angular style issues.
This commit is contained in:
parent
e91bf14298
commit
4aed242a48
@ -56,7 +56,7 @@ angular.module('accountant.accounts', [
|
|||||||
return Account;
|
return Account;
|
||||||
})
|
})
|
||||||
|
|
||||||
.controller('AccountController', function($scope, $ngBootbox, Account, Notification) {
|
.controller('AccountController', function($ngBootbox, Account, Notification) {
|
||||||
var vm = this;
|
var vm = this;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@ -103,7 +103,7 @@ angular.module('accountant.accounts', [
|
|||||||
});
|
});
|
||||||
|
|
||||||
// Insert account at the begining of the array.
|
// Insert account at the begining of the array.
|
||||||
$scope.accounts.splice(0, 0, account);
|
vm.accounts.splice(0, 0, account);
|
||||||
};
|
};
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@ -114,7 +114,7 @@ angular.module('accountant.accounts', [
|
|||||||
rowform.$cancel();
|
rowform.$cancel();
|
||||||
} else {
|
} else {
|
||||||
// Account not saved, just remove it from array.
|
// Account not saved, just remove it from array.
|
||||||
$scope.accounts.splice($index, 1);
|
vm.accounts.splice($index, 1);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -122,7 +122,7 @@ angular.module('accountant.accounts', [
|
|||||||
* Save account.
|
* Save account.
|
||||||
*/
|
*/
|
||||||
vm.save = function(account) {
|
vm.save = function(account) {
|
||||||
// var account = $scope.accounts[$index];
|
// var account = vm.accounts[$index];
|
||||||
|
|
||||||
// account = angular.merge(account, $data);
|
// account = angular.merge(account, $data);
|
||||||
|
|
||||||
@ -149,7 +149,7 @@ angular.module('accountant.accounts', [
|
|||||||
Notification.success('Account #' + id + ' deleted.');
|
Notification.success('Account #' + id + ' deleted.');
|
||||||
|
|
||||||
// Remove account from array.
|
// Remove account from array.
|
||||||
$scope.accounts.splice($index, 1);
|
vm.accounts.splice($index, 1);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user