Very accurate observation J.  We have a fix, that I still need to push out
before it is too late, that avoids use of new Date() with no args (since
the behavior would depend on the current day), but instead provides all the
args at once.

On Mon, Jun 20, 2016 at 9:06 PM, <jstab...@energyedge.com.au> wrote:

> Hi.
>
> In anticipation of the end of month issue in a few days (29th June).
>
> I found that dataview.toDataTable() and datatable.clone() were having
> trouble with the date replication.
> It seems (without knowing the underlying code) that it is the order of the
> date creation.
>
> Say, if the current date is 30-Jun-2016 and you want to create a date of
> 15-Feb-2015.
> It appears to create a date from today (30-Jun-2016).
> then change year = 30-Jun-2015
> then change month = 30-Feb-2015 (which is converted to 2 Mar-2015)
> then change day = 15-Mar-2015  (not 15-Feb-2015)
>
> I believe it can be solved by initiating the date in .clone() and
> .toDataTable() with new Date(0) as opposed to new Date().
>
> J
>
> On Wednesday, June 1, 2016 at 3:53:49 AM UTC+10, Daniel LaLiberte wrote:
>>
>> It appears there are at least two different date-related bugs that have
>> come up on the jspai loaded version.
>>
>> One problem involves dates that are specified with the string notation,
>> e.g. "Date(2016, 4, 30)", which typically occurs when using JSON formatted
>> values especially from spreadsheets.   The bug affects dates when the
>> current date is just before the end of a month.
>>
>> Another separate problem involves the use of the viewWindow with date
>> values, resulting in the date being one month later.  This probably also
>> affects the DateRangeFilter.   I'm not sure if this problem only shows up
>> at the end of the month also, but we weren't hearing about it until now.
>>
>> --
> You received this message because you are subscribed to the Google Groups
> "Google Visualization API" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to google-visualization-api+unsubscr...@googlegroups.com.
> To post to this group, send email to
> google-visualization-api@googlegroups.com.
> Visit this group at
> https://groups.google.com/group/google-visualization-api.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/google-visualization-api/82bca05e-a3be-4450-8585-b20c382da637%40googlegroups.com
> <https://groups.google.com/d/msgid/google-visualization-api/82bca05e-a3be-4450-8585-b20c382da637%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>
> For more options, visit https://groups.google.com/d/optout.
>



-- 
Daniel LaLiberte <https://plus.google.com/100631381223468223275?prsrc=2>
dlalibe...@google.com <dlalibe...@google.com>   5CC, Cambridge MA

-- 
You received this message because you are subscribed to the Google Groups 
"Google Visualization API" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-visualization-api+unsubscr...@googlegroups.com.
To post to this group, send email to google-visualization-api@googlegroups.com.
Visit this group at https://groups.google.com/group/google-visualization-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-visualization-api/CAOtcSJOYFJVSwADY2mEL_6O%2BV2C7MK2Ni_pcsQmS427ErHzpuQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to