From 2fafa3929c54d78487113ce095f83cd378a88e4f Mon Sep 17 00:00:00 2001 From: kunw Date: Wed, 29 Jun 2016 14:18:36 +0800 Subject: [PATCH] update for auto-resizing height to table body. --- static/resources/css/dashboard.css | 2 +- .../components/top-repository/top-repository.directive.html | 4 ++-- .../js/components/top-repository/top-repository.directive.js | 4 +++- .../resources/js/components/user-log/user-log.directive.html | 2 +- static/resources/js/layout/dashboard/dashboard.controller.js | 3 ++- static/resources/js/layout/index/index.controller.js | 5 ++++- views/dashboard.htm | 4 ++-- views/index.htm | 2 +- 8 files changed, 16 insertions(+), 10 deletions(-) diff --git a/static/resources/css/dashboard.css b/static/resources/css/dashboard.css index 1fe3e142b..eeee030c4 100644 --- a/static/resources/css/dashboard.css +++ b/static/resources/css/dashboard.css @@ -1,6 +1,6 @@ .up-section .up-table-pane { overflow-y: auto; - height: 180px; + height: 220px; margin-top: -10px; } diff --git a/static/resources/js/components/top-repository/top-repository.directive.html b/static/resources/js/components/top-repository/top-repository.directive.html index 372aae120..601799587 100644 --- a/static/resources/js/components/top-repository/top-repository.directive.html +++ b/static/resources/js/components/top-repository/top-repository.directive.html @@ -1,6 +1,6 @@
-
+
@@ -9,7 +9,7 @@
// 'repository_name' | tr //
-
+
diff --git a/static/resources/js/components/top-repository/top-repository.directive.js b/static/resources/js/components/top-repository/top-repository.directive.js index 549c967c3..12a099a2c 100644 --- a/static/resources/js/components/top-repository/top-repository.directive.js +++ b/static/resources/js/components/top-repository/top-repository.directive.js @@ -30,7 +30,9 @@ 'restrict': 'E', 'templateUrl': '/static/resources/js/components/top-repository/top-repository.directive.html', 'controller': TopRepositoryController, - 'scope' : true, + 'scope' : { + 'customBodyHeight': '=' + }, 'controllerAs': 'vm', 'bindToController': true }; diff --git a/static/resources/js/components/user-log/user-log.directive.html b/static/resources/js/components/user-log/user-log.directive.html index 43f5e1207..3b093a2d7 100644 --- a/static/resources/js/components/user-log/user-log.directive.html +++ b/static/resources/js/components/user-log/user-log.directive.html @@ -9,7 +9,7 @@
-
+
diff --git a/static/resources/js/layout/dashboard/dashboard.controller.js b/static/resources/js/layout/dashboard/dashboard.controller.js index 4beb06f1c..90386b9fa 100644 --- a/static/resources/js/layout/dashboard/dashboard.controller.js +++ b/static/resources/js/layout/dashboard/dashboard.controller.js @@ -9,7 +9,8 @@ DashboardController.$inject = ['$scope']; function DashboardController($scope) { - + var vm = this; + vm.customBodyHeight = {'height': '165px'}; } })(); \ No newline at end of file diff --git a/static/resources/js/layout/index/index.controller.js b/static/resources/js/layout/index/index.controller.js index b0c5e18b3..fee10c856 100644 --- a/static/resources/js/layout/index/index.controller.js +++ b/static/resources/js/layout/index/index.controller.js @@ -14,8 +14,11 @@ $scope.subsSection = 32; $scope.subsSubPane = 226; + var vm = this; - + + vm.customBodyHeight = {'height': '180px'}; + var indexDesc = $filter('tr')('index_desc', []); var indexDesc1 = $filter('tr')('index_desc_1', []); var indexDesc2 = $filter('tr')('index_desc_2', []); diff --git a/views/dashboard.htm b/views/dashboard.htm index 98137b7b0..be6b177bd 100644 --- a/views/dashboard.htm +++ b/views/dashboard.htm @@ -10,7 +10,7 @@
- +
@@ -20,7 +20,7 @@
- +
diff --git a/views/index.htm b/views/index.htm index fc8296781..e1095b6c6 100644 --- a/views/index.htm +++ b/views/index.htm @@ -52,7 +52,7 @@
- +