diff --git a/library/Icingadb/Model/Behavior/Timestamp.php b/library/Icingadb/Model/Behavior/Timestamp.php index b2a3a2ba..73fc835f 100644 --- a/library/Icingadb/Model/Behavior/Timestamp.php +++ b/library/Icingadb/Model/Behavior/Timestamp.php @@ -13,6 +13,10 @@ class Timestamp extends PropertyBehavior public function toDb($value, $_) { + if (! ctype_digit($value)) { + $value = strtotime($value); + } + return $value * 1000.0; } }