Skip to content

Commit 9937b6b

Browse files
mysql update
1 parent 20439bb commit 9937b6b

File tree

1 file changed

+45
-0
lines changed

1 file changed

+45
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
<?php
2+
3+
use yii\db\Migration;
4+
5+
/**
6+
* Class m190814_025105_fecshop_tables
7+
*/
8+
class m190814_025105_fecshop_tables extends Migration
9+
{
10+
/**
11+
* {@inheritdoc}
12+
*/
13+
public function safeUp()
14+
{
15+
16+
$sql = "UPDATE `store_base_config` SET `value` = 'a:7:{s:12:\"increment_id\";s:10:\"1100000000\";s:19:\"requiredAddressAttr\";s:57:\"first_name,email,telephone,street1,country,city,state,zip\";s:24:\"orderProductSaleInMonths\";s:1:\"3\";s:34:\"minuteBeforeThatReturnPendingStock\";s:2:\"60\";s:32:\"orderCountThatReturnPendingStock\";s:2:\"30\";s:20:\"orderRemarkStrMaxLen\";s:4:\"1000\";s:10:\"guestOrder\";s:1:\"2\";}' WHERE `store_base_config`.`id` = 30;";
17+
$this->execute($sql);
18+
19+
}
20+
21+
/**
22+
* {@inheritdoc}
23+
*/
24+
public function safeDown()
25+
{
26+
echo "m190814_025105_fecshop_tables cannot be reverted.\n";
27+
28+
return false;
29+
}
30+
31+
/*
32+
// Use up()/down() to run migration code without a transaction.
33+
public function up()
34+
{
35+
36+
}
37+
38+
public function down()
39+
{
40+
echo "m190814_025105_fecshop_tables cannot be reverted.\n";
41+
42+
return false;
43+
}
44+
*/
45+
}

0 commit comments

Comments
 (0)