forked from pkp/ojs
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
pkp/pkp-lib#8333 Added migration to create extra foreign keys
- Loading branch information
1 parent
17a1fbb
commit f7d2436
Showing
2 changed files
with
34 additions
and
0 deletions.
There are no files selected for viewing
33 changes: 33 additions & 0 deletions
33
classes/migration/upgrade/v3_4_0/I8333_AddMissingForeignKeys.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
<?php | ||
|
||
/** | ||
* @file classes/migration/upgrade/v3_4_0/I8333_AddMissingForeignKeys.php | ||
* | ||
* Copyright (c) 2023 Simon Fraser University | ||
* Copyright (c) 2023 John Willinsky | ||
* Distributed under the GNU GPL v3. For full terms see the file docs/COPYING. | ||
* | ||
* @class I8333_AddMissingForeignKeys | ||
* | ||
* @brief Upgrade/downgrade operations for introducing foreign key definitions to existing database relationships. | ||
*/ | ||
|
||
namespace APP\migration\upgrade\v3_4_0; | ||
|
||
class I8333_AddMissingForeignKeys extends \PKP\migration\upgrade\v3_4_0\I8333_AddMissingForeignKeys | ||
{ | ||
protected function getContextTable(): string | ||
{ | ||
return 'journals'; | ||
} | ||
|
||
protected function getContextKeyField(): string | ||
{ | ||
return 'journal_id'; | ||
} | ||
|
||
protected function getContextSettingsTable(): string | ||
{ | ||
return 'journal_settings'; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters