06-12-2020 03:45
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

06-12-2020 03:45
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Hi,
i m using the oauth example,
By using GET method for a single night i can easily query my data as so :
console.log(data.sleep);
how shall i do the same query when using the range of dates url :
for now it gives me a "null" answer... I guess i must address by date somewhere...
here is a picture of what i mean, thank you for your help!
merci beaucoup
Answered! Go to the Best Answer.

Accepted Solutions
06-12-2020 04:55
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

06-12-2020 04:55
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
var month = ("0" + (avant.getMonth() + 1)).slice(-2);
var day = ("0" + avant.getDate()).slice(-2);
needs 0 before units...
the oath example is a traitor as it provides a today variable working fine with the single day url but not with the range date...
let todayDate = `${date.getFullYear()}-${date.getMonth() + 1}-${date.getDate()}`;
:

06-12-2020 04:55
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

06-12-2020 04:55
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
var month = ("0" + (avant.getMonth() + 1)).slice(-2);
var day = ("0" + avant.getDate()).slice(-2);
needs 0 before units...
the oath example is a traitor as it provides a today variable working fine with the single day url but not with the range date...
let todayDate = `${date.getFullYear()}-${date.getMonth() + 1}-${date.getDate()}`;
:

