Skip to content

Commit 2958665

Browse files
committed
Merge branch 'sw-26098/5.7/correct-date-columns' into '5.7'
SW-26098 - Correct some date fields back to datetime See merge request shopware/5/product/shopware!568
2 parents 7b8afb2 + cfda9fa commit 2958665

File tree

4 files changed

+55
-4
lines changed

4 files changed

+55
-4
lines changed

UPGRADE-5.7.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,25 @@
22

33
This changelog references changes done in Shopware 5.7 patch versions.
44

5+
## 5.7.1
6+
7+
[View all changes from v5.7.0...v5.7.1](https://github.com/shopware/shopware/compare/v5.7.0...v5.7.1)
8+
9+
### Additions
10+
11+
* Added service alias from `Template` to `template`
12+
* Added service alias from `Loader` to `loader`
13+
14+
### Changes
15+
16+
* Changed the visibility of services from tags `shopware_emotion.component_handler`, `criteria_request_handler` and `sitemap_url_provider` to public
17+
* Changed following columns type from `date` to `datetime`
18+
* `s_order_basket.datum`
19+
* `s_order_comparisons.datum`
20+
* `s_order_notes.datum`
21+
22+
## 5.7.0
23+
524
[View all changes from v5.6.1...v5.7.0](https://github.com/shopware/shopware/compare/v5.6.1...v5.7.0)
625

726
### Breaks

_sql/migrations/1702-no-more-invalid-dates.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,9 @@ public function up($modus)
3333
$sql[] = 'ALTER TABLE `s_emarketing_banners` CHANGE `valid_to` `valid_to` DATETIME NULL DEFAULT NULL;';
3434
$sql[] = 'ALTER TABLE `s_emarketing_lastarticles` CHANGE `time` `time` DATETIME NULL DEFAULT NULL;';
3535
$sql[] = 'ALTER TABLE `s_emarketing_tellafriend` CHANGE `datum` `datum` DATE NULL DEFAULT NULL;';
36-
$sql[] = 'ALTER TABLE `s_order_basket` CHANGE `datum` `datum` DATE NULL DEFAULT NULL;';
37-
$sql[] = 'ALTER TABLE `s_order_comparisons` CHANGE `datum` `datum` DATE NULL DEFAULT NULL;';
38-
$sql[] = 'ALTER TABLE `s_order_notes` CHANGE `datum` `datum` DATE NULL DEFAULT NULL;';
36+
$sql[] = 'ALTER TABLE `s_order_basket` CHANGE `datum` `datum` DATETIME NULL DEFAULT NULL;';
37+
$sql[] = 'ALTER TABLE `s_order_comparisons` CHANGE `datum` `datum` DATETIME NULL DEFAULT NULL;';
38+
$sql[] = 'ALTER TABLE `s_order_notes` CHANGE `datum` `datum` DATETIME NULL DEFAULT NULL;';
3939
$sql[] = 'ALTER TABLE `s_statistics_pool` CHANGE `datum` `datum` DATE NULL DEFAULT NULL;';
4040
$sql[] = 'ALTER TABLE `s_statistics_referer` CHANGE `datum` `datum` DATE NULL DEFAULT NULL;';
4141
$sql[] = 'ALTER TABLE `s_statistics_visitors` CHANGE `datum` `datum` DATE NULL DEFAULT NULL;';
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
<?php
2+
/**
3+
* Shopware 5
4+
* Copyright (c) shopware AG
5+
*
6+
* According to our dual licensing model, this program can be used either
7+
* under the terms of the GNU Affero General Public License, version 3,
8+
* or under a proprietary license.
9+
*
10+
* The texts of the GNU Affero General Public License with an additional
11+
* permission and of our proprietary license can be found at and
12+
* in the LICENSE file you have received along with this program.
13+
*
14+
* This program is distributed in the hope that it will be useful,
15+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
16+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17+
* GNU Affero General Public License for more details.
18+
*
19+
* "Shopware" is a registered trademark of shopware AG.
20+
* The licensing of the program under the AGPLv3 does not imply a
21+
* trademark license. Therefore any rights, title and interest in
22+
* our trademarks remain entirely with us.
23+
*/
24+
class Migrations_Migration1710 extends Shopware\Components\Migrations\AbstractMigration
25+
{
26+
public function up($modus)
27+
{
28+
$this->addSql('ALTER TABLE `s_order_basket` CHANGE `datum` `datum` DATETIME NULL DEFAULT NULL;');
29+
$this->addSql('ALTER TABLE `s_order_comparisons` CHANGE `datum` `datum` DATETIME NULL DEFAULT NULL;');
30+
$this->addSql('ALTER TABLE `s_order_notes` CHANGE `datum` `datum` DATETIME NULL DEFAULT NULL;');
31+
}
32+
}

engine/Shopware/Models/Order/Basket.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ class Basket extends ModelEntity
132132
/**
133133
* @var \DateTimeInterface|null
134134
*
135-
* @ORM\Column(name="datum", type="date", nullable=true)
135+
* @ORM\Column(name="datum", type="datetime", nullable=true)
136136
*/
137137
private $date;
138138

0 commit comments

Comments
 (0)