Skip to content

Promotions should use timezone in shop settings for time calculations not server time #6603

@brent-hoover

Description

@brent-hoover

Time zone is set here in the shop settings

image

I think this probably only involves changing const now = new Date() to something like const now = new Date().toLocaleString("en-US", { timeZone: "America/Chicago" }); where "America/Chicago" would be the timezone from ShopSettings. And probably want to define that function globally and maybe cache the timezone.

Metadata

Metadata

Assignees

Labels

PromotionsIssues related to the Promotions project

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions