Merge pull request #2052 from marekkukan-tw/mk/fixplotly

fix bug in plotly_convert_to_datetime
This commit is contained in:
Michael Krabbe Borregaard 2019-06-08 09:47:02 +02:00 committed by GitHub
commit 505989eec7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -436,7 +436,7 @@ plotly_native_data(axis::Axis, a::Surface) = Surface(plotly_native_data(axis, a.
function plotly_convert_to_datetime(x::AbstractArray, formatter::Function)
if formatter == datetimeformatter
map(xi -> replace(formatter(xi), "T", " "), x)
map(xi -> replace(formatter(xi), "T" => " "), x)
elseif formatter == dateformatter
map(xi -> string(formatter(xi), " 00:00:00"), x)
elseif formatter == timeformatter