From 3cb4bd24e127b7f55d463d934cad27f8c07c4406 Mon Sep 17 00:00:00 2001 From: Stephen Kelly Date: Mon, 15 Apr 2019 09:21:14 +0100 Subject: [PATCH] Add fractional part of seconds to datetime parser Some recent Qt version must have changed the output of QDateTime represented as a string to include that. --- templates/defaultfilters/datetime.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/templates/defaultfilters/datetime.cpp b/templates/defaultfilters/datetime.cpp index c61a437d..901dae71 100644 --- a/templates/defaultfilters/datetime.cpp +++ b/templates/defaultfilters/datetime.cpp @@ -89,7 +89,7 @@ QVariant DateFilter::doFilter(const QVariant &input, const QVariant &argument, { Q_UNUSED(autoescape) auto d = QDateTime::fromString(getSafeString(input), - QStringLiteral("yyyy-MM-ddThh:mm:ss")); + QStringLiteral("yyyy-MM-ddThh:mm:ss.zzz")); auto argString = getSafeString(argument);