File tree Expand file tree Collapse file tree 1 file changed +47
-0
lines changed Expand file tree Collapse file tree 1 file changed +47
-0
lines changed Original file line number Diff line number Diff line change 1+ <?php
2+
3+ use Illuminate \Database \Migrations \Migration ;
4+ use Illuminate \Database \Schema \Blueprint ;
5+ use Illuminate \Support \Facades \Schema ;
6+
7+ class UpdateLegacyLocale extends Migration
8+ {
9+ /**
10+ * Run the migrations.
11+ *
12+ * @return void
13+ */
14+ public function up ()
15+ {
16+ //
17+ Schema::table ('users ' , function (Blueprint $ table ) {
18+ //
19+ $ table ->string ('locale ' , 10 )->nullable ()->default ('en-US ' )->change ();
20+ });
21+
22+ Schema::table ('settings ' , function (Blueprint $ table ) {
23+ //
24+ $ table ->string ('locale ' , 10 )->nullable ()->default ('en-US ' )->change ();
25+ });
26+
27+
28+ }
29+
30+ /**
31+ * Reverse the migrations.
32+ *
33+ * @return void
34+ */
35+ public function down ()
36+ {
37+ //
38+ Schema::table ('users ' , function (Blueprint $ table ) {
39+ //
40+ $ table ->string ('locale ' , 10 )->nullable ()->default (config ('app.locale ' ))->change ();
41+ });
42+ Schema::table ('settings ' , function (Blueprint $ table ) {
43+ //
44+ $ table ->string ('locale ' , 10 )->nullable ()->default (config ('app.locale ' ))->change ();
45+ });
46+ }
47+ }
You can’t perform that action at this time.
0 commit comments