diff --git a/src/main/resources/static/js/controllers.js b/src/main/resources/static/js/controllers.js index 8ee83df..86e6fa4 100644 --- a/src/main/resources/static/js/controllers.js +++ b/src/main/resources/static/js/controllers.js @@ -298,3 +298,55 @@ transactionControllers.controller('TransactionDetailCtrl', [ '$scope', '$routePa } ]); + + + +transactionControllers.controller('ModalDemoCtrl', function ($scope, $uibModal, $log) { + + $scope.items = ['item1', 'item2', 'item3']; + $scope.animationsEnabled = true; + + $scope.open = function (size) { + var modalInstance = $uibModal.open({ + animation: $scope.animationsEnabled, + templateUrl: 'myModalContent.html', + controller: 'ModalInstanceCtrl', + size: size, + resolve: { + items: function () { + return $scope.items; + } + } + }); + + modalInstance.result.then(function (selectedItem) { + $scope.selected = selectedItem; + }, function () { + $log.info('Modal dismissed at: ' + new Date()); + }); + }; + + $scope.toggleAnimation = function () { + $scope.animationsEnabled = !$scope.animationsEnabled; + }; + +}); + +// Please note that $uibModalInstance represents a modal window (instance) dependency. +// It is not the same as the $uibModal service used above. + +transactionControllers.controller('ModalInstanceCtrl', function ($scope, $uibModalInstance, items) { + + $scope.items = items; + $scope.selected = { + item: $scope.items[0] + }; + + $scope.ok = function () { + $uibModalInstance.close($scope.selected.item); + }; + + $scope.cancel = function () { + $uibModalInstance.dismiss('cancel'); + }; +}); diff --git a/src/main/resources/static/partials/transaction-list.html b/src/main/resources/static/partials/transaction-list.html index 4b55164..e5c4362 100644 --- a/src/main/resources/static/partials/transaction-list.html +++ b/src/main/resources/static/partials/transaction-list.html @@ -10,8 +10,6 @@
-
- -
+
@@ -67,7 +65,7 @@ class="form-control">
-
+
  @@ -81,30 +79,32 @@
- - - - - - - - - - - - - - -
DatumKategorieBetragBeschreibung
{{transaction.date | date:'dd.MM.yyyy'}}{{transaction.category.name}}{{transaction.amount | number : 2}} €{{transaction.description}}
-
- more + +
+ + + + + + + + + + + + + +
DatumKategorieBetragBeschreibung
{{transaction.date | date:'dd.MM.yyyy'}}{{transaction.category.name}}{{transaction.amount | number : 2}} €{{transaction.description}}
+
+ more +
+ +
+ {{user.name}} {{user.outstandings | number : 2}} €
+
-
- {{user.name}} {{user.outstandings | number : 2}} €
-
- - +