Skip to content

Commit

Permalink
Update migration herlper for translations to default active field to …
Browse files Browse the repository at this point in the history
…false to comply with some versions of PostgreSQL
  • Loading branch information
sauron authored and ifox committed Nov 19, 2023
1 parent dfa0ba5 commit 945e97e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Helpers/migrations_helpers.php
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ function createDefaultTranslationsTableFields($table, $tableNameSingular, $table
$table->softDeletes();
$table->timestamps();
$table->string('locale', 7)->index();
$table->boolean('active');
$table->boolean('active')->default(false);

$table->foreign("{$tableNameSingular}_id", "fk_{$tableNameSingular}_translations_{$tableNameSingular}_id")->references('id')->on($tableNamePlural)->onDelete('CASCADE');
$table->unique(["{$tableNameSingular}_id", 'locale'], "{$tableNameSingular}_id_locale_unique");
Expand Down

0 comments on commit 945e97e

Please sign in to comment.