From b181bd8d7862f410b1e20d505c0ecd6ee676646e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20P=C3=A9ters?= Date: Tue, 11 Apr 2017 10:16:32 +0200 Subject: [PATCH] hide header from time-only picker (#14736) --- chrono/manager/static/css/style.css | 8 ++++++++ chrono/manager/static/js/bootstrap-datetimepicker.js | 4 ++++ 2 files changed, 12 insertions(+) diff --git a/chrono/manager/static/css/style.css b/chrono/manager/static/css/style.css index f94beb6..0c88892 100644 --- a/chrono/manager/static/css/style.css +++ b/chrono/manager/static/css/style.css @@ -30,3 +30,11 @@ h2 span.identifier { font-size: 1rem; opacity: 0.6; } + +.time-only-picker thead { + display: none; +} + +.time-only-picker tbody td { + width: 200px; +} diff --git a/chrono/manager/static/js/bootstrap-datetimepicker.js b/chrono/manager/static/js/bootstrap-datetimepicker.js index 9ba9888..efc44df 100644 --- a/chrono/manager/static/js/bootstrap-datetimepicker.js +++ b/chrono/manager/static/js/bootstrap-datetimepicker.js @@ -151,6 +151,10 @@ mousedown: $.proxy(this.mousedown, this) }); + if (this.maxView == 1) { + this.picker.addClass('time-only-picker'); + } + if (this.wheelViewModeNavigation) { if ($.fn.mousewheel) { this.picker.on({mousewheel: $.proxy(this.mousewheel, this)}); -- 2.11.0