This is an automated email from the ASF dual-hosted git repository.

maximebeauchemin pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-superset.git


The following commit(s) were added to refs/heads/master by this push:
     new 42ebcaa  Evelynturner/annotation timezone fix2 (#4550)
42ebcaa is described below

commit 42ebcaad40fff66b4cc833a04f988c5949280014
Author: EvelynTurner <36863942+evelyntur...@users.noreply.github.com>
AuthorDate: Thu Mar 8 13:19:36 2018 -0500

    Evelynturner/annotation timezone fix2 (#4550)
    
    * Fix how the annotation layer interpretes the timestamp string without 
timezone info; use it as UTC
    
    * Fix how the Interval annotation layer interpretes the timestamp string 
without timezone info; use it as UTC
---
 superset/assets/visualizations/nvd3_vis.js | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/superset/assets/visualizations/nvd3_vis.js 
b/superset/assets/visualizations/nvd3_vis.js
index 3739aa4..8bd7229 100644
--- a/superset/assets/visualizations/nvd3_vis.js
+++ b/superset/assets/visualizations/nvd3_vis.js
@@ -670,8 +670,8 @@ function nvd3Vis(slice, payload) {
             const tip = tipFactory(e);
 
             const records = (slice.annotationData[e.name].records || 
[]).map((r) => {
-              const timeColumn = new Date(r[e.timeColumn]);
-              const intervalEndColumn = new Date(r[e.intervalEndColumn]);
+              const timeColumn = new Date(moment.utc(r[e.timeColumn]));
+              const intervalEndColumn = new 
Date(moment.utc(r[e.intervalEndColumn]));
               return {
                 ...r,
                 [e.timeColumn]: timeColumn,

-- 
To stop receiving notification emails like this one, please contact
maximebeauche...@apache.org.

Reply via email to