Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Check dateToSerialString compared to model for timezone offset #3

Closed
bayssmekanique opened this issue Jan 31, 2019 · 0 comments
Closed
Assignees
Labels
question Further information is requested

Comments

@bayssmekanique
Copy link
Contributor

bayssmekanique commented Jan 31, 2019

Currently using:

const dateToSerialString = (date: Date) => {
  return ('00' + (date.getUTCMonth() + 1)).substr(-2) +
  ('00' + date.getUTCDate()).substr(-2) + ' ' +
  date.getUTCFullYear() + ' ' +
  ('00' + date.getUTCHours()).substr(-2) +
  ('00' + date.getUTCMinutes()).substr(-2) + ' ' +
  ('00' + date.getUTCSeconds()).substr(-2)
}

This assumes the serial number encoding is using UTC time, but it might be using PST offset. Need to compare value with label on machine to confirm.

@bayssmekanique bayssmekanique added the question Further information is requested label Jan 31, 2019
@bayssmekanique bayssmekanique self-assigned this Jan 31, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

1 participant