Skip to content

fix: consider time zone during migration of orders#9

Draft
Dennis Garding (DennisGarding) wants to merge 5 commits intotrunkfrom
14186/time-zone-diff
Draft

fix: consider time zone during migration of orders#9
Dennis Garding (DennisGarding) wants to merge 5 commits intotrunkfrom
14186/time-zone-diff

Conversation

@DennisGarding
Copy link
Copy Markdown
Contributor

This PR is necessary to complete the issue: shopware/shopware#14186

See PR: shopware/SwagMigrationAssistant#184

Comment thread Service/OrderService.php

foreach ($orders as $key => &$order) {
$order['_locale'] = $locale;
if (!empty($timezone)) {
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we should avoid using empty()

/**
* @return string|null
*/
public function getDatabaseTimezone()
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I dont think OrderRepository is the correct place for this

Comment on lines +119 to +126
SELECT timeZones.timeZone
FROM (
SELECT @@SESSION.time_zone AS timeZone
UNION
SELECT @@system_time_zone AS timeZone
) AS timeZones
WHERE timeZone != 'SYSTEM'
LIMIT 1
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See my comments in the assistant PR:
shopware/SwagMigrationAssistant#184 (comment)

@larskemper Lars Kemper (larskemper) marked this pull request as draft April 28, 2026 13:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants