Only show time in datepicker if format is HH/HH:mm/HH:mm:ss (#6525)
This commit is contained in:
committed by
Sebastiaan Janssen
parent
6b4f7f9ec8
commit
2aede644f4
@@ -53,6 +53,12 @@ function dateTimePickerController($scope, notificationsService, assetsService, a
|
||||
dateFormat: dateFormat,
|
||||
time_24hr: true
|
||||
};
|
||||
|
||||
// Don't show calendar if date format has been set to only time
|
||||
if ($scope.model.config.format === "HH:mm:ss" || $scope.model.config.format === "HH:mm" || $scope.model.config.format === "HH") {
|
||||
$scope.datePickerConfig.enableTime = true;
|
||||
$scope.datePickerConfig.noCalendar = true;
|
||||
}
|
||||
|
||||
setDatePickerVal();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user